Firewall and few questions

Questions about applications and software
Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Javoc

Firewall and few questions

Post by Javoc »

Hello
1. I want find and install firewall for Linux Mint with interactive creations(if some app using connections, firewall must ask allow/deny) rules for apps.
Standart firewall not has this option..
Tell me please few names of firewalls with this option.

2. From app repository i install Lazarus 1.6 - but then it starts - message - "The sources of Free Pascal packages are required for browsing and code completion. For example it has the file rtl/linux/system.pp. Error: directory not found
You can download FPC and the FPC sources from http://sourceforge.net/projects/lazarus ... =directory"

But in sourcceforge - i not see where is this FPC package ?
Please give me direct link to download this package.

3. Internet has legend - "For Linux not exists viruses". This is true ?
Or i need to install some antiviral software like DrWeb ?
Please give me some links, or it names - for free antiviral software for Linux Mint.

4. Also i looking software like Total Commander for Linux Mint.

5. In update manager - i see this - tomcat8 - "Apache Tomcat implements the Java Servlet and the JavaServer Pages (JSP) specifications from Oracle, and provides a "pure Java" HTTP web server environment for Java code to run.
This package contains the Java Servlet and JSP library."

But why Linux mint contains this server software by default ?

Thanks
MintyO

Re: Firewall and few questions

Post by MintyO »

Hello and welcome to the forums!

