-
-
Notifications
You must be signed in to change notification settings - Fork 112
Add token id to audit log #932
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
6c4561e
fa6cb79
9cd1849
fe01913
4e7568b
36d39f6
8453af1
0f65d1e
55e82ca
e2756b4
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -7,13 +7,17 @@ | |
| [hiccup.form :refer [check-box drop-down label text-field submit-button]])) | ||
|
|
||
| (defn- new-token-message | ||
| [{:keys [name token]}] | ||
| [{:keys [name token token_id]}] | ||
| (when token | ||
| (list | ||
| [:p (format "Your new deploy token '%s' has been created. It will only be shown this one time, so be sure to copy it now:" | ||
| name)] | ||
| [:p (format "Your new deploy token '%s' with id '%s' has been created. It will only be shown this one time, so be sure to copy it now:" | ||
| name | ||
| token_id)] | ||
| [:div.new-token | ||
| [:pre token]]))) | ||
| [:pre token]] | ||
| [:p "Token ID:"] | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I don't think we need to show the id here, since I think it would make users think they need to copy it as well. But it would be good to have a way to go from a token value to an id. Maybe instead we add another column to the token table below to show the last four digits of the token? That would require another column, as we don't store the token value, just the bcrypt and sha256 hashes of it. |
||
| [:div.token-id | ||
| [:pre token_id]]))) | ||
|
|
||
| (defn- scope | ||
| [{:keys [group_name jar_name]}] | ||
|
|
@@ -95,6 +99,7 @@ | |
| [:table.table.deploy-tokens | ||
| [:thead | ||
| [:tr | ||
| [:th "Token ID"] | ||
| [:th "Token Name"] | ||
| [:th "Scope"] | ||
| [:th "Single Use?"] | ||
|
|
@@ -114,6 +119,7 @@ | |
| (when expired? "token-expired") | ||
| (when used? "token-used")]))]] | ||
| [:tr {:class classes} | ||
| [:td.id (:id token)] | ||
| [:td.name (:name token)] | ||
| [:td.scope (scope token)] | ||
| [:td.single-use (:single_use token)] | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you move this to the end of the vector? We keep the migrations in the order they were added.