This is an interactive CLI tool that helps to check and process the information of certificate and private key files, making it easy to apply the certificate to a web server.
A chain of trust is designed to allow multiple users to create and use software on the system, which would be more difficult if all the keys were stored directly in hardware. It starts with hardware that will only boot from software that is digitally signed. The signing authority will only sign boot programs that enforce security, such as only running programs that are themselves signed, or only allowing signed code to have access to certain features of the machine. This process may continue for several layers.
This process results in a chain of trust. The final software can be trusted to have certain properties, because if it had been illegally modified its signature would be invalid, and the previous software would not have executed it. The previous software can be trusted, because it, in turn, would not have been loaded if its signature had been invalid. The trustworthiness of each layer is guaranteed by the one before, back to the trust anchor.
It would be possible to have the hardware check the suitability (signature) for every single piece of software. However, this would not produce the flexibility that a "chain" provides. In a chain, any given link can be replaced with a different version to provide different properties, without having to go all the way back to the trust anchor. This use of multiple layers is an application of a general technique to improve scalability, and is analogous to the use of multiple certificates in a certificate chain.
# [install]
brew tap ghdwlsgur/gossl
brew install gossl
# [upgrade]
brew upgrade gossl
The tool displays a list of files with extensions ending in pem, crt, ca, csr, cer, and key
in the current directory as options. If a single certificate file is selected, it indicates whether it is a chain certificate, root certificate, or domain certificate, and shows the Md5 Hash
value, expiration date
, Subject
and Issuer
information, and Verify Host
. If the certificate is a domain certificate, it also provides additional information on Subject Alternative Name
.
The option is provided to convert a crt
file to pem
format.
gossl echo
When you select each individual file of domain certificate, chain certificate, and root certificate, it combines them into one certificate file in the order of domain certificate, chain certificate, and root certificate.
gossl merge -n [fileName]
Shows the order in which the domain certificate, chain certificate, and root certificate are composed into a single certificate file, or splits the file into separate files named according to the type of certificate, such as gossl_internetiate_1.crt
, gossl_leaf_1.crt
, and gossl_root_1.crt
, so that the type of each certificate can be identified.
gossl split # make file
gossl split show # not make file
When a private key is password-protected, it prompts for the password and replaces the original key with an unencrypted one.
gossl unlock
Compresses each file into a single archive.
gossl zip -n [fileName]
Decompresses the compressed file.
gossl unzip -n [fileName]
If the domain uses a CDN, it retrieves the domain certificate information applied to each edge device. If not, it retrieves the domain certificate information applied to the origin server.
gossl validate -n [domain]
It retrieves the certificate information applied to the domain.
gossl check [domain]
If you select one of the root certificates provided by gossl, it will be downloaded to the current directory.
gossl download
gossl is licensed under the MIT