CertGenerator
Python module to generate key, certificate request, self signed certificate and p12 certificate
Information
This can be used only with python2.7
Getting started
required modules:
Click
pyOpenSSL
pycparser
PyYAML
Installing package using pip
$ pip install CertGenerator
Usage
Usage: cert [OPTIONS] COMMAND [ARGS]... A command line tool to create and read CSR and P12 Options: -V, --version show version and exit -h, --help Show this message and exit. Commands: config Edit or read config ini create Create a single CSR create-multiple Create multiple certificate using csv file create-multiple-p12 Create multiple p12 using csv file create-p12 Create a simple p12 Need key file and pem file init Create or edit certificate folder and csv file Add... read Read csr or p12
PRE-CONFIGURATION
Configuration files
serial |
|---|
test1 |
test2 |
test3 |
config.ini
- Create default folder
May require sudo
Default folder => $HOME/Documents/CertGenerator/
copy default csv file to $HOME/Documents/CertGenerator/csv/serial.csv
copy yaml file to $HOME/Documents/CertGenerator/csr.yaml
$ sudo cert init
- To change default folder or default csv:
May require sudo
$ sudo cert init -cert [path/of/folder] -csv [path/of/csv/file]
or
$ sudo cert config edit -cert [path/of/folder] -csv [path/of/csv/file]
- To edit yaml file:
Enter the desired subject
Enter “-” to keep empty
If you want to create multiple csr using serial.csv, don’t use Commmon Name => just enter “-” to keep empty
Note: You always have old csr.yaml in folder under format csr.yam_[date od modification]
$ cert config edit-yaml
CONFIGURATION
Create csr
Create one csr
Use -c if you want to use csr.yaml to create csr
Use -f to overwrite existing csr
The key and csr files will be created in {folder}/certificate/csr/
- Example: With the command below it will create
{folder}/certificate/csr/test/test.csr
{folder}/certificate/csr/test/test.key
$ cert create test -c [-f]
Create multiple csr
Use -c if you want to use csv file and csr.yaml
Use -f to overwrite existing csr
* cert create-multiple -c [-f]
Create p12
Create one p12
You need pem file and key file:
Use -f to overwrite existing p12
$ cert create-p12 test.p12 [-f] --pem [path/of/pem file] --key [path/of/key file] -pass [password(default:3z6F2Xfc)]
Create multiple p12
for creating multiple p12: pem file, key file and p12 must have the same name
Use -f to overwrite existing p12
- Example if you create test1.p12 test2.P12 …:
In the csv file, you must have test1 test2 …
The pem files must be test1.pem test2.pem …
The key files must be test1.key test2.key …
It will search key files in folder/certificate/csr/
$ cert create-multiple-p12 -c [-f] --pem-folder [path/of/pem folder]
If you want to use an other folder to search key files, add –key-folder:
$ cert create-multiple-p12 -c [-f] --pem-folder [path/of/pem folder] --key-folder [path/of/key folder]
ChangeLog
see changes
Links
Metadata
Release files for CertGenerator 2.2.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| CertGenerator-2.2.1.tar.gz | 18.3 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| CertGenerator-2.2.1-py2-none-any.whl | Python 2 | none | any | Details |
Total release size: 38.8 kB
Release files / CertGenerator-2.2.1.tar.gz
| Download URL | CertGenerator-2.2.1.tar.gz |
|---|---|
| Size | 18.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
b00adcf9844bcec52590302e127450de5a826c8ce8948cbc84567d8383d009af
|
|
BLAKE2b-256 checksum How to use checksums |
33bfe7c14f83691924b4c190d2a823eb48d987e577985c1cd7738e8641eb9e2c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.4.2 requests/2.20.1 setuptools/40.6.2 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/2.7.10
|
Release files / CertGenerator-2.2.1-py2-none-any.whl
| Download URL | CertGenerator-2.2.1-py2-none-any.whl |
|---|---|
| Size | 20.5 kB |
| Tags | Python 2 |
|
SHA-256 checksum How to use checksums |
bcea075a9942791aaa13ae41308589f52f5f8757a7aaae9c66f20868d92a92c5
|
|
BLAKE2b-256 checksum How to use checksums |
ee7359822f8f78fd72a32096f55d5cf44f0501404d5b72c54fca189cca47d9f7
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.4.2 requests/2.20.1 setuptools/40.6.2 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/2.7.10
|
Security for CertGenerator 2.2.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.