使用StartSSL.com 免费证书在博客 

最近跟风SSL,便搞了一个SSL证书到自己的网站。

https://startssl.com/Certificates 注册会员,验证邮箱和域名。

然后申请 Class 1 (Not Validated) 的 DV SSL Certificate for Free User (Not Validated),这是给初级别用户的证书,因为不用验证身份证,拍照啥的。

1.Please enter the full hostname for SSL certificate (e.g: mail.domain.com):

输入自己的域名,可以是好几个子域名,换行隔开。

2.Please submit your Certificate Signing Request (CSR):

选择第一个 Generated by Myself。

在shell 执行 “openssl req -newkey rsa:2048 -keyout xxx.key -out xxx.csr ”,需要安装openssl 套件。

cat xxx.csr

把内容贴入下方的文本域,点击提交。

如下:

[root@xzx ssl]# openssl req -newkey rsa:2048 -keyout blog.key -out blog.csr
Generating a 2048 bit RSA private key
..............................................................................................................................................+++
..................+++
writing new private key to 'blog.key'
Enter PEM pass phrase:
Verifying - Enter PEM pass phrase:
-----
You are about to be asked to enter information that will be incorporated
into your certificate request.
What you are about to enter is what is called a Distinguished Name or a DN.
There are quite a few fields but you can leave some blank
For some fields there will be a default value,
If you enter '.', the field will be left blank.
-----
Country Name (2 letter code) [XX]:CN
State or Province Name (full name) []:Shanghai
Locality Name (eg, city) [Default City]:Shanghai
Organization Name (eg, company) [Default Company Ltd]:Sharl Jimh Tsin
Organizational Unit Name (eg, section) []:Sharl
Common Name (eg, your name or your server's hostname) []:xiazhengxin.name
Email Address []:xzx@xiazhengxin.name

Please enter the following 'extra' attributes
to be sent with your certificate request
A challenge password []:xiazhengxin
An optional company name []:
[root@xzx ssl]# cat blog.csr
-----BEGIN CERTIFICATE REQUEST-----
MIIC/zCCAecCAQAwgZ0xCzAJBgNVBAYTAkNOMREwDwYDVQQIDAhTaGFuZ2hhaTER
MA8GA1UEBwwIU2hhbmdoYWkxGDAWBgNVBAoMD1NoYXJsIEppbWggVHNpbjEOMAwG
A1UECwwFU2hhcmwxGTAXBgNVBAMMEHhpYXpoZW5neGluLm5hbWUxIzAhBgkqhkiG
9w0BCQEWFHh6eEB4aWF6aGVuZ3hpbi5uYW1lMIIBIjANBgkqhkiG9w0BAQEFAAOC
AQ8AMIIBCgKCAQEAt7s1Nhtmt5ZeIkOXnMeH3fFl1neUjxun/aqf52If5tTkpVqp
UuKpkzOk8nXOYiFfHsdhormo57bTuDdnG/e2mz5KXR0uE2k3zqMGGFvRfeRQHGTz
eI/xP1GhLTI8KWfN2VP9hjV6KOd992OJkceoQ+qr8wmOpt+QEbMXi7taA/q5eBEc
vjEEeFRT8V0yV6CZcylQaKAtmcM73iR5siPi8DJap4WAkKgNdlC+XymO1eDY4TDY
JzzPPDo88+6+Y6DwfbDRSEjDS40byA0SovkDShLYFkxa5vHgLWsrFGEZzgyxa4ob
Ih0VxyrEFCdFVaQlnVIL38OCBw0fdWaa5FmzbwIDAQABoBwwGgYJKoZIhvcNAQkH
MQ0MC3hpYXpoZW5neGluMA0GCSqGSIb3DQEBBQUAA4IBAQBBo5b03ATzyMjaEYfk
uSoZV3dGNydqZvcUUnaV4TxkZnjG3TntUmrCqF9lja9XqjaKk4gRClUQqivGes6S
DcfTfCcleenAhgvCAOafuhEMfK0fSx7X9c9+Mrtntmdcx8By0dhEekVRJIO2f0KE
LO19OzVCKCLcaqMwShEAjeRzfd63LhU79xFZqsPT3XgRQQJuUlId6MakbvGUTGej
1z5n+ty/uKsh/VJXIhhFrkY1rSSeSWf9qYHzQwag41XrJ9JUCS9+cLmEnGKdLmYi
Kg1/QAyTluxjYW2NVvshvbhgL5Kx+WnO9DZcghqyV8UxBDGr+sbTN6p0TmTfr+rS
mE0F
-----END CERTIFICATE REQUEST-----


跳转页面后就可以下载对应的 xxxxx.xxx.pem 文件。也可以到 首页 的 Tool Box 下面的 Certificate List 页面去下载。


170112183726840 xiazhengxin.name Class 1 SSL 2017-01-12 2020-01-12 Issued “下载按钮”


到这里,startssl 网站的工作就搞完了。把 pem 文件上传到自己的服务器,把它和自己的私钥合并。


[root@xzx ssl]# cat blog.key xiazhengxin.name.pem > ssl.pem
[root@xzx ssl]# cp ssl.pem /home/http/blog_xiazhengxin_name/
[root@xzx ssl]# cd /home/http/blog_xiazhengxin_name/
[root@xzx blog_xiazhengxin_name]# ll
total 92
drwxrwx--- 5 http web 4096 Apr 11 2011 admin
-rwxrwx--- 1 http web 1547 Apr 23 2013 config.inc.php
-rwxrwx--- 1 http web 53 Dec 1 2010 google7a48cd06bd7c1d66.html
-rwxrwx--- 1 http web 685 Jul 2 2009 index.php
-rwxrwx--- 1 http web 37235 Jun 21 2010 install.php
-rwxrwx--- 1 http web 15255 May 14 2008 license.txt
lrwxrwxrwx 1 http web 30 Nov 8 2014 pub -> ../static_xiazhengxin_name/pub
-rw-r--r-- 1 root root 4285 Jan 12 18:43 ssl.pem
drwxrwx--- 5 http web 4096 Apr 11 2011 usr
drwxrwx--- 5 http web 4096 Aug 15 2010 var
[root@xzx blog_xiazhengxin_name]# chmod 777 ssl.pem
[root@xzx blog_xiazhengxin_name]# chmod a-x ssl.pem


之后就是配置 lighttpd 了。确认编译lighttpd 的时候启用了 openssl 模块。


[root@xzx sbin]# ./lighttpd -V
lighttpd/1.4.35 (ssl) - a light and fast webserver
Build-Date: Nov 7 2014 02:06:04

Event Handlers:

+ select (generic)
+ poll (Unix)
- rt-signals (Linux 2.4+)
+ epoll (Linux 2.6)
- /dev/poll (Solaris)
- eventports (Solaris)
- kqueue (FreeBSD)
- libev (generic)

Network handler:

+ linux-sendfile
- freebsd-sendfile
- solaris-sendfilev
+ writev
+ write
- mmap support

Features:

+ IPv6 support
+ zlib support
+ bzip2 support
+ crypt support
+ SSL Support
+ PCRE support
+ mySQL support
- LDAP support
- memcached support
+ FAM support
- LUA support
+ xml support
+ SQLite support
+ GDBM support


编辑位于 etc 下面的 lighttpd.conf 文件,加入以下配置:

$SERVER["socket"] == ":443" {
ssl.engine = "enable"
ssl.pemfile = "/home/http/blog_xiazhengxin_name/ssl.pem"
server.name = "xiazhengxin.name"
server.document-root = "/home/http/blog_xiazhengxin_name"
}


重启 lighttpd,输入 密钥的短口令,启动成功。

[root@xzx blog_xiazhengxin_name]# service myservice start
*******starting Services*********
php-fpm Started
mysqld Started
NOW SLEEP 5 seconds for MySQL ready
170112 18:50:37 mysqld_safe Logging to '/var/log/mysqld.log'.
170112 18:50:37 mysqld_safe Starting mysqld daemon with databases from /var/mysql
vsftpd Started
Enter PEM pass phrase:
lighttpd Started
*******all services Started*********


访问 https://xiazhengxin.name/ 显示正常。就是由于是 Class 1 级别的SSL证书所以有警告。

注:文章撰写和实践时参考了一下连接
http://redmine.lighttpd.net/projects/li ... i/Docs_SSL
https://startssl.com/Support?v=33
wwwe 

<H1><a href="http://www.yeezyboost350v2.org.uk" title="yeezy boost 350 v2"><strong>yeezy boost 350 v2</strong></a></H1>
<H1><a href="http://www.russellwestbrookshoes.us" title="westbrook shoes"><strong>westbrook shoes</strong></a></H1>
<H1><a href="http://www.stephencurry-shoes.us.com" title="stephen curry shoes"><strong>stephen curry shoes</strong></a></H1>
<H1><a href="http://www.louboutinshoes.uk" title="louboutin shoes"><strong>louboutin shoes</strong></a></H1>
<H1><a href="http://www.patriotsjerseys.us.com" title="patriots jerseys"><strong>patriots jerseys</strong></a></H1>
<H1><a href="http://www.kobeshoes.uk" title="kobe byrant shoes"><strong>kobe byrant shoes</strong></a></H1>
普通H1标签
<H1><a href="http://www.nikeairforce1.us.com"><strong>nike air force 1</strong></a></H1>
<H1><a href="http://www.michaelkorshandbags.net.co"><strong>michael kors handbags</strong></a></H1>
<H1><a href="http://www.cartierbracelet.us"><strong>cartier bracelet</strong></a></H1>
<H1><a href="http://www.offwhiteclothing.us.com"><strong>off white clothing</strong></a></H1>
UBB
louboutin shoes
nike hyperdunk 2017
nike basketball shoes
adidas pure boost
A标签
<a href="http://www.adidassuperstar.us.com"><strong>adidas superstar</strong></a>
<a href="http://www.lebron-soldier11.us.com"><strong>nike lebron 11</strong></a>
<a href="http://www.nike-airmax90.uk"><strong>nike air max 90</strong></a>
<a href="http://www.adidasnmdrunner.us.com"><strong>adidas nmd</strong></a>
裸链
http://www.yeezys.us.org
http://www.yeezy-shoes.ca
http://www.yeezy-shoes.org
http://www.yeezy-shoes.org.uk


king 

cc0314
pandora charms
coach outlet online
adidas store
ugg canada
the north face outlet
ugg outlet online
ralph lauren uk
kate spade outlet store
michael kors outlet clearance
adidas outlet online
jordan shoes for sale
nba jerseys cheap
timberland outlet
ugg boots outlet
christian louboutin shoes
fitflops sale clearance
air max
oakley sunglasses outlet
birkenstock uk
canada goose
fred perry polo shirts
coach outlet store online
coach factory outlet online
kate spade outlet online
cheap air jordans
louboutin outlet
michael kors outlet
ugg boots
michael kors outlet online
cheap jordan shoes
kate spade handbags
adidas yeezy
michael kors outlet store
coach outlet online
moncler outlet online
vans outlet
kate spade handbags
fitflop sandals
adidas yeezy boost
cheap jordan shoes
prada outlet online
cheap air jordans
ugg outlet store
coach factory outlet online
michael kors
ugg boots
longchamp outlet store
coach factory outlet online
canada goose jackets
michael kors
canada goose jackets
coach outlet online
coach outlet store online clearance
adidas yeezy boost
retro 11
michael kors bags
louis vuitton outlet store
moncler uk
yeezy boost 350
michael kors handbags
coach outlet online
adidas outlet online
pandora jewelry
ferragamo outlet
ray ban sunglasses outlet
pandora charms
air jordans
polo ralph lauren outlet
coach factorty outlet store
uggs outlet
hermes outlet
air max 90
nike shoes
pandora charms outlet
pandora rings
cheap jordans
pandora jewelry
canada goose jackets
uggs on sale
polo ralph lauren outlet
discount ray ban sunglasses
coach outlet canada
red bottom
adidas outlet store
coach outlet online
gucci outlet
adidas campus shoes
polo ralph lauren outlet online
pandora outlet
pandora jewelry outlet
birkin handbags
cheap ray ban sunglasses
reebok outlet
red bottoms
polo ralph lauren outlet
harden vol 1
coach factory outlet online
coach outlet store online
kate spade outlet
adidas superstar shoes
nike sneakers
canada goose jackets
cheap nfl jerseys wholesale
moncler outlet online
pandora sale clearance
canada goose jackets
air jordan retro
nike outlet
coach outlet store
pandora jewelry store
nike outlet online
michael kors outlet store
michael kors outlet store
canada goose outlet online
valentino outlet
moncler jackets
coach outlet online
coach outlet online
cheap ugg boots
hermes bags
nike outlet online
bottes ugg
canada goose coats
burberry outlet
pandora charms sale clearance
ralph lauren outlet
pandora uk
canada goose jackets
pandora jewelry outlet
mbt shoes sale
adidas shoes
ralph lauren
michael kors outlet clearance
coach outlet online
puma outlet
fred perry shirts
canada goose coats
nfl jerseys
burberry outlet online
michael kors
michael kors outlet online
nike air max 2018
ugg boots
canada goose jackets
canada goose jackets
coach factory outlet online
canada goose
coach factory outlet online
hermes bags
canada goose sale
michael kors outlet
nike outlet store
columbia sportswear outlet
coach outlet store online
cheap air max
ralph lauren outlet online
fitflops sale clearance
yeezy shoes
converse outlet
ralph lauren sale
mbt
cheap nfl jerseys wholesale
kate spade outlet online
kate spade outlet online
timberland outlet store
coach outlet online
pandora jewelry
adidas superstars
moncler coats
ecco outlet
ugg outlet
supra for sale
kate spade outlet
christian louboutin shoes
adidas nmd r1
canada goose coats
tory burch outlet online
michael kors outlet store
polo ralph lauren
tory burch shoes
coach factory outlet
mulberry uk
michael kors outlet store
longchamps
polo ralph lauren outlet online
yeezy boost 350
mulberry handbags
supreme clothing
yeezy shoes
moncler coats
christian louboutin sale
michael kors outlet clearance
coach factory outlet
canada goose
moncler outlet online
uggs outlet
birkenstock outlet
ugg canada
birkenstock shoes outlet
mcm outlet store
ugg boots
cheap oakley sunglasses
prada shoes
adidas outlet store
philipp plein outlet
canada goose jackets
ralph lauren outlet online
ecco shoes for women
fitflops sale
fitflop sandals
supreme shirts
cheap jordans
polo ralph lauren
pandora charms
nike air max 97
burberry handbags
moncler
air jordan shoes
asics outlet
michael kors outlet canada
mbt
canada goose jackets
coach outlet online
adidas originals
michael kors bags
coach factory outlet
air max
rolex replica watches
ugg boots
ralph lauren uk
ralph lauren outlet online
ugg outlet store
ralph lauren
ray ban glasses
michael kors outlet online
ugg boots
coach outlet online
timberland outlet
ralph lauren sale
adidas nmd r1
pandora charms sale clearance
jordans
canada goose jackets
moncler sale
air max shoes
coach factory outlet online
adidas nmd r1
yeezy boost
nike outlet online
cheap jordans for sale
pandora charms outlet
birkenstock outlet store
valentino
cheap ugg boots
michael kors
moncler outlet online
yeezy boost 350
ugg boots women
burberry handbags
polo ralph lauren
adidas nmd r1
vans outlet store
moncler pas cher
tory burch outlet store
supreme uk
canada goose jackets
philipp plein
coach outlet online
burberry outlet online
pandora charms
coach outlet online
birkenstock sale
michael kors outlet store
coach outlet online
mulberry
adidas yeezy
longchamp bags
adidas yeezy boost
adidas sneakers
ugg boots
coach outlet online
ray bans
the north face jackets
fitflop shoes
birkenstock outlet
uggs outlet
pandora charms outlet
canada goose coats
polo ralph lauren outlet online
pandora uk
cheap jordans free shipping
yeezy boost 350
adidas nmd runner
ralph lauren uk
nmd adidas
ugg outlet
oakley sunglasses for women
ferragamo shoes
michael kors outlet canada
pandora charms outlet
fitflops sale
canada goose jacket
adidas ultra boost
canada goose jackets uk
moncler coats
canada goose jackets
canada goose parka
pandora charms sale
coach outlet online
cheap jordan shoes
ralph lauren outlet online
new balance outlet
canada goose
cheap oakley sunglasses
longchamp sale
canada goose sale
caterpillar boots
ugg outlet online
gucci outlet online
coach factory outlet online
hermens
kate spade handbags
mcm bags
coach outlet online
nike sneakers
tory burch handbags
adidas outlet
coach outlet online
nba jerseys wholesale
oakley sunglasses outlet
nike air max 97
louboutin outlet
ray ban sunglasses discount
birkenstock uk
birkenstock sale
cheap jordan shoes
air max outlet
ugg boots outlet
cheap jordan shoes
ray ban sunglasses sale
mlb jerseys
cheap nike shoes
adidas
pandora charms sale clearance
christian louboutin shoes
polo ralph lauren outlet
nike outlet store
ugg boots sale
louis vuitton outlet
new balance outlet store
nike zoom
kate spade outlet online
discount oakley sunglasses
moncler uk
birkenstock shoes
mulberry outlet uk
louis vuitton factory outlet
michael kors outlet online
louis vuitton factory outlet
canada goose outlet
coach outlet store
fitflops sale
yeezy shoes
nfl jerseys
moncler jacket
coach outlet store online
birkenstock sandals
canada goose sale
mlb jerseys cheap
cheap air jordans
north face outlet
uggs outlet
hermes bag
supra for sale
pandora jewelry
canada goose jackets
oakley sunglasses outlet
coach factorty outlet online
michael kors
coach factory outlet online
rolex replica watches for sale
moncler jackets
michael kors uk
coach factory outlet
canada goose coats
cheap ray ban sunglasses
adidas yeezy shoes
canada goose jackets
pandora charms sale
mlb jerseys wholesale
salvatore ferragamo outlet
cheap oakley sunglasses
uggs
adidas yeezy boost 350
skechers outlet
louis vuitton handbags
michael kors outlet online
ugg sale
supreme shirts
ralph lauren outlet
coach factory outlet online
hermes handbags
moncler jackets
coach outlet
coach outlet store online
cheap jordan shoes
timberland boots
pandora outlet
nike air max 2018
coach outlet store
converse all star
coach outlet canada
oakley sunglasses outlet
nike outlet store online
polo ralph lauren outlet online
louis vuitton outlet online
coach factorty outlet online
canada goose sale
canada goose coats
canada goose sale
canada goose jackets
red bottom heels
mlb jerseys cheap
salvatore ferragamo shoes
ralph lauren uk
adidas nmd runner
canada goose outlet store
ralph lauren
coach factory outlet
pandora charms sale clearance
michael kors outlet online
coach factory outlet online
canada goose
nfl jerseys
moncler sale
cheap oakley sunglasses
louboutin shoes
coach outlet online
longchamp bags
longchamp outlet
ralph lauren outlet online
jordan shoes
cc0314

评论

发表评论

填写下面的表单来发表您的评论。









插入标签: