diff --git a/cheat/jenkins.md b/cheat/jenkins.md index f763823..2d70422 100644 --- a/cheat/jenkins.md +++ b/cheat/jenkins.md @@ -2,7 +2,9 @@ Execute in https://*INSTANCE*/script to reveal passwords from a password hash (obtained via Inspect Element on a Credential) -`hudson.util.Secret.decrypt('secret_hash')` +```groovy +hudson.util.Secret.decrypt('secret_hash') +``` ### Jenkins current jobs @@ -11,7 +13,7 @@ https://*INSTANCE*/computer/api/json?tree=computer[executors[currentExecutable[* ### Reveal all secrets Execute in https://*INSTANCE*/script to reveal all secrets -``` +```groovy import com.cloudbees.plugins.credentials.CredentialsProvider import com.cloudbees.plugins.credentials.Credentials import com.cloudbees.plugins.credentials.domains.Domain