Docs
  • Introduction
  • Get Started
    • Introduction
    • Preparation
  • Instant Payment
    • overview
    • instant payment apply API
    • instant payment confirm API
    • instant payment notification
    • instant payment result query.md
    • balance-query-api
  • MPAY Payment API
    • Overview
    • Card Bind Apply API
    • Card Bind Verify API
    • MPAY Apply Direct API
    • MPAY Verify Direct API
    • Asynchronous Notification
    • Payment Result Query API
  • Unified gateway payment
    • Overview
    • Payment Creation Direct API
    • New Online Banking Overview
  • Easy Payment
    • Overview
    • WEB Payment API
    • H5 Payment API
    • Easypay Apply Direct API
    • Easypay Verify Direct API
    • Pre-authorized capture API
    • Pre-authorized cancel API
    • Pre-authorized order status query API
    • Asynchronous Notification
    • Payment Result Query API
  • Online banking Payment
    • Overview
    • Payment API
    • Synchronous Notification
    • Asynchronous Notification
    • Payment Result Query API
  • Exchange Payment
    • Overview
    • Apply API
    • Verify API
    • Asynchronous Notification
    • Payment Result Query API
  • Aggregate Payment
    • Overview
    • Redirect API
    • Direct API
    • Asynchronous Notification
    • Payment Result Query API
  • Relevant API
    • Card Bind
      • Apply API
      • Verify API
      • Unbind API
      • Query API
    • Refund
      • Apply API
      • Result Query API
      • Asynchronous Notification
    • Card Bin Query API
  • Development
    • Singature
      • Key Configuration
      • Add Sign
      • Verify Sign
    • Asynchronous Notification
    • Risk Item
    • Transaction Report
    • Return Codes
    • Supported Currencies
    • Supported Banks
Powered by GitBook
On this page
  • Generate private key
  • Generate public key and upload it to LianLian dashboard
  • Obtain LianLian public key
  1. Development
  2. Singature

Key Configuration

PreviousSingatureNextAdd Sign

Last updated 5 years ago

In this section, you will learn about how to generate your private key and public key. We use to generate keys.

Generate private key

openssl genrsa -out rsa_private_key.pem 2048

A file named rsa_private_key.pem should be generated in your current folder.

The following steps are required for Java and C#, if you are using PHP, you can continue with .

Convert rsa_private_key.pem in the format of PKCS8.

openssl pkcs8 -topk8 -inform PEM -in rsa_private_key.pem -outform PEM -nocrypt

Remove the header, footer, line breaks of the output and save it. E.g.

MIICdgIBADANBgkqhkiG9w0BAQEFAASCAmAwggJcAgEAAoGBALrnBQVM/VUTaECLW/VaMfJK4Lb6WZaL6Iy6MYWr0D4rSk3VU/33LvubRPUQAylWUpT8sgaHb2bkPl+1+DAvAELoR+2yIGRNq6X6oqAR/Drv/b6MOokzEGq9KxOQM44aRHgwBEbDTt1IWFIj241A5WBJpmrLLnyKAZm7jTmCmITpAgMBAAECgYBFuxlZb+74RcRYiGXntR37WspaGi9AhrRdhL4jNAX+m+IeBeBPWWCTCMwCblXvn0AyS9ETtIXwqmlHBjoxp+d9atLEyFN2GMu811gvfWTrK2LKQxO+eo5ulpJKuSAQkpz7bZzq5ByG8vlT8QZ+YKCp/7XCHto2PHtA2YO7CeR8gQJBAPL64oEfRsEi+NxOYN7mBeUPEcH1HCQ9hBcVaatSzWcdnJP/MCcL7V7Y02zwCJQxBSIbU5d/5brCEtVzMWLGupECQQDE6uHCzk+aWx1trioOAiwegENL7jy3E40cJ7ie8OvkP/mJZpbjNjSBefpsY/semzjBwd77hJKH0+SIpB/KTmDZAkB23e+DFYbqoy41sI5JXSRTG50nUr7Sp9l/5XTNYHOl12GrMTMgVwBn3xEHgSHhRV3qgo3RVrtPMvQ9wd3OIcRRAkBZucTg5Oz0omvIXEGhXHAJ/dusL4POz8POfnLrSU/TEyt65hn+seY+0PvAg9Ya3hOAhfw6ku/JoE1TzaUGo6wRAkEAr4e9y/swoH7SiDtuvCNHLha2sSDdmNVDWzWpvGNiomST17W2UuXxaLmFPZB5+Jd3bGndppYFsVKAD6Qf3ECBHQ==

Generate public key and upload it to LianLian dashboard

openssl rsa -in rsa_private_key.pem -pubout -out rsa_public_key.pem

In your current folder, a file named rsa_public_key.pem should be generated. Open it and you will get something like this:

-----BEGIN PUBLIC KEY-----
MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQC65wUFTP1VE2hAi1v1WjHySuC2
+lmWi+iMujGFq9A+K0pN1VP99y77m0T1EAMpVlKU/LIGh29m5D5ftfgwLwBC6Eft
siBkTaul+qKgEfw67/2+jDqJMxBqvSsTkDOOGkR4MARGw07dSFhSI9uNQOVgSaZq
yy58igGZu405gpiE6QIDAQAB
-----END PUBLIC KEY-----

Remove the header, footer, line breaks.

MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQC65wUFTP1VE2hAi1v1WjHySuC2+lmWi+iMujGFq9A+K0pN1VP99y77m0T1EAMpVlKU/LIGh29m5D5ftfgwLwBC6EftsiBkTaul+qKgEfw67/2+jDqJMxBqvSsTkDOOGkR4MARGw07dSFhSI9uNQOVgSaZqyy58igGZu405gpiE6QIDAQAB

Obtain LianLian public key

Upload it to .

Go to and obtain the file whose name is llpay_public_key.pem.

merchant dashboard
merchant dashboard
openssl
Generate public key