Generate a cryptographically random session ID (`s_<128-bit hex>`). Used as `$auth.session_id` in RLS predicates and as the audit correlation key — must be unguessable.
()
| 326 | /// Used as `$auth.session_id` in RLS predicates and as the audit |
| 327 | /// correlation key — must be unguessable. |
| 328 | pub fn generate_session_id() -> String { |
| 329 | super::random::generate_tagged_random_hex("s_") |
| 330 | } |
| 331 | |
| 332 | #[cfg(test)] |
| 333 | mod tests { |