Sign up for our public-beta program and redeem upwards of $1.000 USD in Zalter credits for your first year!
Simple and secure sign in links sent via email
Sign in users with a one-time passcode sent via email
Sign in users with a one-time passcode sent via SMS
Add extra factors such as Google Authenticator
End-to-end encryption. During the authentication, a new end to end encryption system protocol ensures no active or passive MITM attack is effective
No cookies used. We not use cookies to function, so even if the user browser doesn't accept cookies, the authentication will still work
Private credentials. The private key never leaves the browser and can never be stolen by MITM attacks. After the authentication, signatures guarantee the user claims
1async function signRequest(requestInit) {
2 const { method, headers, body } = requestInit;
3
4 // Load current user and get their public key ID
5 const user = await auth.getCurrentUser();
6 const keyId = user.subSigKeyId;
7
8 const data = Buffer.from(body || Buffer.alloc(0));
9
10 // Create the signature by signing the message
11 let sig = await user.signMessage(data);
12
13 // Encode the signature to Base64
14 sig = Buffer.from(sig).toString('base64');
15
16 return {
17 method,
18 headers: {
19 ...headers,
20 // Add the signature header
21 'x-signature': `${keyId};${sig}`
22 },
23 body
24 };
25}
Jump into the developers docs and start building in minutes
Zalter is free to get started and scales with you as you grow.
Get a free personalized demo from a security expert.