@gibme/stir-shaken
    Preparing search index...

    @gibme/stir-shaken

    STIR/SHAKEN CallerID Attestation & Call Signing

    • generateIdentityHeader() method used for generating the Identity header using the supplied parameters.
    • AGIStirShakenServer class that creates an Asterisk AGI server instance that will attest to and sign calls automatically
    • Auto formats caller ID and called numbers into E.164 format when signing

    https://gibme-npm.github.io/stir-shaken/

    import { generateIdentityHeader } from '@gibme/stir-shaken';

    const header = generateIdentityHeader(
    '5678675309', // caller id
    '8004444444', // called number
    '8935da48-d9d5-4fff-ae99-2753bb9b034b', // the unique call ID
    'C', // the attestation level
    'https://my.domain/certificate.pem', // the publicly accessible URL with the STI certificate
    '<private_key_for_certificate>' // the certificate private key
    );
    import { AGIStirShakenServer } from '@gibme/stir-shaken';

    (async () => {
    const server = new AGIStirShakenServer({
    port: 9000,
    certificatePath: './certificate.pem',
    privateKeyPath: './privatekey.pem',
    publicCertificateURL: 'https://my.domain/certificate.pem',
    attestationProvider: callerId => {
    // do some checks and return an attestation level
    return 'C';
    },
    logger: entry => {
    console.log(entry);
    }
    });

    await server.start();
    })()