Linux - Security This forum is for all security related questions.
Questions, tips, system compromises, firewalls, etc. are all included here. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
|
10-05-2007, 09:47 AM
|
#1
|
LQ Newbie
Registered: Nov 2006
Distribution: gentoo
Posts: 7
Rep:
|
Samba shares available from internet
Ok, I work on a laptop always, and all my files are on my fileserver (~2TB, thus nothing on the laptop).
I want them to be accesible from wherever they are.
I am planning to set up a vpn server and connect to my home. Till then (it's going to be a month or so), is it safe to have the samba available from the outside?
ie mount -t smbfs //myip/share /mnt/storage
Thanks in advance
|
|
|
10-05-2007, 10:11 AM
|
#2
|
LQ Guru
Registered: Jan 2004
Location: NJ, USA
Distribution: Slackware, Debian
Posts: 5,852
|
Well, I certainly wouldn't do it myself.
I would rather use NFS, which is generally more secure (Samba has had a number of remote buffer overflows and other such vulnerabilities recently, it seems like every few months I see a security update for it), and doesn't rely on non-routable protocols (NETBIOS).
If your client side is Windows, then there is an NFS client available from Microsoft.
If your client is *nix, then there are a number of other options available (like SSH); and ,arguably, you shouldn't even be using Samba for *nix-to-*nix communication.
|
|
|
10-05-2007, 10:57 AM
|
#3
|
LQ Guru
Registered: Jul 2003
Location: Los Angeles
Distribution: Ubuntu
Posts: 9,870
|
Risky stuff. I'd recommend sticking to SSH until you set up your VPN.
Capt_Caveman actually commented on this a few days ago.
Last edited by win32sux; 10-05-2007 at 10:58 AM.
|
|
|
10-05-2007, 11:51 AM
|
#4
|
Member
Registered: Jul 2007
Distribution: Gentoo, LFS
Posts: 42
Rep:
|
Quote:
Originally Posted by win32sux
Risky stuff. I'd recommend sticking to SSH until you set up your VPN.
|
I second that. Or possibly Apache + SSL, but if you don't have it setup already, you should just go straight to your VPN. Probably take about the same amount of time.
-TDS-
|
|
|
10-05-2007, 02:32 PM
|
#5
|
Member
Registered: Oct 2003
Location: United Kingdom
Distribution: SuSE 10.0 - 11.4
Posts: 347
Rep:
|
If it's just access to your files then ssh is really all you need - I used the same link as in the Capt_Caveman a while back and it worked fairly simply - I have Cygwin on my laptop so I use that rather than putty. I also use WinSCP to copy files to and fro if needed.
As regards VPN I use OpenVPN - there are a few hoops to go through generating the keys etc but the docs on their site are excellent and you can get it up and running in a very short time.
Only thing to look out for is that either ssh or VPN is going to be slower than direct because of the encryption overhead.
As everyone else has said - you don't want Samba over the internet.
|
|
|
10-05-2007, 04:18 PM
|
#6
|
LQ Newbie
Registered: Nov 2006
Distribution: gentoo
Posts: 7
Original Poster
Rep:
|
MS3FGX: Both laptop and fileserver are running linux. I use samba anyway because of some windows boxes on my lan.
win32sux: I read the post and now I am going to read also the guide he points out. That's going to be the temporary solution propably.
TheDirtyScreech: I don't want to install apache on this machine. It's just a fileserver. Heading for the VPN.
andrewdodsworth: I 'm messing with OpenVPN right now, but because I don't have enough time, it's going to take a lot till I read the manual and install it successfully.
Thanks all of you for your answers
|
|
|
10-07-2007, 03:32 AM
|
#7
|
Member
Registered: Apr 2006
Location: Cape Town, South Africa
Distribution: Gentoo 2006.1(2.6.17-gentoo-r7)
Posts: 222
Rep:
|
nah, be safe and wait until you setup/use your vpn. Allowing access to Samba from the outside could lead to security issues...
|
|
|
10-08-2007, 12:34 AM
|
#8
|
Member
Registered: Jul 2003
Location: Pennsylvainia
Distribution: Slackware / Debian / *Ubuntu / Opensuse / Solaris uname: Brian Cooney
Posts: 503
Rep:
|
It sounds like the best solution may be to use ssh.
If you are running linux on the laptop, You may be interested in the FUSE driver, which would allow you to (with the correct module) mount a ssh connection like a local drive.
for more info: http://fuse.sourceforge.net/
|
|
|
10-08-2007, 01:45 PM
|
#9
|
Member
Registered: Dec 2006
Location: Vancouver, BC
Distribution: Debian,Ubuntu,Slackware
Posts: 479
Rep:
|
You might want to look into Hamachi as an option as well.
|
|
|
10-08-2007, 03:31 PM
|
#10
|
Member
Registered: Apr 2005
Location: UK
Distribution: Slackware 13.0
Posts: 241
Rep:
|
Opening Samba to the world - an accident waiting to happen and not recommended. It's not that it's insecure, it's just an unnecessary risk. Given that SMB is such a common protocol for the propogation of Windows viruses then, if nothing else, rogue traffic from your ISP will treble overnight, even if they don't manage to get into any of your shares.
My own ISP even blocks Internet access if it detects unfiltered SMB connections being accepted on your IP, until you certify to them that you *have* firewalled/authenticated it or you know the risks.
For one-off usage, use scp (i.e. ssh)
For permanent usage, set up something like OpenVPN or similar and open Samba up to that.
I personally have an internal network which allows everything (i.e. pretty much unfirewalled between clients - all clients are Linux and things aren't running services they aren't supposed to.).
The only way to get onto that network is to a) plug a cable into my house wiring system or b) use some sort of authentication from an insecure network with a VPN or SSH package.
For my purposes that means that I treat wireless connections exactly the same as Internet connections - there is no access from them to my internal network until you enter via a VPN or SSH. Once you have that, you are on the "real" network and are open to anything that you need.
Externally, on wireless or the Internet, all you can see of my network is a SSH port and a VPN port. Both are updated religiously (I don't care if I run an older version of Apache on the internal network, but I don't let SSH or OpenVPN get even a tiny bit out of date because they are exposed to the world). For myself, even they are behind a second layer of defence, but that's getting too paranoid.
|
|
|
All times are GMT -5. The time now is 11:02 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|