19

Combining an External pfSense firewall with AskoziaPBX - webinar 2016, English

  • Upload
    askozia

  • View
    87

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Combining an External pfSense firewall with AskoziaPBX - webinar 2016, English
Page 2: Combining an External pfSense firewall with AskoziaPBX - webinar 2016, English

Your Hosts

Markus Ehlers Benjamin-Nicola Lüken

Page 3: Combining an External pfSense firewall with AskoziaPBX - webinar 2016, English

Why a Firewall?

Page 4: Combining an External pfSense firewall with AskoziaPBX - webinar 2016, English

Agenda

• Introduction

•Why a Firewall

•How to configure a PF Sence

•Questions

Page 5: Combining an External pfSense firewall with AskoziaPBX - webinar 2016, English

Secure Passwords • Digits, letters and special characters •Minimum: 8 characters • No words

adminpassword

000012344321

askoziaaizoksa

8C+inL6B}4_kQu3F6b?!1Q_ct!88_u7V.dLN

1@i+yY{L97Km

Page 6: Combining an External pfSense firewall with AskoziaPBX - webinar 2016, English

•DDoS attacks • Systems becomes slow • Registration not possible anymore

•Brute-Force attacks • Different password are tested until the account is hacked and misused

Why a Firewall?

Page 7: Combining an External pfSense firewall with AskoziaPBX - webinar 2016, English

Why a Firewall? Testing incoming numbers

Page 8: Combining an External pfSense firewall with AskoziaPBX - webinar 2016, English

Why a Firewall?

…NOTICE[2540]: chan_sip.c:26430 in handle_request_register: Registration from '"13796" <sip:[email protected]:5060>' failed for '212.83.257.8:5097' - No matching peer foundNOTICE[2540]: chan_sip.c:26430 in handle_request_register: Registration from '"13797" <sip:[email protected]:5060>' failed for '212.83.257.8:5097' - No matching peer foundNOTICE[2540]: chan_sip.c:26430 in handle_request_register: Registration from '"13798" <sip:[email protected]:5060>' failed for '212.83.257.8:5097' - No matching peer foundNOTICE[2540]: chan_sip.c:26430 in handle_request_register: Registration from '"13799" <sip:[email protected]:5060>' failed for '212.83.257.8:5097' - No matching peer foundNOTICE[2540]: chan_sip.c:26430 in handle_request_register: Registration from '"13800" <sip:[email protected]:5060>' failed for '212.83.257.8:5097' - No matching peer foundNOTICE[2540]: chan_sip.c:26430 in handle_request_register: Registration from '"13801" <sip:[email protected]:5060>' failed for '212.83.257.8:5097' - No matching peer found…

SIP Brute-Force attacks

Page 9: Combining an External pfSense firewall with AskoziaPBX - webinar 2016, English

Why a Firewall?

…dropbear[19696]: Bad password attempt for 'root' from 61.174.251.226:37142dropbear[19696]: Bad password attempt for 'root' from 61.174.251.226:37142dropbear[19696]: Bad password attempt for 'root' from 61.174.251.226:37142dropbear[19696]: Bad password attempt for 'root' from 61.174.251.226:37142dropbear[19696]: Exit before auth (user 'root', 10 fails): Max auth tries reached - user 'root' from 61.174.251.226:37142dropbear[19713]: Child connection from 61.174.251.226:41271dropbear[19713]: Bad password attempt for 'root' from 61.174.251.226:41271dropbear[19713]: Bad password attempt for 'root' from 61.174.251.226:41271dropbear[19713]: Bad password attempt for 'root' from 61.174.251.226:41271dropbear[19713]: Bad password attempt for 'root' from 61.174.251.226:41271dropbear[19713]: Bad password attempt for 'root' from 61.174.251.226:41271…

SSH attacks

Page 10: Combining an External pfSense firewall with AskoziaPBX - webinar 2016, English

Why a Firewall? What can happen?

• High phone bills • System gets “taken over” • Passwords get sold (such as for provider & e-mail accounts) • PBX is used for "free" phone calls • Call-through and fax devices are used for scams • System is used as a spam distributor • Calls get recorded (espionage) • Trojaner/Viren get installed • Additional IT systems become infected (internal network) • Loss of face in front of your customer

Page 11: Combining an External pfSense firewall with AskoziaPBX - webinar 2016, English

Why a Firewall? Solution

• Blocking ports by means of a global firewall •Port forwarding is dangerous and not necessary! • Using NAT-Firewall • Activating Askozia firewall • Blocking ports for the internet • Using Fail2Ban • IP is blocked automatically after n tries • Attacks are effectively prevented

• Using VPN • Calls are encrypted • No audio problems

• A poorly configured firewall is as good as no firewall.

Page 12: Combining an External pfSense firewall with AskoziaPBX - webinar 2016, English

Application

Presentation

Session

Transport

Network

Data Link

Physical

SIP

IP

MAC

Page 13: Combining an External pfSense firewall with AskoziaPBX - webinar 2016, English

Application

Presentation

Session

Transport

Network

Data Link

Physical

SIP

IP

Laye

r 2 (S

witc

h)

Laye

r 3 (R

outin

g)

SIP-

ALG

, SIP

-Pro

xy

MAC

Page 14: Combining an External pfSense firewall with AskoziaPBX - webinar 2016, English

Application

Presentation

Session

Transport

Network

Data Link

Physical

SIP

IP

Laye

r 2 (S

witc

h)

Laye

r 3 (R

outin

g)

SIP-

ALG

, SIP

-Pro

xy

Dee

p Pa

ckag

e In

spec

tion

MAC

Page 15: Combining an External pfSense firewall with AskoziaPBX - webinar 2016, English

Application

Presentation

Session

Transport

Network

Data Link

Physical

SIP

IP Network IPe.g. 216.123.123.123

SIP IPe.g. 192.168.1.5

Laye

r 2 (S

witc

h)

Laye

r 3 (R

outin

g)

SIP-

ALG

, SIP

-Pro

xy

Dee

p Pa

ckag

e In

spec

tion

MAC

Page 16: Combining an External pfSense firewall with AskoziaPBX - webinar 2016, English

RouterDHCP

FirewallDHCP

NAT IPv4172.0.0.x

Internet

Public IP216.123.123.123

LAN

NAT IPv4192.168.1.x

SIP-ServerSIP-Gateway(Provider)

192.168.1.5

216.123.123.123

Firewall configuration Doubled NAT

Page 17: Combining an External pfSense firewall with AskoziaPBX - webinar 2016, English

RouterDSL-Mode

FirewallDHCP-Server

PPPoE216.123.123.123

Internet

Public IP216.123.123.123

LAN

NAT IPv4192.168.1.x

SIP-ServerSIP-Gateway(Provider)

192.168.1.5

216.123.123.123

Firewall configuration Doubled NAT

Page 18: Combining an External pfSense firewall with AskoziaPBX - webinar 2016, English

Firewall configuration pfSense

• System > Advanced > Firewall/NAT

•Firewall Optimization Options -> Conservative UDP timeouts results in connection losses and missing SIP registration

•Disable firewall scrub Could result in packet loss on some network cards

•Firewall rules for WANAdd SIP provider as an aliasAllow all connections from that added alias

Page 19: Combining an External pfSense firewall with AskoziaPBX - webinar 2016, English

Questions? Time to wake up!

[email protected]