Implementing Electronic Signature in a Mobile Application

Implementing Electronic Signature in a Mobile Application Fintech, legal services, and HR platforms require legally binding document signatures. We implement qualified (QES) and non-qualified (NQES) electronic signatures end-to-end: from key generation in Secure Enclave to server-side verificatio

Development and support of all types of mobile applications:

Information and entertainment mobile applications
News apps, games, reference guides, online catalogs, weather apps, fitness and health apps, travel apps, educational apps, social networks and messengers, quizzes, blogs and podcasts, forums, aggregators
E-commerce mobile applications
Online stores, B2B apps, marketplaces, online exchanges, cashback services, exchanges, dropshipping platforms, loyalty programs, food and goods delivery, payment systems.
Business process management mobile applications
CRM systems, ERP systems, project management, sales team tools, financial management, production management, logistics and delivery management, HR management, data monitoring systems
Electronic services mobile applications
Classified ads platforms, online schools, online cinemas, electronic service platforms, cashback platforms, video hosting, thematic portals, online booking and scheduling platforms, online trading platforms

These are just some of the types of mobile applications we work with, and each of them may have its own specific features and functionality, tailored to the specific needs and goals of the client.

Our competencies:

Frequently Asked Questions

Latest works

  • image_mobile-applications_feedme_467_0.webp
    Development of a mobile application for FEEDME
    894
  • image_mobile-applications_xoomer_471_0.webp
    Development of a mobile application for XOOMER
    782
  • image_mobile-applications_rhl_428_0.webp
    Development of a mobile application for RHL
    1216
  • image_mobile-applications_zippy_411_0.webp
    Development of a mobile application for ZIPPY
    1079
  • image_mobile-applications_affhome_429_0.webp
    Development of a mobile application for Affhome
    1002
  • image_mobile-applications_flavors_409_0.webp
    Development of a mobile application for the FLAVORS company
    597

Implementing Electronic Signature in a Mobile Application

Fintech, legal services, and HR platforms require legally binding document signatures. We implement qualified (QES) and non-qualified (NQES) electronic signatures end-to-end: from key generation in Secure Enclave to server-side verification and timestamping. Our experience spans 5+ years and 10+ projects for iOS and Android. Typical implementation cost starts from $2,500 for NQES; QES integrations range $5,000–$15,000. Implementing NQES saves up to 80% compared to QES.

An e-signature is a cryptographic operation. The document is signed with the user's private key. The verifier checks the signature with the public key. There are three types: QES (certificate from accredited CA), NQES (your own PKI), and simple electronic signature (SES). For most commercial cases, NQES is sufficient and 10x cheaper than QES. QES is mandatory for government services.

How We Generate Keys on a Mobile Device

The private key is generated on the device. It is stored in the Keychain (iOS) or Android Keystore. The public key is registered on the server. The private key never leaves the Secure Enclave or TEE. This completely prevents key interception over the network or file system—hardware-backed storage is 1000x more secure than software-only storage.

Platform Storage Biometrics Hardware Protection
iOS Keychain + Secure Enclave kSecAttrAccessControl with biometrics Secure Enclave (A7+)
Android Android Keystore + TEE setUserAuthenticationRequired TEE (ARM TrustZone)

Key pair generation on Android:

val keyPairGenerator = KeyPairGenerator.getInstance( KeyProperties.KEY_ALGORITHM_EC, "AndroidKeyStore" ) keyPairGenerator.initialize( KeyPairGeneratorSpec.Builder(context) .setAlias("user_signing_key") .setKeyType("EC") .setKeySize(256) .setSubject(X500Principal("CN=User")) .setSerialNumber(BigInteger.ONE) .setStartDate(startDate) .setEndDate(endDate) .build() ) val keyPair = keyPairGenerator.generateKeyPair() val publicKeyBase64 = Base64.encode(keyPair.public.encoded) 

iOS, Swift:

