Hi Alessandro,
> Is "period":"0" the correct value to create a token with an unlimited lifetime?
No. Periodic token should have TTL value other than "0". The way to
ensure unlimited lifetime is to keep on renewing the periodic token
before it hits its TTL. The maximum TTL which is applicable to regular
tokens are not applicable to periodic tokens. "explicit_max_ttl" is an
exception though.
> Why "lease_duration": 0" and "lease_duration": 2764800 in the response of "auth/token/create" ?
The value of interest in that response is the auth block. The outer
"lease_duration" is for something else. Since the token had a period
of 0, the created token is NOT a periodic token and it has the default
TTL of 32 days (2764800 second).
> Why "ttl": 2764506 in the response of "auth/token/lookup-accessor" ?
Based on the explanation above it is the TTL of the regular token
created. The token has used up a few seconds off of the 32 days.
Changing the "period" to a shorter value, say "10m", and having it
renewed every 10m is the way to use it.
Hope this helps!
Regards,
Vishal
> --
> This mailing list is governed under the HashiCorp Community Guidelines -
>
https://www.hashicorp.com/community-guidelines.html. Behavior in violation
> of those guidelines may result in your removal from this mailing list.
>
> GitHub Issues:
https://github.com/hashicorp/vault/issues
> IRC: #vault-tool on Freenode
> ---
> You received this message because you are subscribed to the Google Groups
> "Vault" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to
vault-tool+...@googlegroups.com.
> To view this discussion on the web visit
>
https://groups.google.com/d/msgid/vault-tool/452f00f6-1cb0-4514-9a10-ed0f6bbbe374%40googlegroups.com.
> For more options, visit
https://groups.google.com/d/optout.
--
vn