mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-09-22 13:39:35 +00:00
prevent access token ttl=0
This commit is contained in:
@@ -116,7 +116,9 @@ export const AddUniversalAuthToIdentityV1 = z.object({
|
||||
.array()
|
||||
.min(1)
|
||||
.default([{ ipAddress: "0.0.0.0/0" }]),
|
||||
accessTokenTTL: z.number().int().min(0).default(7200),
|
||||
accessTokenTTL: z.number().int().min(1).refine(value => value !== 0, {
|
||||
message: "accessTokenTTL must have a non zero number",
|
||||
}).default(2592000),
|
||||
accessTokenMaxTTL: z.number().int().refine(value => value !== 0, {
|
||||
message: "accessTokenMaxTTL must have a non zero number",
|
||||
}).default(2592000), // 30 days
|
||||
|
||||
@@ -223,7 +223,7 @@ export const IdentityUniversalAuthForm = ({
|
||||
{...field}
|
||||
placeholder="2592000"
|
||||
type="number"
|
||||
min="0"
|
||||
min="1"
|
||||
step="1"
|
||||
/>
|
||||
</FormControl>
|
||||
|
||||
Reference in New Issue
Block a user