I don't know about such firewalls you talk about, but maybe someone here does. As for you #3, I don't know if you can say that there aren't any viruses for linux, but I can say the majority of linux users will say you don't need (and actually shouldn't install and use) an antivirus software.

I have seen the Mint default firewall being recommended for firewall needs, and although it might not do exactly what you want you can make your own rules for traffic. I'd say it's more than sufficient if it is security you are concerned about.

Lastly, for everyone doing a research for their firewall needs, here's a viewpoint that's worth reading no matter on what you ultimately decide:
http://www.infoworld.com/article/261693 ... ewall.html
User avatar
jimallyn
Level 19
Level 19
Posts: 9075
Joined: Thu Jun 05, 2014 7:34 pm
Location: Wenatchee, WA USA

Re: Firewall and few questions

Post by jimallyn »

Regarding viruses affecting Linux, there are damn few, and I don't think that there are any "in the wild" at the moment. I have been using Linux for almost 15 years, have never used an antivirus program, and have never been infected with any virus or other malware. Nor do I know of any other Linux user who has had a Linux computer infected. One of the forums members has written on antivirus and firewall for Linux. See the link below, and look around the whole site while you're there, there's some good stuff!

https://sites.google.com/site/easylinux ... t/security
“If the government were coming for your TVs and cars, then you'd be upset. But, as it is, they're only coming for your sons.” - Daniel Berrigan
Javoc

Re: Firewall and few questions

Post by Javoc »

MintyO wrote:Hello and welcome to the forums!

I don't know about such firewalls you talk about, but maybe someone here does.
i want find firewall with interactive gui for creating rules.
for example - some application - goes to internet - and then firewall stopt it and ask - allow/deny - at once or create rule - allow/deny for all time for this app.

And now i dont know allow/deny internet access for linux app
avahi-daemon - ?
cups-browsed - ?
List of linux nesesary internet connected apps ?
Because that - i cant configure standart linux mint firewall.

For example system monitor - now shows - what today i send 74 mb - in internet. But i only use browser, for surfing.
So - i dont know wich application send this traffic, and whom.

Im searching firewall for linux mint - like that
http://s019.radikal.ru/i628/1703/c4/207af80c567c.png

Use linux only second day, so...
thaks
MintyO

Re: Firewall and few questions

Post by MintyO »

I understood what you're looking, just said that I don't know of such firewalls for linux. Also what I meant by my post, is that a normal home user doesn't really need a firewall and if you want to use one it's enough to turn the Mint's default one on. jimallyn linked to a site that belongs to a knowledgeable forum member that says it like this:
1.2. A firewall is already installed by default. It's called IPtables. IPtables can be managed through the application Uncomplicated Firewall (ufw), which is also installed by default.

By default the firewall isn't activated, because behind the ports that are exposed to the internet, there aren't any listening services. At least not in a standard installation. An attacker can't do anything without a listening service that keeps a port open.

However, in certain cases you do need a firewall. For instance when you share an unprotected wireless network, or when you've activated some services on your computer. So in order to be on the safe side, I advise to turn on the firewall in all cases.

You can turn on the firewall by means of the terminal (yikes!). This is how you do it:

Launch a terminal window.
(You can launch a terminal window like this: *Click*)

type (copy/paste):
sudo ufw enable

Press Enter. Type your password when prompted; this will remain entirely invisible, not even asterisks will show, which is normal.

Uncomplicated Firewall (ufw) has a sensible set of default settings (profile), which are fine for the vast majority of home users. So unless you have special wishes: you're done!
...snip..
If your need is different that's totally okay, I'm not out to set global firewall policies. :D Just got a feeling from your post that you might be new to linux, suffering from windows withdrawal symptoms still, and answered with that assumption in mind.
Hoser Rob
Level 20
Level 20
Posts: 11796
Joined: Sat Dec 15, 2012 8:57 am

Re: Firewall and few questions

Post by Hoser Rob »

MintyO wrote:... a normal home user doesn't really need a firewall and if you want to use one it's enough to turn the Mint's default one on ...
It is quite true that you don't need a fireewall in Linux in quite the same way you do in WIndows ... you'd have to be a complete techno idiot not to use one there. Linux, however, doesn't leave unused ports open the way Windows does.

But I still think a firewall should be used, and for most users the default rules of gufw GUI front end for ufw will be just fine. You may want to add mroe rules if you're doing something like running a bittorrent server. I've reinstalled Linux and forgot to enable the firewall at first a couple of times with no ill effects. But I still want one.

However I don't know of any ones with app specific rules and I'd be surprised if there was one. You don't get the loevel of integration in Linux like in Windows, which is largely why Linux uses much less RAM.
... got a feeling from your post that you might be new to linux, suffering from windows withdrawal symptoms still....
Got that feeling too. It's quite common AFAIK ... I guess I was lucky when I 1st installed Linux. I had enough background that I mostly knew what I was getting into :wink: .

WHen you say you get a souirceforge link when trying to install Lazarus, did you add the ppa for that or was that the default app repo? I've never seen such a thing from the default repos ... all dependencies should be there. I very rarely use ppa sources. Only if there's no other way. They are a very good way to break things if you don't know what you're doing.

I don't use any antivirus programs and I don 't think they're necessary. Linux is just a lot harder to hack than WIndows because the kernel runs in protected mode and in Linux (and other Unix like systems like OS X) the protection levels work.

In fact, and this may seem controversial, I've known a couple of real computer programmers who won't use AV programs in Windows because they don 't trust them. For good reason ... AV software has to have root level acces pretty much by definition and if you hack an AV program (which is disturbingly possible) you can do whatever you want. But these guys have advanced CS degrees and are so above my head that I do not understand how they manage such a thing.

There are Linux apps that are similar to Total Commander ... gnome commander is one ... but I don't believe in using alternate file managers anymore. File managers are pretty integrated with the DE/WM and things just never seem to run as nicely with ones other than the one that shipped with the DE. I like Xfce but for the longest time I hated the Thunar file mgr so I see the argument there but fortunately they improved it.

I don't know off the top of my head why the tomcat server is installed by default but it being a server program on a desktop version install seems to appear out of place to you. It isn't ... Linux/Unix uses tons of programs using a client/server model. Like the whole audio and video subsystems for a start. Unix, unlike Windows, was designed from the outset as a multiuser/multitasking OS. It has never assumed that you are the only user.
For every complex problem there is an answer that is clear, simple, and wrong - H. L. Mencken
altair4
Level 20
Level 20
Posts: 11460
Joined: Tue Feb 03, 2009 10:27 am

Re: Firewall and few questions

Post by altair4 »

Maybe firejail will get you some of the things you want. Here's a tutorial by one of our own:
Firejail as security sandbox for your programs
Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved.
Javoc

Re: Firewall and few questions

Post by Javoc »

Tell me please how to add rule for variable applications(for example for firefox) in standart linux mint Gufw ?
In preinstalled rules - not searched application with name - firefox.
And firefox process not displayed in Report tab.

How to add in Gufw rule for - not installed application(simple unpacked and running from catalog) ?

Who write so stupid interface for Gufw ????
Soffy but for newble in Linux - this interface is.....
User avatar
Moem
Level 22
Level 22
Posts: 16235
Joined: Tue Nov 17, 2015 9:14 am
Location: The Netherlands
Contact:

Re: Firewall and few questions

Post by Moem »

Javoc wrote:Who write so stupid interface for Gufw ????
Soffy but for newble in Linux - this interface is.....
Real newbies don't try to set rules or anything. With any luck they'll switch it on, set it and forget it.
Image

If your issue is solved, kindly indicate that by editing the first post in the topic, and adding [SOLVED] to the title. Thanks!
red03golf
Level 2
Level 2
Posts: 96
Joined: Tue Feb 09, 2016 10:32 pm

Re: Firewall and few questions

Post by red03golf »

The [Uncomplicated FireWall] ufw is already installed in Mint and it's very easy to use from the command line.

Every install I do starts with the following before I do anything else:
  • sudo ufw default deny
  • sudo ufw enable
  • sudo ufw deny out 1:52/tcp
  • sudo ufw deny out 1:52/udp
  • sudo ufw deny out 54:79/tcp
  • sudo ufw deny out 54:79/udp
  • sudo ufw deny out 81:122/tcp
  • sudo ufw deny out 81:122/udp
  • sudo ufw deny out 124:442/tcp
  • sudo ufw deny out 124:442/udp
  • sudo ufw deny out 444:65535/tcp
  • sudo ufw deny out 444:65535/udp
  • sudo ufw reload
The above rules:
  1. sets the default action to deny all traffic in / drop requests
  2. enables the ufw program to start at bootup
  3. (using ranges) block all ports out, on tcp and udp respectively, except 53, 80, 123, and 443
  4. reloads the firewall immediately to apply newly created rules
If you need other ports open such as 22 then it's a simple matter to amend the ranges from [1:52, etc] to [1:21, 23:52, etc]

There is much, much more which can be done with ufw apart from this simple (above) example - explore the docs!

If you prefer a GUI instead of the command line then gufw is available in the package manager.

To see the available commands and a few examples of how to set rules using the command line, type man ufw into the terminal.

For a shorter document type ufw --help into terminal.

IPTABLES is preinstalled and available from the command line. The corresponding terminal commands to the docs are iptables --help and man iptables.

EDIT:
One other thought, remember to also open ports in your gateway. Normally, 80 & 443 are already configured to exit the gateway, 53 &/or 123 'may' need to be enabled to exit the gateway.

If you enable a port in ufw but not in your gateway OR in your gateway but not in ufw then the traffic should still be blocked until both are configured to allow the traffic to pass.
Tin-foil hat? - Check!!
altair4
Level 20
Level 20
Posts: 11460
Joined: Tue Feb 03, 2009 10:27 am

Re: Firewall and few questions

Post by altair4 »

Javoc wrote:Tell me please how to add rule for variable applications(for example for firefox) in standart linux mint Gufw ?
gufw / ufw is not an application level firewall. I don't think even Firewalld can be used at an application level.
Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved.
red03golf
Level 2
Level 2
Posts: 96
Joined: Tue Feb 09, 2016 10:32 pm

Re: Firewall and few questions

Post by red03golf »

Iptables has string matching ability to handle application-level rules and filtering.

Linux Firewalls:
attack detection and response with iptables, psad, and fwsnort.
[Michael Rash, 2007]

has some info on it starting at:
page 69 (ch. 4)

There's no shortage of resources online: and on, and on, etc

Personally, I love the speed of PF, but I don't think there's a Linux port. Besides, iptables is extremely advanced and capable, and has everything anyone could want.
Tin-foil hat? - Check!!
Javoc

Re: Firewall and few questions

Post by Javoc »

I found Leopart firewall - in it screenshots - looks like that i want.
but can't find deb installation file(and no in repository) for this, and from unpacked zip archive it launched, but not displays active net app.
How to start it correctly ?
red03golf
Level 2
Level 2
Posts: 96
Joined: Tue Feb 09, 2016 10:32 pm

Re: Firewall and few questions

Post by red03golf »

Leopard's Firewall? as in for a Mac?
I don't know anything about running Mac software on Linux, sorry.
Tin-foil hat? - Check!!
Javoc

Re: Firewall and few questions

Post by Javoc »

red03golf wrote:Leopard's Firewall? as in for a Mac?
I don't know anything about running Mac software on Linux, sorry.
No it version for linux
From readme
# Leopard Flower personal firewall for Linux (LPFW)

LPFW gives the user control over which applications are allowed to use the
network.
It comes with a GUI.

These instructions apply specifically to Ubuntu 14.04 64-bit but are very
likely to work on other Linux distributions.
Please note that on 32-bit Linuxes lpfw may function incorrectly.

Install all dependencies:

```Shell
sudo apt-get install make g++ libnetfilter-queue-dev libnetfilter-conntrack-dev libcap-dev python-qt4
```

Compile:
```Shell
make
```

Quick start:
Run `lpfw` as root. Run python `gui/gui.py` as regular user.
i download archive from https://github.com/themighty1/lpfw - install dependency packages, but i dont know how to complete installation on step
Compile:
```Shell
make
How to compile it ?
red03golf
Level 2
Level 2
Posts: 96
Joined: Tue Feb 09, 2016 10:32 pm

Re: Firewall and few questions

Post by red03golf »

Excellent, looks like an interesting project.

The compile instructions are on that github page - scroll down to see the readme.md file contents (also, pasted below):
Install all dependencies:

sudo apt-get install make g++ libnetfilter-queue-dev libnetfilter-conntrack-dev libcap-dev python-qt4
Compile:

make
Quick start: Run lpfw as root. Run python gui/gui.py as regular user.
Tin-foil hat? - Check!!
Javoc

Re: Firewall and few questions

Post by Javoc »

i run make commant - it create files

Quick start: Run lpfw as root. Run python gui/gui.py as regular user.

but i cant start it
in console - no command lpfw
and gui program not whows any data
afrer simple launch lpfw - it possible closed because in system monitor - no process with this name
altair4
Level 20
Level 20
Posts: 11460
Joined: Tue Feb 03, 2009 10:27 am

Re: Firewall and few questions

Post by altair4 »

Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved.
Javoc

Re: Firewall and few questions

Post by Javoc »

altair4 wrote:How about Douane instead: Linux per-application firewalls - Doable? Douane.
Is this app only for archlinux ?
https://github.com/Douane/Douane/wiki/A ... -Packaging

Why developers not use simple way to pack all program files at single package installer :x
altair4
Level 20
Level 20
Posts: 11460
Joined: Tue Feb 03, 2009 10:27 am

Re: Firewall and few questions

Post by altair4 »

There may be a PPA available for it. You should check. Will it work in Mint rather than Ubuntu? I have no idea.
Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved.
Locked

Return to “Software & Applications”