diff --git a/fido2/ctap.c b/fido2/ctap.c index 5d01721..4b12461 100644 --- a/fido2/ctap.c +++ b/fido2/ctap.c @@ -1219,6 +1219,12 @@ uint8_t ctap_get_assertion(CborEncoder * encoder, uint8_t * request, int length) { memset(auth_data_buf,0,sizeof(CTAP_authDataHeader)); auth_data_buf_sz = sizeof(CTAP_authDataHeader); + crypto_sha256_init(); + crypto_sha256_update(GA.rp.id, GA.rp.size); + crypto_sha256_final(((CTAP_authData *)auth_data_buf)->head.rpIdHash); + + ((CTAP_authData *)auth_data_buf)->head.flags = (1 << 0); + ((CTAP_authData *)auth_data_buf)->head.flags |= (ctap_is_pin_set() << 2); } else #endif diff --git a/fido2/main.c b/fido2/main.c index f290ff8..6dee829 100644 --- a/fido2/main.c +++ b/fido2/main.c @@ -42,9 +42,10 @@ int main(int argc, char *argv[]) TAG_U2F| //TAG_PARSE | //TAG_TIME| - //TAG_DUMP| + TAG_DUMP| TAG_GREEN| TAG_RED| + TAG_EXT| TAG_ERR );