0

I am config the ssl using Mechanize, according the document I need to set the

agent.cert = 'example.cer'
agent.key='example.cer'

but how can I get these two file? I also find that ssl file has a lot of types, such as .cer .pem .crt .key, what is the relationship between them?

roger
  • 9,063
  • 20
  • 72
  • 119
  • Stack Overflow is a site for programming and development questions. This question appears to be off-topic because it is not about programming or development. See [What topics can I ask about here](http://stackoverflow.com/help/on-topic) in the Help Center. Perhaps [Super User](http://superuser.com/) or [Unix & Linux Stack Exchange](http://unix.stackexchange.com/) would be a better place to ask. – jww Apr 09 '15 at 18:57

1 Answers1

0

Let's start from PEM files, which are your digital certificates written in form encoded in only basic ASCII characters, they can be easily copy&pasted, e-mailed, printed. More about them:

The file with .crt extension is PEM or DER, which is just binary encoded certificate. This extension is recognized by Windows, while PEM or DER aren't.

The file with .key extension is just your private key. It's stored in separate file. Format not standardized.

You will find more information about all these formats in the answer on serverfault: What is a PEM file and how does it differ from other OpenSSL generated key file formats?

Community
  • 1
  • 1
Michał Fita
  • 1,183
  • 1
  • 7
  • 24