Add RSA hash algorithm detection in passport parsing

This commit is contained in:
turnoffthiscomputer
2025-10-17 23:56:35 +02:00
committed by GitHub
parent da83215748
commit d2ec05cec9

View File

@@ -40,6 +40,14 @@ export function brutforceSignatureAlgorithm(passportData: PassportData) {
};
}
}
const hashAlgorithm = brutforceHashAlgorithm(passportData, 'rsa');
if (hashAlgorithm) {
return {
signatureAlgorithm: 'rsa',
hashAlgorithm: hashAlgorithm,
saltLength: 0,
};
}
}
function brutforceHashAlgorithm(