Re: Apache2 servidor seguro SSL
On 4/27/05, a a <vasura@gmail.com> wrote:
> On 4/27/05, a a <vasura@gmail.com> wrote:
> > On 4/26/05, mario <debian@estilorural.com> wrote:
> > > El mar, 26-04-2005 a las 16:06 +0200, 31 escribió:
> > > > mario escribió:
> > > >
> > > > >El jue, 21-04-2005 a las 14:01 +0200, 31 escribió:
> > > > >
> > > > >
> > > > >>He estado intentando poner a andar un servidor seguro https, siguiendo
> > > > >>estes manuales
> > > > >>http://lists.debian.org/debian-apache/2004/09/msg00105.html
> > > > >>http://www.ilovett.com/node/126/
> > > > >>
> > > > >>Pero no consiguo hacerlo funcionar, me termina por dar este error:
> > > > >>
> > > > >>xuvenka:/etc/apache2/sites-enabled# /etc/init.d/apache2 restart
> > > > >>Forcing reload of web server: Apache2 ... no pidfile found! not
> > > > >>running?(98)Address already in use: make_sock: could not bind to address
> > > > >>[::]:443
> > > > >>no listening sockets available, shutting down
> > > > >>Unable to open logs
> > > > >>xuvenka:/etc/apache2/sites-enabled#
> > > > >>
> > > > >>No tengo muy claro como ponen las configuraciones en sites-enabled, yo
> > > > >>tengo dos archivos (enlaces) default y default-ssl y pongo en uno lo de
> > > > >>
> > > > >>NameVirtualHost *:80
> > > > >>NameVirtualHost *:443
> > > > >><VirtualHost *:80>
> > > > >> ServerAdmin webmaster@localhost
> > > > >>
> > > > >> DocumentRoot /var/www/
> > > > >> <Directory />
> > > > >>[...]
> > > > >>
> > > > >>
> > > > >>Y en el otro (default-ssl) ya no le pongo nada de NameVirtualHost, ya lo
> > > > >>he probado y me dan errores... ¿alguien tiene funcionando el apache2 ssl
> > > > >>en debian? ¿como se configura?
> > > > >>
> > > > >>
> > > > >>
> > > > >
> > > > >Yo segui este MINI-manual:
> > > > >
> > > > >http://www.ianmiller.net/article.php?id=13
> > > > >
> > > > >y en 10 minutos ya estaba tirando...
> > > > >
> > > > >en el fichero ports.conf añadiste el 443???
> > > > >[......]
> > > > >Add a
> > > > >Listen 443
> > > > >to /etc/apache2/ports.conf
> > > > >[......]
> > > > >
> > >
> > > Mis configuraciones:
> > >
> > > archivo /etc/apache2/ports.conf
> > > ========
> > > Listen 80
> > > Listen 443
> > > ==========
> > >
> > > archivo /etc/apache2/sites-avalaible/default
> > > ========
> > > NameVirtualHost *
> > > <VirtualHost *>
> > > ServerAdmin webmaster@localhost
> > > DocumentRoot /var/www/
> > > <Directory />
> > > Options FollowSymLinks
> > > AllowOverride None
> > > </Directory>
> > > [......]
> > > </VirtualHost>
> > > ========
> > >
> > > archivo /etc/apache2/sites-avalaible/ssl
> > > ====
> > > NameVirtualHost *:443
> > > <VirtualHost *:443>
> > > ServerAdmin webmaster@localhost
> > > ==> SSLEngine On
> > > ==> SSLCertificateFile /etc/apache2/ssl/apache.pem
> > > DocumentRoot /var/www/secure/
> > > <Directory />
> > > Options FollowSymLinks
> > > AllowOverride None
> > > </Directory>
> > > [....]
> > > </VirtualHost>
> > > ===
> > >
> > > Básicamente no estan editados ambos salvo un par de directorios con
> > > clave.
> > >
> > > el archivo ssl es una copia del default pero con el puerto 443 y la ruta
> > > al certificado
> > >
> > > Creo que en el default no deberías indicar el 80
> > >
> > > Saludos
> > >
> > > PD.- Procura mandar los mail sólo a la lista, me ha llegado 2 veces.
> > > Gracias
> > >
> > > > >
> > > > >
> > > > Acabo de hacerlo y este es el resultado:
> > > >
> > > > xuvenka:/etc/apache2/mods-enabled# /etc/init.d/apache2 restart
> > > > Forcing reload of web server: Apache2 ... no pidfile found! not
> > > > running?[Tue Apr 26 16:02:58 2005] [error] VirtualHost *:443 -- mixing *
> > > > ports and non-* ports with a NameVirtualHost address is not supported,
> > > > proceeding with undefined results
> > > > [Tue Apr 26 16:02:58 2005] [warn] NameVirtualHost *:0 has no VirtualHosts
> > > > .
> > > > xuvenka:/etc/apache2/mods-enabled# nmap localhost
> > > >
> > > > Starting nmap 3.75 ( http://www.insecure.org/nmap/ ) at 2005-04-26 16:03
> > > > CEST
> > > > Interesting ports on localhost (127.0.0.1):
> > > > (The 1644 ports scanned but not shown below are in state: closed)
> > > > PORT STATE SERVICE
> > > > 9/tcp open discard
> > > > 13/tcp open daytime
> > > > 21/tcp open ftp
> > > > 22/tcp open ssh
> > > > 23/tcp open telnet
> > > > 25/tcp open smtp
> > > > 37/tcp open time
> > > > 53/tcp open domain
> > > > 80/tcp open http
> > > > 110/tcp open pop3
> > > > 139/tcp open netbios-ssn
> > > > 143/tcp open imap
> > > > 443/tcp open https
> > > > 445/tcp open microsoft-ds
> > > > 631/tcp open ipp
> > > > 953/tcp open rndc
> > > > 5432/tcp open postgres
> > > > 8080/tcp open http-proxy
> > > > 10000/tcp open snet-sensor-mgmt
> > > >
> > > > Nmap run completed -- 1 IP address (1 host up) scanned in 0.264 seconds
> > > > xuvenka:/etc/apache2/mods-enabled#
> > > >
> > > > ¿Como se que esta funcionando bien? si pongo http://localhost entro en
> > > > apache, si pongo https://localhost no entro en nada, y si pongo
> > > > http://localhost:443 entro en apache también, pero de candaditos ni
> > > > cosas que me digan que estoy en modo seguro nada de nada.
> > > >
> > > >
> > >
> > > --
> > > To UNSUBSCRIBE, email to debian-user-spanish-REQUEST@lists.debian.org
> > > with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
> > >
> > >
> > Me sigue dando el mismo error /etc/init.d/apache2 force-reload
> > Forcing reload of web server: Apache2 ... no pidfile found! not
> > running?(98)Address already in use: make_sock: could not bind to
> > address 0.0.0.0:443
> > no listening sockets available, shutting down
> >
> > Si en el ports.conf le quito el Listen 443 solo me da este error:
> > Forcing reload of web server: Apache2 ... no pidfile found! not running?.
> >
> Ya funciona .... !!!
> El problema es q solo funciona para http://localhost/ y
> https://localhost/ desde mi máquina. si le hago un
> https://miipexterna/ no hace ni caso y con http tampoco ( ni desde mi
> pc ni desde fuera d otro pc ... )
>
os enseño mi configuración:
NameVirtualHost *
<VirtualHost *>
ServerAdmin webmaster@localhost
DocumentRoot /var/www/
<Directory />
Options FollowSymLinks
AllowOverride None
</Directory>
<Directory /var/www/>
Options Indexes FollowSymLinks MultiViews
AllowOverride None
Order allow,deny
allow from all
# This directive allows us to have apache2's default start page
# in /apache2-default/, but still have / go to the right place
RedirectMatch ^/$ /apache2-default/
</Directory>
ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
<Directory "/usr/lib/cgi-bin">
AllowOverride None
Options ExecCGI -MultiViews +SymLinksIfOwnerMatch
Order allow,deny
Allow from all
</Directory>
ErrorLog /var/log/apache2/error.log
# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
LogLevel warn
CustomLog /var/log/apache2/access.log combined
ServerSignature On
Alias /doc/ "/usr/share/doc/"
<Directory "/usr/share/doc/">
Options Indexes MultiViews FollowSymLinks
AllowOverride None
Order deny,allow
Deny from all
Allow from 127.0.0.0/255.0.0.0 ::1/128
</Directory>
</VirtualHost>
Y mi ssl está igual pero para el 443.
el ports.conf tiene un Listen 80 y un Listen 443
Reply to: