Skip to content

Go-based tool for checking domain SSL support

License

Notifications You must be signed in to change notification settings

cdukes/ssl-support-checker

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

SSL Support Checker

This package contains two functions to a) check whether a URL's domain supports SSL and b) automatically upgrade a URL string to SSL if supported.

import checker "github.com/cdukes/ssl-support-checker"

u, _ := url.Parse("http://example.com")
log.Print(checker.SupportsSSL(u)) // false
log.Print(checker.MaybeUpgradeURL("http://example.com")) // http://example.com

u, _ = url.Parse("http://google.com")
log.Print(checker.SupportsSSL(u)) // true
log.Print(checker.MaybeUpgradeURL("http://google.com"))  // https://google.com

Uses DuckDuckGo Smarter Encryption (Docs)

About

Go-based tool for checking domain SSL support

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages