Commit Graph

1830 Commits

Author SHA1 Message Date
Matthias Fischer
ba6fc476fb snort: Update to 2.9.9.0
Signed-off-by: Matthias Fischer <matthias.fischer@ipfire.org>
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
2016-12-18 15:19:52 +00:00
Michael Tremer
adb11e90df Always enable asynchronous logging
This patch always enables asynchronous logging which slows
down the system a lot on slow storage and some virtual environments.

It also removes the configuration options in the web
user interface, since this is not configurable any more.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
2016-11-29 12:18:41 +00:00
Alexander Marx
bc4a68812b BUG11242: Fix for adding 2 VPN Hosts/network with same name
If one has an IPSec network named "aaa" and an OpenVPn Host with the same name
it was not possible to group them together because of the same name.
Now the Network type is also checked wich allows Entries with same name, but different networks.

Fixes: #11242

Signed-off-by: Alexander Marx <alexander.marx@ipfire.org>
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
2016-11-17 14:11:50 +00:00
Matthias Fischer
5e818d6afb log.dat: cosmetical upgrade
Signed-off-by: Matthias Fischer <matthias.fischer@ipfire.org>
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
2016-10-25 12:15:07 +01:00
Matthias Fischer
58c2333bdc iptables.cgi: cosmetics - wider columns
Hi,

Since the first three columns of 'iptables.cgi' gave a nearly unreadable output
with large numbers, so I made 'pkts', 'bytes' and 'target'-columns a bit wider.

BEFORE - it was something like this:

Chain INPUT (policy DROP 0 packets, 0 bytes)
  pkts bytestarget        proc opt in     out source    destination
  32M38G    BADTCP        tcp  --  *      *   0.0.0.0/0 0.0.0.0/0
  32M38G    CUSTOMINPUT   all  --  *      *   0.0.0.0/0 0.0.0.0/0
  32M38G    P2PBLOCK      all  --  *      *   0.0.0.0/0 0.0.0.0/0
  32M38G    GUARDIAN      all  --  *      *   0.0.0.0/0 0.0.0.0/0
  00        OVPNBLOCK     all  --  tun+   *   0.0.0.0/0 0.0.0.0/0
  32M38G    IPTVINPUT     all  --  *      *   0.0.0.0/0 0.0.0.0/0
  32M38G    ICMPINPUT     all  --  *      *   0.0.0.0/0 0.0.0.0/0
  32M38G    LOOPBACK      all  --  *      *   0.0.0.0/0 0.0.0.0/0
  21M21G    CONNTRACK     all  --  *      *   0.0.0.0/0 0.0.0.0/0
  393873484KDHCPGREENINPUTall  --  green0 *   0.0.0.0/0 0.0.0.0/0
  645153642KGEOIPBLOCK    all  --  *      *   0.0.0.0/0 0.0.0.0/0
  386592304KIPSECINPUT    all  --  *      *   0.0.0.0/0 0.0.0.0/0
  386592304KGUIINPUT      all  --  *      *   0.0.0.0/0 0.0.0.0/0
  368332209KWIRELESSINPUT all  --  *      *   0.0.0.0/0 0.0.0.0/0 ctstate NEW
  368332209KOVPNINPUT     all  --  *      *   0.0.0.0/0 0.0.0.0/0
  368332209KTOR_INPUT     all  --  *      *   0.0.0.0/0 0.0.0.0/0
  368332209KINPUTFW       all  --  *      *   0.0.0.0/0 0.0.0.0/0
  309641833KREDINPUT      all  --  *      *   0.0.0.0/0 0.0.0.0/0
  309641833KPOLICYIN      all  --  *      *   0.0.0.0/0 0.0.0.0/0

AFTER - somehow better readable - I think: ;-)

