LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Security
User Name
Password
Linux - Security This forum is for all security related questions.
Questions, tips, system compromises, firewalls, etc. are all included here.

Notices


Reply
  Search this Thread
Old 01-24-2009, 11:14 AM   #1
neilcpp
Member
 
Registered: Jul 2003
Location: England
Distribution: Debian Jessie, FreeBSD 10.1 anything *nix to get my fix
Posts: 329

Rep: Reputation: Disabled
how safe is using bittorrent


I had a reality check today. I was getting some films with bittorrent and to get it to work i turned off the router's firewall and opened up about 10 ports in a range, including tcp and udp.

In addition, i made exceptions in my computer firewall for these ports.

I had left my pc for about 3hours and when i turned the monitor on there was over 10 windows open for a dialog for saving 'a snapshot' of the desktop.

I pulled the plug on my modem straightway. I turned on my router firewall and removed all the ports i opened. I set my firewall back to blocking everything. i also changed some policies e.g by making my home directory permissions only rw by myself, by disallowing remote connection to x windows...

Right now, i am not going to start using bittorrent again until i know whats what.

First thing i want to know is do i need to open just one port for bittorrent or not? Some websites say you should open a whole range of ports.

The second thing is, if i am opening a port what is to stop joe cracker from logging onto my computer and doing some damage?

Just how safe is this bittorrent stuff? From my experience, it sure dont seem very safe to me.
 
Old 01-24-2009, 11:25 AM   #2
watcher69b
Member
 
Registered: Nov 2007
Location: /home/watcher69b
Distribution: RH, Fedora & CentOS
Posts: 552

Rep: Reputation: 41
well 1st don't ever open your firewall!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! !!!!!!!!!!!!

Any software that is legit should allow for the client being able to traverse it with out problem. use something that comes with your distro for a client, in my case it was transmission. i would think very hard about wiping your system as it most likely has been compromised.
 
Old 01-24-2009, 12:28 PM   #3
unixfool
Member
 
Registered: May 2005
Location: Northern VA
Distribution: Slackware, Ubuntu, FreeBSD, OpenBSD, OS X
Posts: 782
Blog Entries: 8

Rep: Reputation: 158Reputation: 158
Quote:
Originally Posted by watcher69b View Post
i would think very hard about wiping your system as it most likely has been compromised.
DON'T wipe your system until you absolutely understand what caused this situation. At this point, you could say that you caused the situation to happen because of your initial FW and router allowances. That doesn't explain what the attacker was doing, though. Wipe your system only after you understand what was going on (how he actually got in, what he was doing, and how to prevent it from happening again). You might also use this time to determine how to use Bittorrent without allowing such attackers to gain access to your network.

It's research time, not clean-up time. If you wipe your drive, you aren't going to learn from this and will quite possibly run into the same situation again later.
 
Old 01-24-2009, 05:32 PM   #4
unSpawn
Moderator
 
Registered: May 2001
Posts: 29,415
Blog Entries: 55

Rep: Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600
Quote:
Originally Posted by watcher69b View Post
it most likely has been compromised.
I'm not slagging you off but you should know how we deal with things here. This is the Linux Security forum. We like to deal with compromises of security accurate and decisively. But that can be only done when based on facts. (If you disagree you should provide substantial evidence that supports your conclusion.) Note there are some very knowledgable people here who deal well (as far as I'm concerned) with (perceived) compromises. Their triage usually starts by asking questions (especially if the OP posted nothing of value or incomplete information), followed by analysis (not opinion) of the situation, followed by advice. With all due respect but if you're lacking incident handling skills please just point to the default starting point: the CERT Intruder Detection Checklist, ask the OP for more information and allow others to do their thing. TIA.


Quote:
Originally Posted by neilcpp View Post
First thing i want to know is do i need to open just one port for bittorrent or not? (...) The second thing is, if i am opening a port what is to stop joe cracker from logging onto my computer and doing some damage?
Actually the first thing to do would be finding out, like Unixfool said. Pulling the plug is a typical default reflex but that doesn't mean it's the right thing to do, because by doing that you lose information. All that's left then is cold tracks like temporary files, login records, syslog, firewall, daemon and application logs, filesystem integrity and package content verification. I suggest you start with reading the the CERT Intruder Detection Checklist and take it from there.
 
Old 01-24-2009, 05:42 PM   #5
win32sux
LQ Guru
 
Registered: Jul 2003
Location: Los Angeles
Distribution: Ubuntu
Posts: 9,870

