💻 Software
Sudo - is there a command to check if I have sudo and/or how much time is left?
Fresh5 days ago
Mar 15, 202654716 viewsConfidence Score0%
0%
Problem
(Originally posted on Stack Overflow). They suggested I try here instead. Here's the original post: Sudo - is there a command to check if I have sudo and/or how much time is left? See title. I want a command that lets me query sudo. Ideally, it would return success if I still have sudo and false if…
Error Output
sudo -v
Unverified for your environment
Select your OS to check compatibility.
1 Fix
Canonical Fix
Unverified Fix
New Fix – Awaiting Verification
Fix for: Sudo - is there a command to check if I have sudo and/or how much time is left?
Low Risk
I know this is a really old question but here is I did in a script today. Assuming that being sudo means being able to run any command as sudo (or, at least, uptime) However, if your user has restrictions in the , this check will not be enough, e.g.…
Awaiting Verification
Be the first to verify this fix
Sign in to verify this fix