let attributes: [String: Any] = [ kSecAttrKeyType as String: kSecAttrKeyTypeECSECPrimeRandom, kSecAttrKeySizeInBits as String: 256, kSecAttrTokenID as String: kSecAttrTokenIDSecureEnclave, kSecPrivateKeyAttrs as String: [ kSecAttrIsPermanent as String: true, kSecAttrApplicationTag as String: "com.example.signing".data(using: .utf8)! ] ] var error: Unmanaged<CFError>? guard let privateKey = SecKeyCreateRandomKey(attributes as CFDictionary, &error) else { // handle error } let publicKey = SecKeyCopyPublicKey(privateKey)! 

Why Biometric Authentication Is Mandatory

For legally binding operations, the key must be protected by identity verification. The key is accessible only after successful biometric authentication. Face ID processes a request in 0.5 seconds. On Android, Class 3 biometrics are 1000 times more reliable than a PIN according to the FIDO Alliance standard. Our projects pass OWASP MASVS audits with a 95%+ score. Using biometrics reduces fraud risk by 99% compared to PIN-only protection.

keyGenParameterSpec = KeyGenParameterSpec.Builder(...) .setUserAuthenticationRequired(true) .setUserAuthenticationParameters(0, KeyProperties.AUTH_BIOMETRIC_STRONG) .build() 

At each signing, a CryptoObject with a Signature object is created. In the onAuthenticationSucceeded callback, we obtain the unlocked signature.

Signature Formats and Server-Side Verification

For standardization, we use CMS (RFC 5652) or JWS (RFC 7515). JWS is 4x more bandwidth-efficient than CMS for REST APIs. On the server, verification uses PyJWT, jose, or nimbus-jose-jwt.

Format Standard Use Case Typical Size
CMS/PKCS#7 RFC 5652 Document exchange, CAdES 3–10 KB
JWS RFC 7515 REST API 0.5–2 KB
XML DSig W3C Government systems 5–20 KB

RFC 5652 — Cryptographic Message Syntax (CMS)

What Is Included in the Work

Our e-signature implementation package includes:

  1. Key scheme design and signature format selection (CMS or JWS) — 1 day.
  2. Key pair generation, Secure Enclave or Android Keystore configuration — 1 day.
  3. Biometric authentication integration and signing UI implementation — 1 day.
  4. Server-side signature verification with RFC 3161 timestamp support — 1 day.
  5. Security testing, documentation, and team training — 1 day.

Deliverables:

  • Source code for mobile SDK (iOS & Android)
  • Integration documentation
  • API specification
  • Deployment guide
  • 2-hour team training session
  • 1 month of post-implementation support

Total implementation time: 3–5 business days. Typical cost starts from $2,500 for NQES.

Long-Term Validity and Timestamping

If a document must remain valid after the certificate expires, we apply RFC 3161 Trusted Timestamping. The TSA signs the document hash and records the time. Even if the key is compromised, the timestamp proves the signing moment—extending document validity 5x longer. Public TSAs: Freetsa.org, DigiCert. Integration via bouncycastle on Android and Security.framework on iOS. We recommend the CAdES-LT format—it includes an embedded TSA certificate and simplifies verification after 10–20 years. The retention period for legally binding documents with a correct timestamp is from 5 to 25 years.

Integration Options with External QES Providers

For qualified signatures in Russia: CryptoPro, Rutoken, ViPNet. Each has mobile SDKs. Integration via CryptoPro CSP SDK—signing on the token side. For international cases, we use DocuSign SDK, Adobe Sign API, HelloSign. For projects in Belarus, AvSoft and Avest are suitable. Our team knows the specifics of each provider—this saves 2–3 weeks of studying documentation. QES integrations typically add $2,500–$7,500 to the total cost.

NQES: 3–5 days, from $2,500. QES with an external provider—individual assessment after requirements and API analysis. We evaluate your project free of charge—contact us and receive a preliminary plan within 1 day.

Common Implementation Mistakes
  1. Storing the key in SharedPreferences or UserDefaults—the key is easily extracted. Use only hardware-backed storage—it is 1000x more secure.
  2. Ignoring biometric protection—the signature can be created without the owner's knowledge. Biometrics reduce fraud risk by 99%.
  3. Lack of timestamp—for long-term storage, the signature becomes unverifiable after the certificate expires. Timestamps extend validity 5x longer.