Skip to content

jscotka/postsignum_tool

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 

Repository files navigation

postsignum_tool

This tool helps you to create, send and merge certificates for Ceska posta postsignum via python. My usecase was to be able to use it with fedora linux

Usage

copy example config to your home dir cp postsignum_tool.ini ~/.postsignum_tool.ini and replace it with your variables. have structure with dirs based on years (tool will read the current year certificates to create new one)

2022/
  request.req
  privatekey.key
  certifikat.pem
  certifikat.p12

create dir for next year cert e.g. mkdir 2023; cd 2023 and call the tooling

# for generating keys
python3 ~/git/postsignum_tool/postsignum_tool/create.py

# for merging keys (you have to copy downloaded PEM file into this dir after postsignum set the key back)
python3 ~/git/postsignum_tool/postsignum_tool/merge.py

Prerequisities

Install packages

sudo dnf install python3 msmtp openssl git

Clone tooling into your home dir

mkdir -p ~/git/postsignum_tool
git clone https://github.com/jscotka/postsignum_tool.git ~/git/postsignum_tool

configure msmtp

you can use any post client what allow to send raw messages via pipe, depends on server requirements

For gmail account

# replace username and password

cat > ~/.msmtprc << EOL
    account [email protected]
    host smtp.gmail.com
    port 587
    tls on
    tls_starttls on
    auth on
    user username
    from [email protected]
    # https://myaccount.google.com/apppasswords
    password "user pass gene bygo"
    # default account
    account default : [email protected]
 
EOL

chmod 600 ~/.msmtprc

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages