Skip to content

Commit 2b0a3e3

Browse files
authored
Merge pull request #291 from kbrwn/patch-1
Update audit-logging.mdx
2 parents 697db32 + 3bfe635 commit 2b0a3e3

File tree

1 file changed

+13
-1
lines changed

1 file changed

+13
-1
lines changed

pages/authzed/concepts/audit-logging.mdx

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ This is an example policy that grants the necessary permissions to write to a Fi
7676
"Resource": "EXAMPLE_FIREHOSE_ARN"
7777
}
7878
]
79-
}
79+
}
8080
```
8181

8282
[Kinesis]: https://aws.amazon.com/kinesis
@@ -126,3 +126,15 @@ Using the web dashboard, navigate to the Permission System's settings page to fi
126126

127127
Audit logging is configured using command-line flags.
128128
See the full list of flags in the [Extenders section](extenders#flags).
129+
130+
### Tokens in Audit Logs
131+
132+
To identify which token was used for a request, look up its SHA-256 hash in the audit log's metadata.
133+
Each request's `token_hash` field contains the hashed value of the original token used.
134+
135+
Example of generating a SHA-256 hash:
136+
137+
```bash
138+
$ python3 -c "import hashlib; print(hashlib.sha256('<authzed-token>'.encode()).hexdigest())"
139+
> 2ffb5caf16962e4371bc036d8de2a99dfcea1ae70091ef2953d633a88d05321a
140+
```

0 commit comments

Comments
 (0)