Using ssh as a socks proxy

Ssh can support forwarding traffic & act as a SOCKS proxy.

This is fantastic for encrypted browsing over unsecured wifi connections. You can setup Firefox, YM or any other SOCKS 5 compliant program to make use of the proxy. After executing the command below ssh will be listening on localhost (127.0.0.1) and you would then point your SOCKS compliant program to this ip and port that you specify below.

The command:

ssh -qTfnN2 -D 8080 -p 22 user@localhost

Explanations:

-q :- be very quite, we are acting only as a tunnel.
-T :- Do not allocate a pseudo tty, we are only acting a tunnel.
-f :- move the ssh process to background, as we don?t want to interact with this ssh session directly.
-N :- Do not execute remote command.
-p :- Port to connect to on the remote host.
-n :- redirect standard input to /dev/null.
-2 :- Forces ssh to try protocol version 2 only.
-D :- Specifies a local “dynamic” application-level port forwarding.This works
by allocating a socket to listen to port on the local side,and whenever a connection
is made to this port, the connection is forwarded over the secure channel, and the application
protocol is then used to determine where to connect to from the remote machine.
Currently the SOCKS4 and SOCKS5 protocols are supported, and ssh will act as a SOCKS server.
Only root can forward privileged ports.

Enjoy.

Install Suhosin PHP5 Security Protection on Debian Squeeze

What is Suhosin?

Suhosin is an advanced protection  for PHP5 installations. It was designed to protect servers and users from known and unknown flaws in PHP applications and the PHP core. Suhosin comes in independent parts, that can be used separately or in combination.

Suhosin is a great and simple way of increasing your security protection without having a immense impact on overall performance.

In this tutorial I will cover the installation and configuration of Suhosin on Debian Squeeze. I will also assume that you already have apache2 and php2 setup using this tutorial:How to install apache2, mysql5 and php5 on debian squeeze

1. Install Suhosin on Debian Squeeze:

Installation of suhosin on Debian Squeeze is simple.

apt-get update && apt-get install php5-suhosin

2. Configuring Suhosin:

The configuration file on Debian Squeeze is located in /etc/php5/conf.d/suhosin.ini.

Systemd – System and Service Manager

systemd is a technique and service manager for Linux, compatible with SysV and LSB init scripts.

systemd provides aggressive parallelization capabilities, makes use of socket and D-Bus activation for starting services, offers on-starting of daemons, keeps track of processes using Linux cgroups, supports snapshotting and restoring of the system state, maintains mount and automount points and implements an elaborate transactional dependency-based service control logic. It can work as a drop-in replacefor sysvinit.

Install systemd:

apt-get update && apt-get install systemd

Useful SystemD commands on Debian Squeeze:

List all running services :

systemctl

Start/stop or enable/disable services:

Debian Squeeze : SSH disable password authentication for root allow public key authentication only

On Debian Squeeze edit the sshd_config file located in /etc/ssh/ :

Change PermitRootLogin from yes/no to “without-password”:

#PermitRootLogin yes
PermitRootLogin without-password

Restart ssh daemon and try to login with root account.

Enjoy.

Create Your Own Cloud Server on Debian Squeeze

Everyone loves using services like Dropbox or Boxnet. Half of us do have hardware laying around that we’d love to convert into our own cloud server but never came across the right software.

In this tutorial i’ll show you how to create your own cloud server:

Step1. Install depencencies need for cloud server:

apt-get install apache2 php5 php5-sqlite php5-json

optional dependencies: apt-get install mp3info curl libcurl3 libcurl3-dev php5-curl zip

Step2. Download ownCloud from owncloud.org:

You can download it from here: http://gitorious.org/owncloud/owncloud/archive-tarball/master

or from repository: git clone git://gitorious.org/owncloud/owncloud.git

Step3. Extract the archive using tar and copy the content to /var/www:

       


Categories

Page 2 of 28123451020...Last »
Copyright © 2012 Linux Debian Tutorials | Debian Squeeze Tutorials. All rights reserved.
Feedbase
Stop ACTA 34 queries in 0.228 seconds.