Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Ignore SSL certs in groovy
def nullTrustManager = [
checkClientTrusted: { chain, authType -> },
checkServerTrusted: { chain, authType -> },
getAcceptedIssuers: { null }
def nullHostnameVerifier = [
verify: { hostname, session ->
] sc ="SSL")
sc.init(null, [nullTrustManager as] as[], null) as
def url = new URL('https://mysecureserver')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.