Back to Linux Basement

Linux | Linux Basement Presents: Chad's Blog - Part 3

linux

7.10 ssl apache2

For the records: http://ubuntuforums.org/showthread.php?t=4466&page=5

On Ubuntu 7.10

(as root)

# aptitude install ssl-cert
# mkdir /etc/apache2/ssl

Hardcoding cert lifetime based on this patch:
http://bugs.debian.org/cgi-bin/bugre…?bug=293821#22

# make-ssl-cert /usr/share/ssl-cert/ssleay.cnf /etc/apache2/ssl/apache.pem

(Answer questions)

# a2enmod ssl

# cp /etc/apache2/sites-available/default /etc/apache2/sites-available/ssl

Modify it so it looks something like this

Code:
NameVirtualHost *:443
<virtualhost *:443>
ServerAdmin webmaster@localhost

SSLEngine On
SSLCertificateFile /etc/apache2/ssl/apache.pem

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
# Commented out for Ubuntu
#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>

# sudo a2ensite ssl

don’t forget to modify /etc/apache2/sites-available/default

Code:
NameVirtualHost *:80
<virtualhost *:80>

__________________


Last edited by fortran01 : January 20th, 2008 at 06:34 PM. Reason: Correction

Reply With Quote

[Slashdot] [Digg] [Reddit] [del.icio.us] [Facebook] [Technorati] [Google] [StumbleUpon]
Wednesday, April 16th, 2008 linux, web design No Comments

Heron nvidia-glx-new after upgrade

This was the only way I could get nvidia drivers working after the upgrade to Heron Beta.

sudo apt-get –purge remove nvidia-glx* nvidia-kernel-common nvidia-settings

sudo rm /etc/init.d/nvidia-*
sudo update-rc.d nvidia-kernel remove
sudo apt-get install nvidia-glx-new linux-restricted-modules-`uname -r`

Then I had to do sudo nvidia-xconfig

reboot again

good to go.

Blogged with the Flock Browser

Tags: ,

[Slashdot] [Digg] [Reddit] [del.icio.us] [Facebook] [Technorati] [Google] [StumbleUpon]
Saturday, April 12th, 2008 linux, technology 2 Comments

Twitter, the Evil

Yes, twitter has taken away from my blog time, no doubt. Twitter is an evil evil web based circle of hell, and I can’t stop. Somehow, I will get out of the habit, but first, I must twitter more.

For the record $HOME/bin works by default in Ubuntu, so you can make youself a /home/yourname/bin directory, put your scripts in there, and run them. Bang!

Blogged with the Flock Browser

Tags: ,

[Slashdot] [Digg] [Reddit] [del.icio.us] [Facebook] [Technorati] [Google] [StumbleUpon]
Friday, March 28th, 2008 linux, technology 2 Comments

Why Open Source Is So Damn Cool

A picture is worth a thousand words.

Desktop Screenshot with zenoos and metasploit

[Slashdot] [Digg] [Reddit] [del.icio.us] [Facebook] [Technorati] [Google] [StumbleUpon]
Monday, March 17th, 2008 Open Source, linux, security 1 Comment

Day 1 - Training

Today was every so slightly frustrating. While the training was good, the VMs for the class were created on windows. Not only that, but somehow the paths were hard coded, so one of the VMs was referencing C:\blahblah and would not open. After about an hour of hacking away, I could not get it to run. This ticks me off, because VMs should be agnostic, which is the whole point, so you can only take the error so many times on linux before you want to throw a brick at the windows users in the room.
It is very apparent that my skills in security have greatly increased over the past year, mainly due to running Linux full time, and having to concentrate on server side operations. I like being in the top 25% of the class as far as understanding the content.
A couple notes. I need to keep up my documentation for open ports on servers. Documentation seems to be where I need to focus, even though I have been over the past year, I need to step it up.

owasp.org for web vulnerabilities, a nice little site I need to investigate more.

More to come…

Blogged with Flock

[Slashdot] [Digg] [Reddit] [del.icio.us] [Facebook] [Technorati] [Google] [StumbleUpon]
Monday, March 3rd, 2008 education, linux No Comments

Search

 

Chad's Twitter

Favorites