Rep: Reputation: 380Reputation: 380Reputation: 380Reputation: 380
Regarding the topic of BT security in general (this is separate from the possible compromise):

I don't think with BitTorrent it would really matter too much whether you "open the port" or not. I mean, I'm sure it reduces the threat somewhat, but people are still able to upload/download from you. Personally, I think that your security concerns regarding BT are well-founded. With BT you've got hundreds upon hundreds of connections open with all kinds of strangers and potentially hostile hosts. Someone who finds an exploit for a popular BT servent and creates an exploit will be able to wreak havoc upon many of us.

Personally, I started to become extremely concerned about BT security a while back. I stopped using it on my personal account and instead used a dedicated user account for it - extremely inconvenient. I haven't really had time to use BT lately but once I do get back into it I'm gonna do this right by wrapping my servent (I use Transmission) up with AppArmor instead. I just haven't had time to create a profile for it yet. Having my BT servent run under mandatory access control won't fix any security vulnerabilities in it, but it will give me peace of mind that any exploit launched against it will be severely limited in what it can do.

Last edited by win32sux; 01-24-2009 at 05:45 PM.
 
Old 01-24-2009, 06:08 PM   #6
jiml8
Senior Member
 
Registered: Sep 2003
Posts: 3,171

Rep: Reputation: 116Reputation: 116
A broader question is this: "is there a history of bittorrent exploits?"

Are there known exploits against bittorrent clients right now? I know of none, but that means nothing. I also have never experienced anything like what OP describes, and sometimes when I have KTorrent running, I watch it just to see what it is doing.
 
Old 01-24-2009, 06:16 PM   #7
amani
Senior Member
 
Registered: Jul 2006
Location: Kolkata, India
Distribution: Debian 64-bit GNU/Linux, Kubuntu64, Fedora QA, Slackware,
Posts: 2,766

Rep: Reputation: Disabled
I think the OP must have accidentally hit the print Screen key
 
Old 01-24-2009, 06:50 PM   #8
jschiwal
LQ Guru
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682
Since you disabled the router's firewall, every port you have open on the computer was exposed, not just the ones that bit torrent uses. Also, you only needed to open one tcp port and another udp port to be able to seed torrents as well. Look at the ports that were exposed using nmap on another computer on the LAN. Also, opening the router, you may have had a different host compromised which may have been a trusted host on the LAN. So you need to look at the ports exposed on all of the hosts on the LAN, not just the one using bit torrent.
 
Old 01-24-2009, 07:55 PM   #9
win32sux
LQ Guru
 
Registered: Jul 2003
Location: Los Angeles
Distribution: Ubuntu
Posts: 9,870

Rep: Reputation: 380Reputation: 380Reputation: 380Reputation: 380
Quote:
Originally Posted by jiml8 View Post
A broader question is this: "is there a history of bittorrent exploits?"

