GmSSL is an open-source cryptographic library that implements the Chinese national cryptographic standards SM2, SM3, SM4, SM9, and ZUC as a unified algorithm suite. It provides a comprehensive set of cryptographic primitives including symmetric and asymmetric encryption, digital signatures, hashing, and key exchange, all built around these national standards for government and enterprise security applications.
The library distinguishes itself through several integration capabilities. It includes an OpenSSL compatibility layer that maps GmSSL functions to OpenSSL API calls, enabling drop-in replacement in applications like Nginx. A hardware abstraction layer provides software interfaces to SDF and SKF cryptographic devices, allowing transparent offloading of operations to PCI-E cards or USB tokens. Multi-language JNI bindings expose the cryptographic APIs to Java, PHP, and Go applications through a compiled shared library.
The library supports a full TLS and TLCP protocol stack with TLS 1.2, 1.3, and TLCP 1.1 using SM-series cipher suites, along with an X.509 certificate engine for creating, parsing, validating, and managing digital certificates and PKI requests. It also includes post-quantum cryptography support with CRYSTALS-Kyber, SPHINCS+, XMSS, and LMS/HSS algorithms. The cross-platform build system compiles for Android/ARM via NDK and Windows via Visual Studio, producing CLI binaries and shared libraries.