View previous topic :: View next topic |
Author |
Message |
Lars Senior Member
Joined: 25 Oct 2010 Posts: 136
|
Posted: Thu Mar 01, 2012 2:46 pm Post subject: TOR-server/router |
|
|
Hi!
Installed SMS last july and it has served me well!
I merely use it as a local NFS- and Samba-server, but have also configured an Apache2 HTTP-, and a vsftpd FTP-server, lately also configured the two latter for SSL/TLS.
Now, I think of installing a basic T.O.R.-node (or -server, or -router), merely for the reason that my server is on quite a lot and I want to contribute to the bandwidth in the TOR-network.
I think I somewhere in the SMS software saw tsocks, but I'm not sure.
Are any tor-software preinstalled in SMS? My version is from beginning of july 2011, perhaps 1.6.1?
Have anyone got any experience of configuring and using the SMS server as a TOR-server? Any disadvantages?
Regards
Lars
|
|
Back to top |
|
gerasimos_h Site Admin
Joined: 09 Aug 2007 Posts: 1757 Location: Greece
|
Posted: Thu Mar 01, 2012 3:20 pm Post subject: |
|
|
To see what SMS version you are running do
"cat /etc/sms-version"
There are no TOR software pre-installed or as packages, I can create packages for you if you want to, and that's not a bad idea adding them in extra also.
I haven't use TOR but as far as I read tsocks is an optional dependency for torify shell script.
You may wanna take a look at
https://www.torproject.org/docs/tor-doc-relay.html.en
gerasimos_h
_________________ Superb! Mini Server Project Manager
http://sms.it-ccs.com |
|
Back to top |
|
Lars Senior Member
Joined: 25 Oct 2010 Posts: 136
|
Posted: Sat Mar 03, 2012 1:57 pm Post subject: |
|
|
Kind as always!
Sorry about the late reply!
I'm running SMS 1.6.0.
Thank you for the offer to create packages, but I think I'll try by myself first if I only can ask a few questions, if you know the answer:
I've managed to install TOR in OpenSUSE12.1 using the different packages that TOR consist of. -Now I've succeeded to find the similar for Slackware 13.37. I e:
geoip-1.4.8-i686-1cf.txz
libevent-2.0.11-i486-1sl.txz
privoxy-3.0.19-i686-1cf.txz
tor-0.2.1.30-i686-1cf.txz*
tor-0.2.2.35-i686-1cf.txz
vidalia-0.2.10-i486-66.1.txz
vidalia-0.2.14-i486-72.1.txz
vidalia-0.2.15-i486-72.1.txz.
Do you think I should use them, or instead install the Bundled software that Torproject recommends: Tor Browser Bundle 2.2.35-7.2 - Linux, BSD, and Unix?
Even if I dealt with PC's for some 12 years now, there are many basics I do not understand. I was for instance very surpriced when I found that my http- and ftp-servers were up even if I didn't log in to the SMS-server?
Now Tor-project recommends that I do not start any of the Tor softwares as root, but as user. The problem is I very seldom log in as a user in SMS: Do you think I can install the Tor softwares in an ordinary user-account -and after best knowledge- set the running at boot (if that doesn't require root-privileges?) and that the Tor-relay will start up like the httpd and vsftpsd services at boot? Or do you think I will have to start it up as the user every time? And then, will the service continue to run when I log out from the user-account?
Perhaps the last description was a little messy
but I hope you could understand what I meant!
Best regards
Lars
|
|
Back to top |
|
gerasimos_h Site Admin
Joined: 09 Aug 2007 Posts: 1757 Location: Greece
|
Posted: Sat Mar 03, 2012 7:22 pm Post subject: |
|
|
If you want to build them your self there are slackbuilds,
http://slackbuilds.org/repository/13.37/network/tor/
http://slackbuilds.org/repository/13.37/libraries/libevent/
http://slackbuilds.org/repository/13.37/libraries/tsocks/
If you want vidalia you need to download bundled software from tor site, which it's built statically.
Other vidalia packages will not work in SMS, because it requires QT4.
If you build tor package it has a start up script rc.tor for starting tor at boot, as user nobody, so no problem.
Bundled software only needed if you want to use vidalia for configuration, unless you configure it manual through /etc/tor/torrc file.
I don't know those packages you have found how they are configured, but should work.
I recommend building your own, if you have problem I can build them for you.
gerasimos_h
_________________ Superb! Mini Server Project Manager
http://sms.it-ccs.com |
|
Back to top |
|
Lars Senior Member
Joined: 25 Oct 2010 Posts: 136
|
Posted: Sat Mar 03, 2012 10:11 pm Post subject: |
|
|
OK!
Thank you for now!
I'll try to build them from the sites you recommended. If I don't succeed I'll be back!
Thank you for guidance!!
Lars
|
|
Back to top |
|
Lars Senior Member
Joined: 25 Oct 2010 Posts: 136
|
Posted: Sat Mar 10, 2012 12:56 pm Post subject: |
|
|
Hi again!
Wonder if you can help me out (I'm not very used to work in Slackware, OpenSuSE is my ordinary system). Trying Slackbuilds, but get complaints about the C compiler:
"configure: error: no acceptable C compiler found in $PATH"
From SuSE I'm used to install gcc and gcc-c++ and that's usually enough.
Found and installed:
gcc-4.5.2-i486-2.txz
gcc-objc-4.5.2-i486-2.txz
gcc-gfortran-4.5.2-i486-2.txz
Still not enough:
Couldn't find gcc-c++, only gcc-g++
Installed
gcc-g++-4.5.2-i486-2.txz
Still get complaints about the C compiler, but now
"checking for gcc... gcc
checking whether the C compiler works... no
configure: error: in `/tmp/SBo/libevent-2.0.10-stable':
configure: error: C compiler cannot create executables"
I know you offered to build the packages for me, but I really would like to learn how to do it myself.
Can you tell what part of the C compiler is missing?
Best regards
Lars
|
|
Back to top |
|
gerasimos_h Site Admin
Joined: 09 Aug 2007 Posts: 1757 Location: Greece
|
Posted: Sat Mar 10, 2012 3:25 pm Post subject: |
|
|
You need to install devel packages from slackware/devel directory in your SMS.Native.CD-1.6.0-Install.iso
if you don't have it, download it at
http://sms.it-ccs.com/isos/index.php?dir=SMS.Native.CD%2F
and install them thought install_packages.sh or with
upgrade --install-new /pathto/mountiso/slackware/devel/*.txz
gerasimos_h
_________________ Superb! Mini Server Project Manager
http://sms.it-ccs.com |
|
Back to top |
|
Lars Senior Member
Joined: 25 Oct 2010 Posts: 136
|
Posted: Sat Mar 10, 2012 5:41 pm Post subject: |
|
|
!
With your help I managed to create and install
GeoIP-1.4.8-i486-1
libevent-2.0.10-i486-1
tor-0.2.2.35-i486-1
torsocks-1.1-i486-1 and
tsocks-1.8beta5-i486-1
but failed in creating
vidalia-0.2.15 and polipo-1.0.4 both downloaded from http://slackbuilds.org/
I must mention I started today with installing Qt-4.7.0 (I had qt3 and qt4 coexisting in SuSE12.1)
vidalia-Slackbuild ends upp with
Code: | vidalia-0.2.15/src/vidalia/vidalia.desktop
cmake: error while loading shared libraries: libarchive.so.2: cannot open shared object file: No such file or directory |
Polipo ends up with
Code: | makeinfo polipo.texi
make: makeinfo: Command not found
make: *** [polipo.info] Error 127 |
Do you think there is a way to solve this, I relly would lika a graphical controller for Tor and a working proxy for applications that cannot connect to SOCKs?
Thank you for your help so far
Lars
|
|
Back to top |
|
gerasimos_h Site Admin
Joined: 09 Aug 2007 Posts: 1757 Location: Greece
|
|
Back to top |
|
Lars Senior Member
Joined: 25 Oct 2010 Posts: 136
|
|
Back to top |
|
Lars Senior Member
Joined: 25 Oct 2010 Posts: 136
|
Posted: Sun Mar 11, 2012 11:14 am Post subject: |
|
|
Hi again!
One final question about starting Tor and process owners:
In noticed that Tor doesn't startup at boot per default.
And further that if I start Tor from Vidalia the user who started Vidalia will own the process, consequently if started by root root owns the tor process. -Further, Vidalia depends on a working X window system which might be a disadvantage since I very often run my httpd- and vsftpd-servers not logged in (are up and running anyway )
If I start Tor as root with the startup script
/etc/rc.d/rc.tor start
or with
/usr/bin/tor
"tor" owns the process.
The safest solution is possibly starting Tor with the startup script?
If I want Tor to start at boot, should I perhaps a line, similar to:
# The Onion Router (TOR) router.
tor stream tcp nowait root /usr/bin/tor tor
in /etc/ined.conf ?
or is there any other way?
Best regards
Lars
|
|
Back to top |
|
gerasimos_h Site Admin
Joined: 09 Aug 2007 Posts: 1757 Location: Greece
|
Posted: Sun Mar 11, 2012 11:31 am Post subject: |
|
|
You can add in /etc/rc.d/rc.local to start at boot
Code: | if [ -x /etc/rc.d/rc.tor ]; then
/etc/rc.d/rc.tor start
fi |
And in /etc/rc.d/rc.local_shutdown to stop at shutdown.
Code: | if [ -x /etc/rc.d/rc.tor ]; then
/etc/rc.d/rc.tor stop
fi |
This info was already available in README of tor.slackbuild
gerasimos_h
_________________ Superb! Mini Server Project Manager
http://sms.it-ccs.com |
|
Back to top |
|
Lars Senior Member
Joined: 25 Oct 2010 Posts: 136
|
Posted: Sun Mar 11, 2012 5:04 pm Post subject: |
|
|
well, you see, I'm not too much of a Slacker!
I saw it but when it was built and installed I thought it was the main content of rc.tor
Anyway, thank you again, now I'll try to configure tor as a relay, but won't bother you with that at least !
Best regards
Lars
|
|
Back to top |
|
Lars Senior Member
Joined: 25 Oct 2010 Posts: 136
|
Posted: Mon Mar 12, 2012 1:52 pm Post subject: |
|
|
I should never have said never.. but this is more of Slackware's hebrewian language interpretation:
I added the lines you (and SlackBuilds ) suggested in /etc:rc.d/rc.local and /etc:rc.d/rc.local_shutdown and i seems to work.
That is, when I run /etc/rc.d/rc.tor status I get a mysterious answer
Code: | $ /etc/rc.d/rc.tor status
/etc/rc.d/rc.tor: line 89: kill: (2414) - Operation not permitted
PID file /var/run/tor/tor.pid present but PID 2414 is not running. |
I never get anything similar starting tor manually during a session with # /etc/rc.d/rc.tor start? just "Running" or "Not running".
Tried
Code: | $ ps aux | grep tor
tor 2414 0.7 1.7 21216 18044 ? S 12:07 0:07 /usr/bin/tor |
Anway, tried connect with Firefox using 127.0.0.1 port 9050 and it really seems tor is up and running?
The mentioned line 89 in /etc/rc.d/rc.tor is:
tor_status() {
PID=`cat /var/run/tor/tor.pid 2>/dev/null`
if [ -z "$PID" ]; then
echo "Not running."
exit 1
elif kill -0 $PID; then
echo "Running."
exit 0
else
echo "PID file /var/run/tor/tor.pid present but PID $PID is not running."
exit 1
fi
Can you please interpret this to me?
Does it has anything to do with my setting up the user and group:
tor:x:220:220:The Onion Router:/dev/null:/bin/false and that it shouldn't be obvious that it is up? Or, do you know the reason?
Best regards
Lars
|
|
Back to top |
|
gerasimos_h Site Admin
Joined: 09 Aug 2007 Posts: 1757 Location: Greece
|
Posted: Mon Mar 12, 2012 2:00 pm Post subject: |
|
|
You are running
/etc/rc.d/rc.tor status
as user and not as root would be my first guess.
Are you?
gerasimos_h
_________________ Superb! Mini Server Project Manager
http://sms.it-ccs.com |
|
Back to top |
|
|