()
| 7 | } from '@oslojs/encoding'; |
| 8 | |
| 9 | export function generateSessionToken(): string { |
| 10 | const bytes = new Uint8Array(20); |
| 11 | crypto.getRandomValues(bytes); |
| 12 | const token = encodeBase32LowerCaseNoPadding(bytes); |
| 13 | return token; |
| 14 | } |
| 15 | |
| 16 | export async function createSession( |
| 17 | token: string, |
no outgoing calls
no test coverage detected