[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[gnutls-dev] Using encrypted OpenPGP keys
From: |
Mario Lenz |
Subject: |
[gnutls-dev] Using encrypted OpenPGP keys |
Date: |
Thu, 10 Aug 2006 17:05:28 +0200 |
Hi!
I just wanted to offer you to send diffs or to use cvs. And a little
change:
> int
> _gnutls_openpgp_raw_enc_privkey_to_gkey (gnutls_privkey * pkey, const
> gnutls_datum_t * raw_key, const char *pw)
> {
> /* no changes */
>
> if (pw)
> {
> if (cdk_sk_unprotect (pkt->pkt.secret_key, pw) != CDK_Success)
> {
> rc = GNUTLS_E_OPENPGP_GETKEY_FAILED;
> goto leave;
> }
> }
>
> /* no changes from here on */
>
> sk = pkt->pkt.secret_key;
> pke_algo = sk->pk->pubkey_algo;
> pkey->params_size = cdk_pk_get_npkey (pke_algo);
>
> /* and so on... */
>
> }
I think "if (pw && *pw)" would be better.
greez
Mario