Social Icons

Showing posts with label pdf. Show all posts
Showing posts with label pdf. Show all posts

Tuesday, June 08, 2021

MERGING PDF: UBUNTU 20.04 LTS

This small post shares a one line command in Ubuntu terminal to merge to PDFs. While for the regulars,merging the same online would seem to be the quickest and the best but there are times when you wish your PDFs are not compromised by third party websites offering these mergers for free...so why not use a one line command with the help of a tool pdftk.

The command to install the same is 

sudo apt-get install pdftk

and the command thereafter to merger the PDFs like three files 1.pdf, 2.pdf and 3.pdf is as seen below:

 pdftk 1.pdf 2.pdf 3.pdf cat output 4.pdf

where 4.pdf is the merged final output file.

That's all...no third party website reliance for private files.

Saturday, November 24, 2012

Detecting a MALICIOUS PDF:PDFid @ BACKTRACK 5 R3


1.    Adobe, who gave us the the ever comfortable PDF..thats the "Portable Document Format" in the early 1990's never thought like how this can become a security threat by the simple action of opening it only....yess!!!this post will give a small insight of how things really work behind the scene in execution of a malicious PDF....

2.  So first of all...how a PDF becomes a malicious document?The answer to this question is simple embedding of a JAVA SCRIPT, that is not seen but only executed once a PDF is opened....no antivirus will be able to identify of what malicious thing lies behind a normal PDF that u and me use daily...so if u scan a malicious PDF with your Antivirus,it is veri unlikely to be caught....how do we know then whether a PDF is malicious or not?...thats what this post shows here....I came across a tool known as PDFid in the BACKTRACK R3 that I was running in Virtual Box.

3.   Few lines about the tool....this was developed by Didier Stevens who blogs at http://blog.didierstevens.com/.So this helps us to differentiate between PDF Documents that could be malicious and those that are unlikely to be....The tool is based on the fact that that a  typical PDF File comprises of header, objects, cross-reference table (to locate objects), and trailer.So , if there is a tool that can find out if any one of them is available in this PDF...things can become easier...so like for example...if a PDF that has no purpose of embedding or holding a JS inside it,then a eye brow raise is certain as to why should it be there....so PDFid tool comes to rescue us out of this question...First the typical structure of a PDF with its one line explanation is given below :

“/OpenAction” and “/AA” (Additional Action) specifies the script or action to run automatically.

 “/Names”, “/AcroForm”, “/Action” can also specify and launch scripts or actions.

“/JavaScript” specifies JavaScript to run.

 “/GoTo*” changes the view to a specified destination within the PDF or in another PDF file.

 “/Launch” launches a program or opens a document.

“/URI” accesses a resource by its URL.

“/SubmitForm” and “/GoToR” can send data to URL.

“/RichMedia” can be used to embed Flash in PDF.

“/ObjStm” can hide objects inside an Object Stream.

4. So now I have set up a VB machine running BTR3 that would run this tool and find out if the PDF that I have analyzed is malicious or not? These are the screen shots showing a step by step scene of how u do it....


(Click on the Image to ENLARGE)

(Click on the Image to ENLARGE)

(Click on the Image to ENLARGE)

(Click on the Image to ENLARGE)

5.   So the last screen shows the final result...for those of you who find this little complicated I will upload a video cast of this soon....

Sunday, December 04, 2011

CONVERT UR BLOOK IN A PDF E-BOOK

1. I recently came across a wonderful wonderful free for use site at http://blogbooker.com/.This site would convert your entire blog into an E-Book....that 2 entirely free....amazing.

2. I was able to convert my present blog here into a complete PDF with amazing features that include :

- comments included
- year wise sorting
- page numbers and indexing included.
- easy to create
- easy to share.
- no irritating water marks.

3.  Sample this :.....gr888888888888

Blogger to E-Book

Thanks  http://blogbooker.com
Powered By Blogger