X-Git-Url: http://the.earth.li/gitweb/?a=blobdiff_plain;f=sigcheck.c;h=963eeffe4beb3ef19f81eed1e5cb756c5d16ca4f;hb=23538b7a1fe44e6e04e15d58b6fe809a6ad2ca31;hp=2c1fc4c0871adc3bde0b5de10db26c7a57cd0b65;hpb=c0fee41b459cc3822d890bac98882a6c9696c033;p=onak.git diff --git a/sigcheck.c b/sigcheck.c index 2c1fc4c..963eeff 100644 --- a/sigcheck.c +++ b/sigcheck.c @@ -116,7 +116,7 @@ static void onak_free_key_material(struct onak_key_material *key) static onak_status_t onak_parse_key_material(struct openpgp_packet *pk, struct onak_key_material *key) { - int i, len, ofs; + int len, ofs; enum onak_oid oid; mpz_t x, y; onak_status_t ret = ONAK_E_OK; @@ -278,7 +278,7 @@ static onak_status_t onak_parse_key_material(struct openpgp_packet *pk, return ret; } -onak_status_t onak_check_hash_sig(struct openpgp_publickey *sigkey, +onak_status_t onak_check_hash_sig(struct openpgp_packet *sigkey, struct openpgp_packet *sig, uint8_t *hash, uint8_t hashtype) @@ -288,11 +288,10 @@ onak_status_t onak_check_hash_sig(struct openpgp_publickey *sigkey, struct dsa_signature dsasig; uint8_t sigkeytype; uint8_t edsig[64]; - uint64_t keyid; int len, ofs; mpz_t s; - ret = onak_parse_key_material(sigkey->publickey, &pubkey); + ret = onak_parse_key_material(sigkey, &pubkey); if (ret != ONAK_E_OK) { return ret; } @@ -530,7 +529,6 @@ onak_status_t calculate_packet_sighash(struct openpgp_publickey *key, uint8_t keyheader[5]; uint8_t packetheader[5]; uint8_t trailer[10]; - int i; uint64_t keyid; onak_status_t res;