Chain INPUT (policy DROP 0 packets, 0 bytes)
  pkts  bytes target         proc opt in     out source    destination
  32M   38G   BADTCP         tcp  --  *      *   0.0.0.0/0 0.0.0.0/0
  32M   38G   CUSTOMINPUT    all  --  *      *   0.0.0.0/0 0.0.0.0/0
  32M   38G   P2PBLOCK       all  --  *      *   0.0.0.0/0 0.0.0.0/0
  32M   38G   GUARDIAN       all  --  *      *   0.0.0.0/0 0.0.0.0/0
  0     0     OVPNBLOCK      all  --  tun+   *   0.0.0.0/0 0.0.0.0/0
  32M   38G   IPTVINPUT      all  --  *      *   0.0.0.0/0 0.0.0.0/0
  32M   38G   ICMPINPUT      all  --  *      *   0.0.0.0/0 0.0.0.0/0
  32M   38G   LOOPBACK       all  --  *      *   0.0.0.0/0 0.0.0.0/0
  21M   21G   CONNTRACK      all  --  *      *   0.0.0.0/0 0.0.0.0/0
  39387 3484K DHCPGREENINPUT all  --  green0 *   0.0.0.0/0 0.0.0.0/0
  64515 3642K GEOIPBLOCK     all  --  *      *   0.0.0.0/0 0.0.0.0/0
  38659 2304K IPSECINPUT     all  --  *      *   0.0.0.0/0 0.0.0.0/0
  38659 2304K GUIINPUT       all  --  *      *   0.0.0.0/0 0.0.0.0/0
  36833 2209K WIRELESSINPUT  all  --  *      *   0.0.0.0/0 0.0.0.0/0 ctstate NEW
  36833 2209K OVPNINPUT      all  --  *      *   0.0.0.0/0 0.0.0.0/0
  36833 2209K TOR_INPUT      all  --  *      *   0.0.0.0/0 0.0.0.0/0
  36833 2209K INPUTFW        all  --  *      *   0.0.0.0/0 0.0.0.0/0
  30964 1833K REDINPUT       all  --  *      *   0.0.0.0/0 0.0.0.0/0
  30964 1833K POLICYIN       all  --  *      *   0.0.0.0/0 0.0.0.0/0

Best,
Matthias

Signed-off-by: Matthias Fischer <matthias.fischer@ipfire.org>
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
2016-10-10 12:03:51 +01:00
Matthias Fischer
c5f633c917 guardian 2.0: suggested cosmetic changes
I did the following:

- Rearranged the fields on 'guardian.cgi' a bit - in a (hopefully) logical manner,
  so that they don't need so much room.
- Added some translation-strings and explanations to (revised) 'guardian.cgi'.
- Added missing language string(s), deleted obsolete.
- Deleted all guardian entries from standard language files in
  '/var/ipfire/langs'-directory.
- Added (upgraded) addon-specific language files to '/var/ipfire/addon-lang'-directory.

I hope, I didn't forget something...

Best,
Matthias

Signed-off-by: Matthias Fischer <matthias.fischer@ipfire.org>
Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2016-10-03 12:12:13 +01:00
Arne Fitzenreiter
642b831b72 Merge branch 'next' of git.ipfire.org:/pub/git/ipfire-2.x into next 2016-10-02 16:36:57 +02:00
Arne Fitzenreiter
e24d6112bb index.cgi: display unbound dns servers
Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2016-10-02 16:35:50 +02:00
Michael Tremer
5edc06b701 Remove IPAC stuff
This is unused for a very very very long time and serves
no purpose any more.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
2016-10-02 15:13:55 +01:00
Arne Fitzenreiter
3cf764f338 samba: default enable SMBv2.
Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2016-09-27 19:38:38 +02:00
Jonatan Schlag
4c8f144e58 Fix URL to list of public name servers in dns.cgi
We have only one english wiki, so the link to the list of public
dns servers can point directly to the right page.
(The link was also not correct).

Fixes: #11191

Signed-off-by: Jonatan Schlag <jonatan.schlag@ipfire.org>
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
2016-09-24 12:25:46 +01:00
Alexander Marx
bbe8e009b8 BUG11184: Error if DNAT address ends with 0 or 255 now disabled
When using dnat addresses, it is possible to use big subnets and host addresses like 172.16.0.0/12.
These addresses where rejected because it was recognised as network address.
The check is now removed.

