Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6468931
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T05:56:10+00:00 2026-05-25T05:56:10+00:00

Recently I was assigned an iOS project, where I need to digitally sign a

  • 0

Recently I was assigned an iOS project, where I need to digitally sign a pdf document using a key that the application will download from a server.

I don’t yet have a clear idea of the process involved in signing documents, what I know until now is that I will be signing my pdf using a private key file provided to me, and then the verification will be done using the public key version of the same file.

I have seen that digital sign can be achieved using libraries like iText for Java or iTextSharp for C#. That’s why I would like to know if there is something similar for iOS?. And if not, what would be the process to achieve this using Quartz abilities to manage pdf documents?


Well… I have been checking the Apple docs, and I found this:

https://developer.apple.com/documentation/security/certificate_key_and_trust_services

I think this is supposed to support the X.509 format… which I could use to sign the pdf as an instance os CFData I guess. Also I have been checking the CryptoExercise sample code, but I am not 100% sure if this is what I am looking for.

Other suggestions have told me to check Adobe documentation, but haven’t found yet a C api to sign documents using certificates.

If somebody has used the certificate services provided by Apple… it would be great any suggestion or more sample codes to understand the process.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-25T05:56:10+00:00Added an answer on May 25, 2026 at 5:56 am

    Pablo,

    signing PDF documents is a tough task (my company is doing this in the windows world in Pascal).

    In general, I can tell you that you probably will not find usable source code you can just incorporate into you project. To see how it is done, the iText source is a good starting point, cause everything is in there.

    In objective-c you are on the right path. Using X.509 certificates with functions like SecKeyRawSign is the right way (cause the actual given paddings are to old, you need to create your own padding for supporting e.g. SHA256. You can see here, how this is done: What is the difference between the different padding types on iOS?).
    The ‘dataToSign’ is nothing else than the hash of PDF Content (e.g. SHA256) you want to sign.

    To find out which part of the PDF source you have to sign exactly, you must check the adobe PDF 1.6 documentation, or do some searches in groups talking about that. It makes no difference in which language you are going to sign the PDF.

    In the end, you will embed the signature and some information about the signature in the predefined portion of the PDF document (look out to not break the valid hash by doing that 😉 ) and it could be seen and verified with any other PDF signature/verification software.

    I’m sorry that I can’t provide you with relevant code, but you’ll find enough samples around the X.509 certificates – e.g. creating a SSL/SSH connection. And if you search for SecKeyRawSign, you’ll even find some samples for signing (at least with other patterns). That’s all you need, if you find the PDF Syntax for taking the content portion to sign and to embed the signature into the final PDF.

    I hope this was of help for you

    Jimmy

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Recently I just got assigned a project to develop a web application/site that uses
I have recently been assigned a CSS & design project that's in a CakePHP
I recently started a new project using Automatic Reference Counting (ARC). When I assigned
I recently was assigned to update an old project who use the asp:listbox control
I have been recently assigned a task in which I need to create a
In a project at work, I've recently been assigned to encode the user input
Recently I was assigned to a project which was already in its midway. It
Recently I've been assigned to examine Java code coverage using Sonar with Maven. I
I've recently been assigned to a C++ project involving information being sent between computers
I recently started working on a large complex application, and I've just been assigned

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.