Advertisement

05.29.2008 at 07:38AM PDT, ID: 23441545
[x]
Attachment Details

Creating extra keys for OpenVPN

Asked by edz_pgt in Virtual Private Networking (VPN), Miscellaneous Security, Windows Batch Scripting

Tags: ,

I've sucessfully created a couple of OpenVPN tunnels and I'm trying to move the project forward and use it in the real world. However, no matter how much I seem to search, I can't find any reference to how to create additional keys for the OpenVPN system.

I've seen a method of revoking keys, but can anyone tell me how to create new ones?

I've tried working it out myself, but I'm getting an error. I'm using Windows based systems, and this is where I've got to:
1. At a command prompt, I've navigated to C:\program files\openvpn\easy-rsa
2. Run the batch file 'vars.bat'
3. Run the command 'build-key newuser1'
The system rthen returns the following error:

'openssl' is not recognized as an internal or external command,
operable program or batch file.
'openssl' is not recognized as an internal or external command,
operable program or batch file.
Could Not Find C:\Program Files\OpenVPN\easy-rsa\keys\*.old

There is a file within this directory called openssl.cnf but i'm not sure that this is what the batch file is trying to address. The build-key batch file looks like this:

@echo off
cd %HOME%
rem build a request for a cert that will be valid for ten years
openssl req -days 3650 -nodes -new -keyout %KEY_DIR%\%1.key -out %KEY_DIR%\%1.csr -config %KEY_CONFIG%
rem sign the cert request with our ca, creating a cert/key pair
openssl ca -days 3650 -out %KEY_DIR%\%1.crt -in %KEY_DIR%\%1.csr -config %KEY_CONFIG%
rem delete any .old files created in this process, to avoid future file creation errors
del /q %KEY_DIR%\*.old

Any ideas? Am I barking up the wrong tree?

Start Free Trial
 
Loading Advertisement...
 
[+][-]05.29.2008 at 08:51AM PDT, ID: 21670296

View this solution now by starting your 7-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

 

About this solution

Zones: Virtual Private Networking (VPN), Miscellaneous Security, Windows Batch Scripting
Tags: Open Source, OpenVPN
Sign Up Now!
Solution Provided By: arnold
Participating Experts: 1
Solution Grade: A
 
 
[+][-]05.29.2008 at 09:03AM PDT, ID: 21670463

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
 
Loading Advertisement...
20080716-EE-VQP-32 / EE_QW_2_20070628