Steps to Reproduce:
$ gpgsm --version gpgsm (GnuPG) 2.4.3 libgcrypt 1.10.2 libksba 1.6.4 $ gpgsm -vv --import root.crt gpgsm: enabled compatibility flags: gpgsm: certificate imported gpgsm: całkowita liczba przetworzonych: 1 gpgsm: dołączono do zbioru: 1 $ gpgsm -vv --import user.crt gpgsm: enabled compatibility flags: gpgsm: unknown digest algorithm '?' used in certificate gpgsm: certificate has a BAD signature: Błąd ogólny gpgsm: podstawowe sprawdzenia certyikatu nie powiodły się - nie zaimportowany gpgsm: no issuer found in certificate gpgsm: podstawowe sprawdzenia certyikatu nie powiodły się - nie zaimportowany gpgsm: całkowita liczba przetworzonych: 2 gpgsm: nie włączono do zbioru: 2 $ certutil.exe user.crt → OK!
• clean all files in %APPDATA%\gnupg
• import .p12:
$ gpgsm -vv --import credential_private_encrypted_3DES.p12 gpgsm: enabled compatibility flags: gpgsm: keybox ,,C:\\Users\\warm_face\\AppData\\Roaming\\gnupg\\pubring.kbx'' utworzony gpgsm: no running gpg-agent - starting 'C:\\Program Files (x86)\\Gpg4win\\..\\GnuPG\\bin\\gpg-agent.exe' gpgsm: waiting for the agent to come up ... (5s) gpgsm: connection to the agent established gpgsm: processing bag.encryptedData gpgsm: 2216 bytes of 3DES encrypted text gpgsm: processing certBag gpgsm: poszukiwanie wystawcy w pamięci podręcznej Dirmngr gpgsm: no running dirmngr - starting 'C:\\Program Files (x86)\\Gpg4win\\..\\GnuPG\\bin\\dirmngr.exe' gpgsm: waiting for the dirmngr to come up ... (5s) gpgsm: connection to the dirmngr established gpgsm: liczba pasujących certyfikatów: 0 gpgsm: wyszukiwanie klucza tylko w pamięci podręcznej dirmngr nie powiodło się: Brak danych gpgsm: nie można uzyskać authorityInfoAccess: Brak wartości gpgsm: issuer certificate (#/[ 434e3df09f93a7204a6f686e20446f65 ]) not found Oops, ksba_cert_get_image failed: imagelen=104 hdr=4 len=981 off=0 gpgsm: błąd zapisywania certyfikatu: Błąd ogólny gpgsm: błąd zapisywania certyfikatu gpgsm: skipping bag.attribute_set gpgsm: processing certBag gpgsm: certificate imported gpgsm: processing bag data gpgsm: processing shrouded_key_bag gpgsm: 1224 bytes of 3DES encrypted text gpgsm: skipping shrouded_key_bag.attribute_set gpgsm: swapping secret primes gpgsm: całkowita liczba przetworzonych: 3 gpgsm: dołączono do zbioru: 1 gpgsm: tajnych kluczy wczytanych: 1 gpgsm: tajnych kluczy dodanych: 1 gpgsm: nie włączono do zbioru: 1
Consider the following 2 levels of certificates:
ROOT/Issuer | \--> USER/Subscriber
The more important parameters of these certificates, from the point of view of path building:
ROOT/Issuer - Serial - Issuer: CN = John Doe - Subject: CN = John Doe - Basic Constraints: critical, CA:TRUE - SKI USER/Subscriber - Serial - Issuer: CN = John Doe - Subject: NULL ASN.1 SEQUENCE {} - Basic Constraints: critical, CA:FALSE - AKI - SKI - SAN: critical, email:test@example.com
The option to leave the "Subject DN" field blank is in line with the standards (standards.txt), I have not discovered anything new. With this "set" of certificates, C+SE are similar to GPG keyrings, but without gluing/binding them together. The EE cert is relatively small (for x509v3) and correctly handled by Outlook and Thunderbird. A solution similar to the one described by Peter Gutmann 25 years ago (using S/MIME without buying CA services), two levels of certificates to bypass email programs. The biggest drawback is that the certificates are mixed with other "official" CA-approved certificates (that's why the emoji was added).
thank you