Signed-off-by: Alexander Marx <alexander.marx@ipfire.org>
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
2016-09-15 18:58:51 +01:00
Michael Tremer
cc53e7ef23 unbound: Restart after local hosts have been modified
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
2016-09-12 20:52:51 +01:00
Michael Tremer
5fba8a0b1e Merge branch 'unbound' into next 2016-09-08 19:50:45 +01:00
Alexander Marx
3364c93e37 BUG11177: pppoe password not required anymore
fixes: #11177

There are providers which do not use passwords anymore.
For this reason the password field is no longer mandatory.

Signed-off-by: Alexander Marx <alexander.marx@ipfire.org>
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
2016-09-08 12:58:47 +01:00
Michael Tremer
df7340d2f3 Add unboundctrl
Control binary to relaunch unbound from the web user interface

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
2016-08-06 19:34:39 +01:00
Michael Tremer
9625be6f24 webinterface: Replace dnsmasq with unbound
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
2016-08-06 19:30:14 +01:00
Stefan Schantl
a27c40a05b ids.cgi: Drop guardian related code.
Guardian competely will be managed by it's own CGI.

Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2016-07-29 13:25:28 +02:00
Stefan Schantl
dadee76d7b guardian.cgi: Fix path to snort alert file.
Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2016-07-29 13:19:14 +02:00
Matthias Fischer
5cbfa0140c log.dat: Added entry for 'guardian'
Signed-off-by: Matthias Fischer <matthias.fischer@ipfire.org>
Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2016-07-29 13:19:14 +02:00
Stefan Schantl
f617f21cc0 guardian.cgi: Prevent from using "syslog" and "debug".
When using syslog as log facility and debug as log mode,
syslog does not log anything.

Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2016-07-29 13:19:14 +02:00
Stefan Schantl
efd9c5ffb4 guardian.cgi: Also generate ignore file when building the configuration.
Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2016-07-29 13:19:14 +02:00
Stefan Schantl
2daa1f5bb2 guardian.cgi: Show/Hide options using Java Script.
The options for configuring the log file location and
snort alert priority level now dynamically will be
displayed or hidden if the desired options or feature
is not used.

Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2016-07-29 13:17:56 +02:00
Stefan Schantl
2d17c6e6b8 guardian.cgi: Add support for selecting the used firewall action.
This will allow to choose between DROP and REJECT if guardian blocks an
attackers address.

Fixes #10xxx.

Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2016-07-29 13:17:56 +02:00
Stefan Schantl
1cc653239f guardian.cgi: Use new feature of ignore file inclusion.
Add support and usage of the recently introduced feature of
including other files in the ignore file to add
the red related IP-addresses to the ignore list on IPFire
systems.

Also use reload-ignore-list feature instead of reloading the
whole configuration on ignore list modifications.

Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2016-07-29 13:17:56 +02:00
Stefan Schantl
c880c2cb8a guardian.cgi: Create config and ignore file if they does not exist.
Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2016-07-29 13:17:56 +02:00
Stefan Schantl
62fd0e6fc7 guardian.cgi: Prevent from blocking the used DNS servers.
Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2016-07-29 13:17:56 +02:00
Stefan Schantl
c232e3489a guardian.cgi: Use private subfunction for gateway and DNS server detection.
Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2016-07-29 13:17:56 +02:00
Stefan Schantl
97849142bd guardian.cgi: Add function to generate the guardian.ignore file.
This function is responsible for collecting all required data,
like the green, blue, orange (if the interfaces are available),
red, gateway and used DNS server IP-addresses.

It will add als these addresses and the configured and enabled
user-defined ignored addresses/networks to the ignore file of
guardian to prevent from blocking any of them.

Note:

