Update tools help

This commit is contained in:
Zhi Guan
2026-06-26 18:06:53 +08:00
parent e43f9e306d
commit a77feb2b4c
25 changed files with 256 additions and 217 deletions

View File

@@ -80,36 +80,36 @@ static const char *options =
" gmssl sm2keygen -pass P@ssw0rd -out alice.pem -pubout alicepub.pem\n"
" gmssl sm2keygen -pass P@ssw0rd -out bob.pem -pubout bobpub.pem\n"
" gmssl sm2exch -stage init \\\n"
" -exch_keyout alice_ra.pem -exch_pass P@ssw0rd -out ra.hex\n"
" -exch_keyout alice_ra.pem -exch_pass P@ssw0rd -out ra.hex\n"
" gmssl sm2exch -stage respond \\\n"
" -key bob.pem -pass P@ssw0rd -id Bob \\\n"
" -peer_pubkey alicepub.pem -peer_id Alice -in ra.hex \\\n"
" -exch_keyout bob_rb.pem -exch_pass P@ssw0rd \\\n"
" -secret_state_out bob_secret_state.hex -out rb_sb.hex\n"
" -key bob.pem -pass P@ssw0rd -id Bob \\\n"
" -peer_pubkey alicepub.pem -peer_id Alice -in ra.hex \\\n"
" -exch_keyout bob_rb.pem -exch_pass P@ssw0rd \\\n"
" -secret_state_out bob_secret_state.hex -out rb_sb.hex\n"
" gmssl sm2exch -stage confirm \\\n"
" -key alice.pem -pass P@ssw0rd -id Alice \\\n"
" -peer_pubkey bobpub.pem -peer_id Bob \\\n"
" -exch_key alice_ra.pem -exch_pass P@ssw0rd -in rb_sb.hex \\\n"
" -keylen 48 -keyout alice_shared_key.hex -out sa.hex\n"
" -key alice.pem -pass P@ssw0rd -id Alice \\\n"
" -peer_pubkey bobpub.pem -peer_id Bob \\\n"
" -exch_key alice_ra.pem -exch_pass P@ssw0rd -in rb_sb.hex \\\n"
" -keylen 48 -keyout alice_shared_key.hex -out sa.hex\n"
" gmssl sm2exch -stage finish \\\n"
" -key bob.pem -pass P@ssw0rd -id Bob \\\n"
" -peer_pubkey alicepub.pem -peer_id Alice \\\n"
" -exch_key bob_rb.pem -exch_pass P@ssw0rd \\\n"
" -secret_state bob_secret_state.hex -in sa.hex \\\n"
" -keylen 48 -keyout bob_shared_key.hex\n"
" -key bob.pem -pass P@ssw0rd -id Bob \\\n"
" -peer_pubkey alicepub.pem -peer_id Alice \\\n"
" -exch_key bob_rb.pem -exch_pass P@ssw0rd \\\n"
" -secret_state bob_secret_state.hex -in sa.hex \\\n"
" -keylen 48 -keyout bob_shared_key.hex\n"
"\n"
"Certificate workflow:\n"
"\n"
" gmssl sm2exch -stage respond \\\n"
" -key bob_enc_key.pem -pass P@ssw0rd -id Bob \\\n"
" -peer_cert alice_enc_cert.pem -peer_id Alice -in ra.hex \\\n"
" -exch_keyout bob_rb.pem -exch_pass P@ssw0rd \\\n"
" -secret_state_out bob_secret_state.hex -out rb_sb.hex\n"
" -key bob_enc_key.pem -pass P@ssw0rd -id Bob \\\n"
" -peer_cert alice_enc_cert.pem -peer_id Alice -in ra.hex \\\n"
" -exch_keyout bob_rb.pem -exch_pass P@ssw0rd \\\n"
" -secret_state_out bob_secret_state.hex -out rb_sb.hex\n"
" gmssl sm2exch -stage confirm \\\n"
" -key alice_enc_key.pem -pass P@ssw0rd -id Alice \\\n"
" -peer_cert bob_enc_cert.pem -peer_id Bob \\\n"
" -exch_key alice_ra.pem -exch_pass P@ssw0rd -in rb_sb.hex \\\n"
" -keyout alice_shared_key.hex -out sa.hex\n"
" -key alice_enc_key.pem -pass P@ssw0rd -id Alice \\\n"
" -peer_cert bob_enc_cert.pem -peer_id Bob \\\n"
" -exch_key alice_ra.pem -exch_pass P@ssw0rd -in rb_sb.hex \\\n"
" -keyout alice_shared_key.hex -out sa.hex\n"
"\n"
"Notes\n"
"\n"