Certify is a simple utility to create self-signed certificates for SSL/TLS to work on networks that do not have a public domain, like an HTTP server on a private network or your computer (localhost).
- Written in shell script and compiled with SHC (Shell Script Compiler) for distribution.
- This has been repurposed mainly for Linux, but feel free to adjust it for MacOS.
- It will not work on WindowsPC unless you use the Windows Subsystem for Linux (WSL).
openssl
- To generate RSA keys for the certificates.1tar
- For packing the certificates into an archive file.2make
- To easily run execution scripts on the project.3shc
- For compiling the script for use and/or distribution.4
After cloning this repository to your workspace, first build the program:
make
make install
Optionally, to relax security. Make a redistributable binary (anyone can use it):
make dist
make install
Installing will require elevated permission (and may prompt you to authorise the action).
All installation does is create a symlink within /usr/local/bin
to the project directory bin
location, so that you can use the command certify
globally, at any location.
Simply running this on its own will present the user with an introduction to usage:
certify
For the moment, the arguments cannot contain spaces. An example would be:
certify home.local GB England London Acme.org
A version check for openssl
and tar
will take place on execution.
To uninstall the utility, type:
make uninstall
- Arguments string cannot contain spaces.
- Organisation Unit parameter5 fails. Has been omitted until the above issue works.
- Opens output folder with
dolphin
(as I currently use Debian). Expand to detect GUI - Improve help functionality.
- The user cannot choose output directory for the archive.
- Could "zip" be a better archiver for accessibility?
I originally wrote this utility to help toward resolving web browser security validation warnings when building web applications, via NGINX.
When people noticed this difference, and asked for a copy of the tool, I made an effort to passed it through a compiler to protect the source code and prevent other employees messing with it, or worse, claiming credit for coming up with it. Yes, it was that kind of place.
Now, I am happy to freely share this code for people to comment, learn, or improve upon.
Footnotes
-
OpenSSL Cryptography and SSL/TLS Toolkit - https://www.openssl.org ↩
-
Tar - GNU Project - Free Software Foundation - https://www.gnu.org/software/tar/ ↩
-
Make - GNU Project - Free Software Foundation- https://www.gnu.org/software/make/ ↩
-
Shell script compiler (shc) - https://neurobin.org/projects/softwares/unix/shc/ ↩
-
RFC 1779: A String Representation of Distinguished Names - https://www.rfc-editor.org/rfc/rfc1779#section-2.2 ↩