TiledViz
Toggle main menu visibility
Loading...
Searching...
No Matches
build_pem.py
1
#!/usr/bin/python3
2
import
pexpect, re, sys
3
4
cmdgen=
"openssl req -new -x509 -days 1 -nodes -out self.pem -keyout self.pem"
5
6
childgen=pexpect.spawnu(cmdgen)
#, logfile=sys.stdout.buffer)
7
childgen.logfile=sys.stdout
8
#childgen.setecho(True)
9
#expindex=childgen.expect('Generating a RSA private key')
10
11
#expindex=childgen.expect(r".*Country Name \(2 letter code\) \[.*\]:")
12
#if (expindex == 0):
13
14
outpass = childgen.sendline(
r'FR'
)
15
16
#expindex=childgen.expect('State or Province Name (full name) [Some-State]:')
17
#if (expindex == 0):
18
19
outpass = childgen.sendline(
r'France'
)
20
21
#expindex=childgen.expect('Locality Name (eg, city) []:')
22
#if (expindex == 0):
23
24
outpass = childgen.sendline(
r'Paris'
)
25
26
#expindex=childgen.expect('Organization Name (eg, company) [Internet Widgits Pty Ltd]:')
27
#if (expindex == 0):
28
29
outpass = childgen.sendline(
r'CNRS'
)
30
31
#expindex=childgen.expect('Organizational Unit Name (eg, section) []:')
32
#if (expindex == 0):
33
34
outpass = childgen.sendline(
r'MDLS'
)
35
#child.send ('\x20')
36
#expindex=childgen.expect('Common Name (e.g. server FQDN or YOUR name) []:')
37
#if (expindex == 0):
38
39
outpass = childgen.sendline(
r'Mancip'
)
40
41
#expindex=childgen.expect('Email Address []:')
42
#if (expindex == 0):
43
44
outpass = childgen.sendline(
r'Martial.Mancip@MaisondelaSimulation.fr'
)
45
46
try
:
47
childgen.expect(pexpect.EOF)
48
except
:
49
pass
50
childgen.close(force=
True
)
51
TVConnections
mageianconnect
build_pem.py
Documentation for
TiledViz
$tiledvizversion