Are there known exploits against bittorrent clients right now? I know of none, but that means nothing. I also have never experienced anything like what OP describes, and sometimes when I have KTorrent running, I watch it just to see what it is doing.
Yeah, my main concern was/is a bad guy gaining the ability to download arbitrary files from my home folder. Or worse, the ability to modify files within it. This is why I chose to run the BT application on another account (which didn't have read access to my home folder) instead. I would actually be surprised to hear of an exploit that would graphically let you know you've been owned. Placing myself in the shoes of a bad guy (a non-script-kiddie one), I would want to make the operation be as stealth as possible. The longer the community at large is unaware of the exploit I am using, the more data I am able to gain unauthorized access to.
 
Old 01-24-2009, 08:06 PM   #10
unSpawn
Moderator
 
Registered: May 2001
Posts: 29,415
Blog Entries: 55

Rep: Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600
Quote:
Originally Posted by win32sux View Post
This is why I chose to run the BT application on another account (which didn't have read access to my home folder) instead.
Minimising chance always is a good choice. I've run BT for quite some time like that now and I've encountered nothing newsworthy.


Quote:
Originally Posted by win32sux View Post
I would actually be surprised to hear of an exploit that would graphically let you know you've been owned.
Searching www.cve.mitre.org, osvdb.org and secunia.com you can find some entries. All from 2008, and apart from CVE-2008-0364 and CVE-2008-4434 only a few concern GNU/Linux products like Opera, BNBT or Azureus. Exploits aren't hard to find but I've seen nothing like you described.
 
Old 01-26-2009, 08:36 AM   #11
rweaver
Senior Member
 
Registered: Dec 2008
Location: Louisville, OH
Distribution: Debian, CentOS, Slackware, RHEL, Gentoo
Posts: 1,833

Rep: Reputation: 167Reputation: 167
Quote:
Originally Posted by neilcpp View Post
I had a reality check today...<SNIP>... Just how safe is this bittorrent stuff? From my experience, it sure dont seem very safe to me.


DON'T PANIC

Unspawn probably gave the best advice in the thread.

Run through the cert checklist, run both of the root kit checking programs, etc. It's entirely possible your system has been compromised for months or that it's not compromised at all and your cat stepped on the keyboard, or that you're right-- its compromised. You need to establish the facts of what is happening before you do anything significant.

As far as I know there have been no Linux system compromises on the bit torrent clients, although that doesn't mean there aren't any. If your system is actually compromised then you need to look at the source of the client too. Did you download it from the sanctioned website or from your distributions repository or off some obscure forum? etc. There's also a big difference in the significance of a root level compromise and a user level compromise.

First things first though, calm down, don't panic, *think*.

Last edited by rweaver; 01-26-2009 at 08:37 AM.
 
Old 01-27-2009, 12:54 PM   #12
neilcpp
Member
 
Registered: Jul 2003
Location: England
Distribution: Debian Jessie, FreeBSD 10.1 anything *nix to get my fix
Posts: 329

Original Poster
Rep: Reputation: Disabled
'Hacker found'

Quote:
Originally Posted by amani View Post
I think the OP must have accidentally hit the print Screen key
Well, my system did have a few obvious security holes and i was doing the wrong thing opening a whole range of ports for bittorrent. ive now installed a new torrent client called transmission and it only requires 1 port to be open. In addition i have my router firewall and my linux firewall guarding my system.

However, I found the Hacker that caused the 'screenshot' dialog to appear!. I at first thought it was a 'remote hacker/cracker' who wanted a snapshot of my desktop as a trophy!!

But thankfully, i saw the same dialog pop up today. My cat has a habit of sleeping on top of my monitor and from time to time he will jump down onto the keyboard!!! thus causeing the print screen button to be pressed multiple times.

In my case, this was a false alarm - but i am definately going to take a closer interest in security issues from now on. When the problem first appeared i felt like the victim of a burglary - thinking that someone had been poking around my pc. I will do my best to make sure this threat is minimised for real.
 
Old 01-27-2009, 04:09 PM   #13
GazL
LQ Veteran
 
Registered: May 2008
Posts: 6,904

Rep: Reputation: 5025Reputation: 5025Reputation: 5025Reputation: 5025Reputation: 5025Reputation: 5025Reputation: 5025Reputation: 5025Reputation: 5025Reputation: 5025Reputation: 5025
hehe... is that what they mean by a 'Black Cat' hacker.
 
Old 01-27-2009, 04:57 PM   #14
win32sux
LQ Guru
 
Registered: Jul 2003
Location: Los Angeles
Distribution: Ubuntu
Posts: 9,870

Rep: Reputation: 380Reputation: 380Reputation: 380Reputation: 380
Anyone know of a cat-detection application for GNU/Linux?

I remember seeing some for Windoze a few years back (PawSense, etc).

Might be a good idea to use such a tool to prevent this from happening again.

Last edited by win32sux; 01-27-2009 at 04:59 PM.
 
Old 01-27-2009, 05:10 PM   #15
mrclisdue
Senior Member
 
Registered: Dec 2005
Distribution: Slackware
Posts: 1,134

Rep: Reputation: 277Reputation: 277Reputation: 277
Could one not disable the keyboard possibly by renaming or changing permissions on whatever /dev the keyboard is on?

Then, perhaps, to renable, a virtual keyboard....

Or, a script that would disable the keyboard, then re-enable when a zenity or xdialog is moused...

Edit:

Here we go: Lock Keyboard For Baby
Code:
http://csincock.customer.netspace.net.au/lock-keyboard-for-baby.htm

cheers,

Last edited by mrclisdue; 01-27-2009 at 05:21 PM. Reason: found something
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Is It safe,..... udazzleme Linux - General 3 01-23-2006 10:46 PM
Is it safe ? Alex_jacobson Solaris / OpenSolaris 2 03-02-2005 01:24 PM
How safe am I? bad_andy Linux - Security 2 01-29-2005 01:47 PM
Is this safe enough? koyi Linux - Security 4 08-18-2004 10:50 PM
is there anyone using bittorrent bittorrent-shadowsclient-5.8.3 moonloader Linux - Software 0 01-12-2004 05:35 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Security

All times are GMT -5. The time now is 03:46 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration