Quantcast
Channel: Sudo - is there a command to check if I have sudo and/or how much time is left? - Super User
Viewing all articles
Browse latest Browse all 12

Answer by Dysaster for Sudo - is there a command to check if I have sudo and/or how much time is left?

$
0
0

According to the sudo manual, the sudo session is determined according to the time stamp file (/usr/lib/sudo/<username>), so you may be able to figure out how much time is left by checking the date/time of the time stamp file. However, in my system, the time stamp file is in fact a directory, and there are three files with cryptic content in them (and also some weird time stamps, but /usr/lib/sudo/<username> seemed to have a timestamp that coincided with the time I gave sudo my password. I think /usr/lib/sudo/<username>/0 has the time stamp of the most recent sudo execution.


Viewing all articles
Browse latest Browse all 12

Trending Articles