import fido2.webauthn


def get_credential_id(attestion_object_cbor: bytes) -> bytes:
	attestation_object = fido2.webauthn.AttestationObject(attestion_object_cbor)
	credential_data = attestation_object.auth_data.credential_data
	assert credential_data is not None
	return credential_data.credential_id
