Académique Documents
Professionnel Documents
Culture Documents
Autor: Henry Renderos Organizacin: Universidad de El Salvador Departamento de Ingeniera y Arquitectura Facultad Multidisciplinaria de Occidente Santa Ana El Salvador - CA
Este documento no est estructurado con una explicacin detallada de cada uno de los elementos de los protocolos, sino nada ms para establecer la configuracin bsica para hacer funcionar un servidor Web con DNS y Certificados Ssl. Todo el software utilizado es Software Libre. Debian Wheezy Apache2 Bind9 OpenSSL
INSTALACIN Y CONFIGURACIN
NOTA: si no tienes una conexin IPv6 debers usar un tnel
creando primero una cuenta en http://www.gogo6.com/ y aadirte al
servidor de Montreal
o Amsterdam. Tambin recuerda l
as herramientas y comandos.
#ifconfig #digxdireccinIPv6 #digtudominio.com.svAAAA
[gogoc]
#aptgetinstallgogoc
CONFIGURACIN [gogoc]
#nano/etc/gogoc/gogoc.conf
************************************************ ... ... ... userid=tuUsuarioDeGogo6 passwd=tuContraseaDeGogo6 ... ... server=authenticated.freenet6.net ... ... auth_method=pl
ain ************************************************ [bind9]
#aptgetinstallbind9 #aptgetinstalldnsutils
CONFIGURACIN [bind]
#nano/etc/bind/named.conf.local
************************************************ zone "tudominio.com.sv" { type master; fil
e "/etc/bind/db.tudominio"; }; zone //Col
oca ac tu direccin ipv6 sin el
l
timo nibbl
e "0.0.0.0.0.0.0.0.0.0.0.0.b.0.0.0.0.0.0.1.0.c.5.0.1.0.0.2.ip6.arpa" { type master; fil
e "/etc/bind/db.revtudominio"; }; ************************************************
#nano/etc/bind/db.tudominio
************************************************ ; ; BIND data fil
e for tun interface ; $TTL 604800 @ IN SOA tudominio.com.sv. admin.tudominio.com.sv. ( 2 ; Serial
604800 ; Refresh 86400 ; Retry 2419200 ; Expire 604800 ) ; Negative Cache TTL ; @ IN NS tudominio.com.sv. @ IN AAAA 2001:5c0:1000:b::cf49 ;ipv6 de l
a interfaz tun dns1 IN AAAA 2001:5c0:1000:b::cf49 ;ipv6 de l
a interfaz tun *************************************************
#nano/etc/bind/db.revtudominio
************************************************* ; ; BIND reverse data fil e for tun interface ; $TTL 604800 @ IN SOA tudominio.com.sv. admin.tudominio.com.sv. ( 1 ; Serial 604800 ; Refresh 86400 ; Retry 2419200 ; Expire 604800 ) ; Negative Cache TTL ; @ IN NS tudominio.com.sv. 9.4.f.c IN PTR tudominio.com.sv. ;9.4.f.c es el l timo nibbl e de nuestra direccin ipv6 de l a interfaz tun **************************************************
[apache]
#aptgetinstallapache2mpmprefork #aptgetinstallapache2utils
CONFIGURACIN [apache]
#nano/etc/apache2/ports.conf
*************************************************** #[ipv6 de l
a interfaz tun]:puerto NameVirtual
Host [2001:5c0:1000:b::cf49]:80 Listen 80 <IfModul
e mod_ssl
.c> # If you add NameVirtual
Host *:443 here, you wil
l
al
so have to change # the Virtual
Host statement in /etc/apache2/sites-avail
abl
e/defaul
t-ssl
# to <Virtual
Host *:443> # Server Name Indication for SSL named virtual
hosts is currentl
y not # supported by MSIE on Windows XP. Listen 443 </IfModul
e> <IfModul
e mod_gnutl
s.c> Listen 443 </IfModul
e> **************************************************** - Desabil
itamos l
os 2 sitios por defecto (defaul
t y defaul
t-ssl
)
#a2dissitedefault #a2dissitedefaultssl #/etc/init.d/apache2reload #/etc/init.d/apache2restart
***************************************************** # [ipv6 de l a interfaz tun]:puerto <Virtual Host [2001:5c0:1000:b::cf49]:80> ServerAdmin admin@tudominio.com.sv # Nombre del servidor ServerName tudominio.com.sv # Lugar donde guardars el sitio DocumentRoot /var/www/tudominio/publ ic_html / # Archivos de l og ErrorLog /var/www/tudominio/l ogs/error.l og CustomLog /var/www/tudominio/l ogs/access.l og combined </Virtual Host> ******************************************************
******************************************************* <html
> <head> <titl
e>Tu Dominio</titl
e> </head> <body> <h1>Es mejor si es Software Libre</h1> </body> </html
> ******************************************************* - Habil
itamos el
sitio
#a2ensitetudominio #/etc/init.d/apache2reload #/etc/init.d/apache2restart
[openssl
]
#aptgetinstallopenssl #aptgetinstallsslcert
- Creamos l
a l
l
ave
#opensslgenrsa2048>/etc/ssl/private/nombrellave.key
- Nos pedir al
guna informacin para compl
etar l
a informacin del
Certificado [Apache - HTTPS]
#nano/etc/apache2/sitesavailable/tudominiossl
********************************************************* <IfModul e mod_ssl .c> # [IPv6 de l a interfaz tun]:puerto <Virtual Host [2001:5c0:1000:b::cf49]:443> ServerAdmin admin@tudominio.com.sv ServerName tudominio.com.sv DocumentRoot /var/www/tudominio/publ ic_html <Directory /> Options Fol l owSymLinks Al l owOverride None </Directory>
<Directory /var/www/tudominio/publ
ic_html
> Options Indexes Fol
l
owSymLinks Mul
tiViews Al
l
owOverride None Order al
l
ow,deny al
l
ow from al
l
</Directory> ScriptAl
ias /cgi-bin/ /usr/l
ib/cgi-bin/ <Directory "/usr/l
ib/cgi-bin"> Al
l
owOverride None Options +ExecCGI -Mul
tiViews +SymLinksIfOwnerMatch Order al
l
ow,deny Al
l
ow from al
l
</Directory> ErrorLog ${APACHE_LOG_DIR}/error.l
og LogLevel
debug CustomLog ${APACHE_LOG_DIR}/ssl
_access.l
og combined SSLEngine on # ACA VAN LAS DIRECCIONES DE LA LLAVE Y DEL CERTIFICADO SSLCertificateFil
e /home/usuario/certificado.pem SSLCertificateKeyFil
e /etc/ssl
/private/nombre-l
l
ave.key <Fil
esMatch "\.(cgi|shtml
|phtml
|php)$"> SSLOptions +StdEnvVars </Fil
esMatch> <Directory /usr/l
ib/cgi-bin> SSLOptions +StdEnvVars </Directory> BrowserMatch "MSIE [2-6]" \ nokeepal
ive ssl
-uncl
ean-shutdown \ downgrade-1.0 force-response-1.0 BrowserMatch "MSIE [17-9]" ssl
-uncl
ean-shutdown </Virtual
Host> </IfModul
e> ************************************************************* - Habil
itamos el
sitio con ssl
#a2ensitetudominiossl #/etc/init.d/apache2reload #/etc/init.d/apache2restart