How to decode PDF created with Quartz PDFContext? - macos

I recieved very strange PDF-contract with sender's possibility of remote real time conditions and payment adress changing against me, to scam me.
One of the PDF layers with text is readable but there are still hidden parts of the text.
The code inside PDF is encrypted. It created with Quartz PDFContext (macOS Version 10.15.3)
How could we decode that PDF and read that code inside PDF to proof the scam against me?
Thanx in advance

Related

How to access to Outlook (desktop client on macOS) stored emails programmatically

I'm trying to read emails from Outlook (desktop client on macOS) installation programmatically.
For Thunderbird I only need to read the files stored in /Users/xxxx/Library/Thunderbird/Profiles/xxxx.default-release/ImapMail/someemailaccount/.
Each file on that directory is named after the name of each folder on the email account (INBOX, Sent, etc.) and it contains all the emails (header, body and attachments). So all I have to do is to read that file with some programming language and apply the right decoder depending on the Content-Transfer-Encoding header.
For Outlook I found this file: /Users/xxxx/Library/Group Containers/UBF8T346G9.Office/Outlook/Outlook 15 Profiles/Main Profile/HxStore.hxd but it looks doesn't look to be readable, is it on a binary format? it is compressed or encrypted?
I tried to see its contents using Hex Field app and it displays that the file contains some blocks of data but those blocks look to be broken or encrypted/compressed (more info about that file here https://boncaldoforensics.wordpress.com/2018/12/09/microsoft-hxstore-hxd-email-research/):
<html><head>
<meta http-equiv="Content-Type" cp="text/;ñ; charset=utf-8"></Lð<body><div dir="ltr">1234567890ñ>
...
As you can see above, the contents look to be there but there are some strange characters on it. Also, the file has a lot of sections with no characters or random ones.
Does anybody know how can I read this file?
If you use the older outlook interface (or switch back to it) you can access the underlying sqlite database pretty easily.
However this will be discontinued at some point and Outlook will completely switch to the new interface based on Core Spotlight.
I am also looking for a way to access emails from the new interface, and yes the data seems to be in this file. Anybody else have pointers on how to access?

InlineQueryResultArticle - thumb_url uploaded image

Is there an option to use an image uploaded to telegram (file_id couldn't do it) inside InlineQueryResultArticle thumb_url?
notes:
I tried to get the file path using getfile() but it didn't do the trick.
even tried to upload a very small image size with no luck.
I'd like to ignore the InlineQueryResultCachedPhoto option since the design is not the same
any thoughts?
thank you!
I also checked that the telegram does not show the uploaded image, I think it is better to give the address of the picture directly.

How to turn base64 encoded data back into an image without using UIImage in Swift?

I'm writing a Swift Server that accepts and saves a base64 String which has encoded a UIImage via UIImageJPEGRepresentation (so I can compress it). This string is then sent as JSON, where it is saved to a Swift Cloudant database. However, the server doesn't have access to UIKit, so I can't refer to a UIImage in it's code to decode it back into a picture. Is there a way to turn the String back into a picture without using UIImage?
Pure Swift would be the best option, but I don't know if it's actually possible. My server is a Kitura one, hosted on IBM Bluemix. Thank you!
(The goal is to show the picture on a webpage.)
I don't know if it can help but as you need to show this image on a website I, in an application where I need to show a webview with a image,used this (in the .html file containing my webpage)
<img src="data:image/png;base64,#IMAGE_STRING#">
and when I run the application the "#IMAGE_STRING#" is replaced by the base64 string containing the image , the result is : my image is showing perfectly in the webpage

How to decode this png file?

Can anyone please help on how to open this png file: https://dl.dropboxusercontent.com/u/23248082/TEST.PNG
Also it would be great if you can tell me how it is enrcrypted or why its not opening.
It opens fine only with Meditech client. It seems Meditech is encrypting in someway.
I tried with different viewers and also tried converting it into differen format but so far no luck.
Iam also a newbie in this area. Any help would be highly appreciated.
Thanks..
Looking at it with tweakpng it seems the format is deliberately corrupted for proprietary use. There's a wrong CRC for the palette (correcting it does no good) and an invalid chunk count.
If your Meditech is the EHR (Electronic Health Record) system then you will only be able to accurately view the image by accessing it from the system. All data is encrypted for the purpose of restricting access to patient records.

Send Email with pdf file as attachment in rhomobile

I want to send email using mailto tag with a single pdf file as attachment.
mailto tag opens the mail window with passed arguments like to and subject using:
Mail to Manager
But, attachments as a parameter isnt working.
Please suggest how to send pdf attachment in rhomobile.
Thanks
I think that you need to add the physical path to the PDF file for it to work (otherwise it may not know where the file is). This post on a forum says as follows:
The only problem is that this "mailto" command executes on the
client machine, therefore it tries to locate the attachment file by
a physical path, and not by a virtual path.
That is,
Using mailto:iudith.m#zim.co.il?subject=my report&body=see attachment&attachment="\myhost\myfolder\myfile.lis"
works ok, but only for local users (those connected to the same
network as the "myhost" machine).
Using mailto:iudith.m#zim.co.il?subject=my report&body=see attachment&attachment="http://myhost:myport/my_location_virtual_path/myfile.lis"
does not work, it does not recognize such a syntax as valid for
the attachment file.
In your case you would properbly need to look at this part of the Rhomobile docs (on file system access) to get the right path to your file.
EDIT:
From you comment I can see that you are trying to make it work on iOS (due to the iOS specific path).
In this discussion (from Rhomobile's Google Group) it is explained that mailto doesn't support attachments on iOS. It says as follows:
Don't know about other platforms, but you cannot do this on iOS. mailto: does not support attachments on iOS.
You can do it using a native API, MFMailComposeViewController.
This is a complete controller with UI, so you would have to write a Native View Extension to use it:
http://docs.rhomobile.com/rhodes/extensions#native-view-extensions
EDIT 2:
I've looked around and it seems that mailto doesn't support attachments on Android either. This is because Android supports the RFC 2368 mailto protocol, which doesn't include attachments. Here is a reference to the Android mailto url parser.
I would suggest that you do as suggested for iOS, write a native extension. I think this post would be relevant for you.

Resources