Coder Social home page Coder Social logo

ca-scripts's Introduction

##################
## HOW TO START ##
##################

- Clone the repo and start the steps

git clone https://github.com/math3matical/ca-scripts.git
cd ca-scripts


################
## HOW TO RUN ##
################

- There are 3 scripts to run, which will create the root ca, the intermediate ca, and then the server certificate:

ruby root.ca.rb
ruby intermediate.ca.rb
ruby server.cert.rb

- There is 1 script to run to change the name of the server certificate in case you have multiple certificates you need to create:

ruby change.server.rb


##############
## SETTINGS ##
##############

- The root ca, intermediate ca and the server certificate all get their settings from the `current_directory`/settings directory:

`current_directory`/settings/root.ca.conf
`current_directory`/settings/intermediate.ca.conf
`current_directory`/settings/server.cert.conf

- These can be changed at user's discretion.  Out of the box this will create all the certificates with the default setting.
- The most important settings to change are the server certificate if you are creating multiple server certificates with the intermediate certificate.  The 2 settings that need changing are:

common_name
srv_fqdn


############
## LAYOUT ##
############

- The root ca will be stored in the root ca directory:

`current_directory`/ca/

- The intermediate ca will be created withint the root ca directory, with the given name of the intermediate directory found in the intermediate.ca.conf file, e.g.:

`current_directory`/ca/intermediate/

- The server certificate, server private key, and the ca-bundle will be created and stored inside the intermediate directory, e.g.:

`current_directory`/ca/intermediate/certs/ca-bundle.cert.pem
`current_directory`/ca/intermediate/certs/satellite.example.com.cert.pem
`current_directory`/ca/intermediate/private/satellite.example.com.key.pem

ca-scripts's People

Contributors

math3matical avatar waldirio avatar

Watchers

 avatar

ca-scripts's Issues

Fixing some path issues

Fixing some path issues, I can see that the script is hard-coding the /var, and when creating an article, it's a bit hard.

Improving it a little bit.
Waldirio

Doubt about the usage

@math3matical

When calling the server.cert.rb, I can see the question mark

% ruby server.cert.rb                                         
Is the server fqdn " satellite.example.com"?

-e CREATING SERVER CERTIFICATE PRIVATE KEY
  (NOTE, NO PASSWORD USED HERE):
-e 
You are about to be asked to enter information that will be incorporated
into your certificate request.
What you are about to enter is what is called a Distinguished Name or a DN.
There are quite a few fields but you can leave some blank
For some fields there will be a default value,
If you enter '.', the field will be left blank.
-----
Country Name (2 letter code) [NA]:

Is that supposed to stop there and change, in case the information is wrong? Or just a simple notification?

Thank you!
Waldirio

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.