The IPFire and RED inteface related addresses also will be added
to the ignore file, even if there is no user-defined entry in the
list.

Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2016-07-29 13:17:56 +02:00
Stefan Schantl
7edbe06374 guardian.cgi: Use ignored config file.
The CGI now uses an own ignored configuration file for
storing host addresses and/or subnets which should be
ignored by guardian.

This allows to add remarks for them and to enable or disable
each entry individally at any time.

Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2016-07-29 13:17:56 +02:00
Stefan Schantl
891ba055f2 guardian.cgi: Use "getipstat" binary.
Rework the GetBlockedHosts() to use the "getipstat" binary
instead of the not longer available "guardianctrl" binary.

Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2016-07-29 13:17:56 +02:00
Stefan Schantl
af6856afc4 guardian.cgi: Send commands through socket connection.
The guardianctrl binary does not longer exists, use
the Guardian::Socket module to send various commands
by using the provided socket client.

Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2016-07-29 13:17:56 +02:00
Stefan Schantl
5295899104 guardian.cgi: Adjust code for generating the config file.
The config file format and values have been changed, so the
code to do the generation has to be adjusted.

Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2016-07-29 13:17:56 +02:00
Stefan Schantl
d530537998 guardian.cgi: Drop option for configure the path to the snort alertfile.
Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2016-07-29 13:17:56 +02:00
Stefan Schantl
723648ac92 guardian.cgi: Rename hash keys for enabled modules.
Rename the hash key names of enabled parser modules,
(services which should be monitored by guardian) to
keep the same name sheme than in the guardian config
file.

Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2016-07-29 13:17:56 +02:00
Stefan Schantl
b5f7d90327 guardian.cgi: Adjust CGI to use Locale::Codes::Country.
The module has been renamed some time ago.

Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2016-07-29 13:17:56 +02:00
Stefan Schantl
eff1feb8c7 guardian.cgi: Disable debugging.
Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2016-07-29 13:17:55 +02:00
Matthias Fischer
b1597f879c guardian.cgi: Suppress warnings for ${Header::colourgreen} variable.
Reference #10748.

Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2016-07-29 13:17:55 +02:00
Matthias Fischer
6a153ecdac guardian.cgi: Fix unititalized value "GUARDIAN_ENABLE_OWNCLOUD".
When the owncloud addon is not installed, this value was not
initialized correctly.

Reference #10748.

Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2016-07-29 13:17:55 +02:00
Matthias Fischer
922ddf0ef6 guardian.cgi: Use variable $pid instead of array element.
This will prevent from a lot of perl suggestions in the
apache error log.

Reference #10748.

Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2016-07-29 13:17:55 +02:00
Stefan Schantl
bfb860ceb7 guardian.cgi: Fix path to meta-owncloud.
Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2016-07-29 13:17:55 +02:00
Stefan Schantl
28981fac68 guardian.cgi: Add configure options for owncloud.
The related options only will be displayed when the owncloud addon
has been installed.

Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2016-07-29 13:17:55 +02:00
Stefan Schantl
36dbcf2e43 guardian.cgi: Allways read-in settings.
Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2016-07-29 13:17:55 +02:00
Stefan Schantl
c973d6da10 guardian.cgi: Some more input validation.
Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2016-07-29 13:17:55 +02:00
Stefan Schantl
473c725721 guardian.cgi: Correct indentation when writing out the config file.
Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2016-07-29 13:17:55 +02:00
Stefan Schantl
4a7fc9f634 guardian.cgi: Add dropdown for PriorityLevel selection.
Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2016-07-29 13:17:55 +02:00
Stefan Schantl
96655fa6b7 guardian.cgi: Fix and improve input validation.
Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2016-07-29 13:17:55 +02:00
Stefan Schantl
f8c3bfe050 guardian.cgi: Reload guardian if config or the ignorelist changes.
Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2016-07-29 13:17:55 +02:00
Stefan Schantl
a35a066845 guardian.cgi: Add option to configure the BlockCount.
Some small code fixes.

Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2016-07-29 13:17:55 +02:00
Stefan Schantl
06ff7e28d7 guardian.cgi: Accidently hardcoded some descriptions.
Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2016-07-29 13:17:55 +02:00