Digital Signature In Yii

Hello friends,

  As a newbie, I am going to ask a stupid question again. In my current project, I have to make website mixed with google docs, dropbox and mediafire. In addition, when a user will submit a file, that file will be checked whatever the file is digitally signed or not (

Now, I need to show that, one file format (either doc or pdf) will be examined to determine that, is it digitally signed or not ? I read the doc file but there is no difference between a signed file and a unsigned file in reading. I thought I would try it in OPENSSL(php), but I did not find any document which indicates doc file can be read for digital signature.

Now, my alternative is java, C#, But, I do not know whatever it is possible in any of this one?

In a word, my question is, How to get information of digital signature from a doc/pdf file and how can i verify its signed or not?

ANY OPINION will be a plus point for me (as a newbie, i am in big trouble).

THANK YOU VERY MUCH FOR READING THIS and sorry for my bad English.



Hm, that’s tough. .doc is largely a proprietary format with little to no open specifications (most informations covering that format are reverse-engineered). Regarding PDF: There are a lot of commercial solutions available to process PDFs. Including the parsing of signature informations. You could also try to set your own parser in place for that, since PDF is really an open format. But beware: It gets quite messy <_<

THANKS A LOT Da:Sourcerer. Can you give me some link on getting digital certificate information from pdf. I wanted to do it in doc, but if i can do it in pdf, i will get some idea. Thanks a lot again, i am completely new and hopless :(

Well, feel free to consult the PDF v1.7 spec. My guess is that the digital signature will be part of some XML in the document’s metadata. Good luck :)

Thanks a lot, :) … I am trying…

Any more opinion will be most welcome ///

I read the metadata of pdf. but there is no difference between signed and unsigned … do not know, what is doing wrong :(

Well, where and how have you been looking? Could be that the signature is compressed or has been wrapped in some ascii-armour (base85 or similar), so it won’t show up in a scan for the raw values.

Yes, metadata is out of question. I need to separate the digital certificate (P7B) from the file. do you know how and where the MS Word stores the digital signature? Anybody?

AND THANKS Da:Sourcerer :)

Maybe you can get some useful information here?

Edit: If you have the time, you can check KB840817 on how to get the Microsoft Word spec.

It is done. Thanks all for the feedback.

All i did, I make jar file where I used iText to read the signature, validate the signature, validate the certificate of the signature using bouncy castle and finally call the jar file to validate all

saqib how to create digital signture in yii?

give me tutorial please…

sory my english so bad

Please provide any tutorial or document for the same.