* Use boxyhq/saml20 * use sign from saml20 * cleaned up GetKeyInfo * cleaned up getPublicKeyPemFromCertificate * cleaned up node-forge * use hasValidSignature from saml20 * cleanup and update saml20 to the beta version * throw an error if signature is not valid * updated saml20
10 lines
343 B
TypeScript
10 lines
343 B
TypeScript
const fetchPublicKey = (): string => {
|
|
return process.env.PUBLIC_KEY ? Buffer.from(process.env.PUBLIC_KEY!, 'base64').toString('ascii') : '';
|
|
};
|
|
|
|
const fetchPrivateKey = (): string => {
|
|
return process.env.PRIVATE_KEY ? Buffer.from(process.env.PRIVATE_KEY!, 'base64').toString('ascii') : '';
|
|
};
|
|
|
|
export { fetchPublicKey, fetchPrivateKey };
|