* Validate AuthnRequest signature skelton * Code refactor: Move the base64decode to common method * wip * Add signature validation * Read the keys from config * Lock dep version Co-authored-by: Deepak Prabhakara <deepak@boxyhq.com>
18 lines
419 B
TypeScript
18 lines
419 B
TypeScript
import { fetchPrivateKey, fetchPublicKey } from 'utils';
|
|
|
|
const appUrl = process.env.APP_URL || 'http://localhost:4000';
|
|
const entityId = process.env.ENTITY_ID || 'https://saml.example.com/entityid';
|
|
const ssoUrl = `${appUrl}/api/saml/sso`;
|
|
const privateKey = fetchPrivateKey();
|
|
const publicKey = fetchPublicKey();
|
|
|
|
const config = {
|
|
appUrl,
|
|
entityId,
|
|
ssoUrl,
|
|
privateKey,
|
|
publicKey,
|
|
};
|
|
|
|
export default config;
|