Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
slapos
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
HongzheWang
slapos
Commits
fde3d5b0
Commit
fde3d5b0
authored
Nov 23, 2011
by
Cédric de Saint Martin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Revert "Use different common_name for openssl"
This reverts commit
320f0265
.
parent
2f677902
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
6 deletions
+3
-6
slapos/recipe/kvm/__init__.py
slapos/recipe/kvm/__init__.py
+3
-5
slapos/recipe/kvm/template/openssl.cnf.ca.in
slapos/recipe/kvm/template/openssl.cnf.ca.in
+0
-1
No files found.
slapos/recipe/kvm/__init__.py
View file @
fde3d5b0
...
@@ -34,7 +34,6 @@ import zc.buildout
...
@@ -34,7 +34,6 @@ import zc.buildout
import
pkg_resources
import
pkg_resources
import
ConfigParser
import
ConfigParser
import
hashlib
import
hashlib
import
uuid
class
Recipe
(
BaseSlapRecipe
):
class
Recipe
(
BaseSlapRecipe
):
...
@@ -56,9 +55,9 @@ class Recipe(BaseSlapRecipe):
...
@@ -56,9 +55,9 @@ class Recipe(BaseSlapRecipe):
self
.
cron_d
=
self
.
installCrond
()
self
.
cron_d
=
self
.
installCrond
()
# XXX-Cedric: Cert is self-signed and issuer is randomly generated.
# XXX-Cedric: Cert is self-signed and issuer is randomly generated.
ca_com
mon_name
=
'SlapOS KVM root %s'
%
uuid
.
uuid1
(
)
ca_com
pany
=
binascii
.
hexlify
(
os
.
urandom
(
10
)
)
self
.
ca_conf
=
self
.
installCertificateAuthority
(
self
.
ca_conf
=
self
.
installCertificateAuthority
(
ca_company
=
ca_com
mon_name
)
ca_company
=
ca_com
pany
)
self
.
key_path
,
self
.
certificate_path
=
self
.
requestCertificate
(
'noVNC'
)
self
.
key_path
,
self
.
certificate_path
=
self
.
requestCertificate
(
'noVNC'
)
# Install the socket_connection_attempt script
# Install the socket_connection_attempt script
...
@@ -268,7 +267,7 @@ class Recipe(BaseSlapRecipe):
...
@@ -268,7 +267,7 @@ class Recipe(BaseSlapRecipe):
def
installCertificateAuthority
(
self
,
ca_country_code
=
'XX'
,
def
installCertificateAuthority
(
self
,
ca_country_code
=
'XX'
,
ca_email
=
'xx@example.com'
,
ca_state
=
'State'
,
ca_city
=
'City'
,
ca_email
=
'xx@example.com'
,
ca_state
=
'State'
,
ca_city
=
'City'
,
ca_company
=
'Company'
,
ca_common_name
=
"CommonName"
):
ca_company
=
'Company'
):
backup_path
=
self
.
createBackupDirectory
(
'ca'
)
backup_path
=
self
.
createBackupDirectory
(
'ca'
)
self
.
ca_dir
=
os
.
path
.
join
(
self
.
data_root_directory
,
'ca'
)
self
.
ca_dir
=
os
.
path
.
join
(
self
.
data_root_directory
,
'ca'
)
self
.
_createDirectory
(
self
.
ca_dir
)
self
.
_createDirectory
(
self
.
ca_dir
)
...
@@ -296,7 +295,6 @@ class Recipe(BaseSlapRecipe):
...
@@ -296,7 +295,6 @@ class Recipe(BaseSlapRecipe):
city
=
ca_city
,
city
=
ca_city
,
company
=
ca_company
,
company
=
ca_company
,
email_address
=
ca_email
,
email_address
=
ca_email
,
common_name
=
ca_common_name
,
)
)
self
.
_writeFile
(
openssl_configuration
,
pkg_resources
.
resource_string
(
self
.
_writeFile
(
openssl_configuration
,
pkg_resources
.
resource_string
(
__name__
,
'template/openssl.cnf.ca.in'
)
%
config
)
__name__
,
'template/openssl.cnf.ca.in'
)
%
config
)
...
...
slapos/recipe/kvm/template/openssl.cnf.ca.in
View file @
fde3d5b0
...
@@ -145,7 +145,6 @@ localityName_value = %(city)s
...
@@ -145,7 +145,6 @@ localityName_value = %(city)s
#1.organizationName_default = World Wide Web Pty Ltd
#1.organizationName_default = World Wide Web Pty Ltd
commonName = Common Name (eg, your name or your server\'s hostname)
commonName = Common Name (eg, your name or your server\'s hostname)
commonName_value = %(common_name)s
commonName_max = 64
commonName_max = 64
emailAddress = Email Address
emailAddress = Email Address
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment