import jenkins.model.*
import hudson.util.Secret

def jenkins = Jenkins.getInstance()
def hudsonSecret = jenkins.getSecretKey()

// Replace this with your encrypted password
def encryptedPassword = 'yourEncryptedPassword'

def decryptedPassword = Secret.fromString(encryptedPassword).getPlainText()
println("Decrypted password: " + decryptedPassword)

