Browse Source

fixed cert generation

master
Robin Thoni 8 years ago
parent
commit
05d6419d16
1 changed files with 3 additions and 2 deletions
  1. 3
    2
      vpngen.py

+ 3
- 2
vpngen.py View File

4
 import os.path
4
 import os.path
5
 import re
5
 import re
6
 import shutil
6
 import shutil
7
+from enum import Enum
7
 from subprocess import call
8
 from subprocess import call
8
 
9
 
9
 
10
 
10
-class VpnGenError:
11
+class VpnGenError(Enum):
11
     Success = 0,
12
     Success = 0,
12
     VpnAlreadyExists = 1,
13
     VpnAlreadyExists = 1,
13
     VpnDoesNotExists = 2,
14
     VpnDoesNotExists = 2,
164
 
165
 
165
         call([".%sclean-all" % os.sep])
166
         call([".%sclean-all" % os.sep])
166
         call([pkitool, "--initca"])
167
         call([pkitool, "--initca"])
167
-        call([pkitool, "server"])
168
+        call([pkitool, "server", "-batch"])
168
         call([".%sbuild-dh" % os.sep])
169
         call([".%sbuild-dh" % os.sep])
169
         call(["openssl", "ca", "-gencrl",
170
         call(["openssl", "ca", "-gencrl",
170
               "-keyfile", "keys%sca.key" % os.sep,
171
               "-keyfile", "keys%sca.key" % os.sep,

Loading…
Cancel
Save