## Last changed: 2017-04-17 14:15:09 GMT-6
version 12.3X48-D45.6;
groups {
    jweb-security-logging {
        system {
            syslog {
                inactive: file loooooooggger {
                    any any;
                    archive files 1;
                    structured-data;
                }
                file logadog {
                    any any;
                    archive files 1;
                    structured-data;
                }
            }
        }
    }
}
system {
    host-name SCRUBBED;
    time-zone GMT-6;
    root-authentication {
        encrypted-password "SCRUBBED";
    }
    name-server {
        208.67.222.222;
        208.67.220.220;
    }
    name-resolution {
        no-resolve-on-input;
    }
    services {
        ssh;
        web-management {
            https {
                system-generated-certificate;
                interface vlan.3;
            }
            session {
                idle-timeout 60;
            }
        }
        dhcp {
            pool 192.168.1.0/24 {
                address-range low 192.168.1.2 high 192.168.1.254;
                name-server {
                    208.67.222.222;
                    208.67.220.220;
                }
                router {
                    192.168.1.1;
                }
            }
            pool 192.168.2.0/24 {
                address-range low 192.168.2.2 high 192.168.2.254;
                name-server {
                    208.67.220.220;
                    208.67.222.222;
                }
                router {
                    192.168.2.1;
                }
            }
            pool 172.19.143.0/24 {
                address-range low 172.19.143.13 high 172.19.143.13;
                name-server {
                    208.67.222.222;
                    208.67.220.220;
                }
                router {
                    172.19.143.1;
                }
            }
            static-binding 00:d0:4b:94:ec:74 {
                fixed-address {
                    192.168.2.33;
                }
                name-server {
                    208.67.222.222;
                    208.67.220.220;
                }
                router {
                    192.168.2.1;
                }
            }
            static-binding 00:10:75:4f:82:12 {
                fixed-address {
                    192.168.2.34;
                }
                name-server {
                    208.67.222.222;
                    208.67.220.220;
                }
                router {
                    192.168.2.1;
                }
            }
            static-binding 00:e0:81:74:16:91 {
                fixed-address {
                    172.19.143.13;
                }
                name-server {
                    208.67.220.220;
                    208.67.222.222;
                }
                router {
                    172.19.143.1;
                }
            }
        }
    }
    syslog {
        archive size 100k files 3;
        user * {
            any emergency;
        }
        file messages {
            any critical;
            authorization info;
        }
        file interactive-commands {
            interactive-commands error;
        }
        file policy_session {
            user info;
            match RT_FLOW;
            archive size 1000k world-readable;
            structured-data;
        }
        file logadog {
            any any;
            archive files 1;
            structured-data;
        }
    }
    max-configurations-on-flash 5;
    max-configuration-rollbacks 5;
    license {
        autoupdate {
            url https://ae1.juniper.net/junos/key_retrieval;
        }
    }
    ntp {
        server us.ntp.pool.org;
    }
}
security {
    log {
        mode event;
    }
    screen {
        ids-option untrust-screen {
            alarm-without-drop;
            icmp {
                ip-sweep;
                fragment;
                large;
                flood;
                ping-death;
                icmpv6-malformed;
            }
            ip {
                bad-option;
                record-route-option;
                timestamp-option;
                security-option;
                stream-option;
                spoofing;
                source-route-option;
                loose-source-route-option;
                strict-source-route-option;
                unknown-protocol;
                block-frag;
                tear-drop;
                ipv6-malformed-header;
            }
            tcp {
                syn-fin;
                fin-no-ack;
                tcp-no-flag;
                syn-frag;
                port-scan;
                syn-flood {
                    alarm-threshold 1024;
                    attack-threshold 200;
                    source-threshold 1024;
                    destination-threshold 2048;
                    timeout 20;
                }
                land;
                winnuke;
            }
            udp {
                flood;
            }
        }
    }
    nat {
        source {
            rule-set nsw_srcnat {
                from zone [ Home VPN Work ];
                to zone Internet;
                rule nsw-src-interface {
                    match {
                        source-address 0.0.0.0/0;
                        destination-address 0.0.0.0/0;
                    }
                    then {
                        source-nat {
                            interface;
                        }
                    }
                }
            }
        }
        destination {
            pool VPNBox {
                address 172.16.234.1/32 port 34916;
            }
            rule-set INT_TO_VPN {
                from zone Internet;
                rule INT_To_VPN {
                    match {
                        source-address 0.0.0.0/0;
                        destination-address 75.72.76.40/32;
                        destination-port {
                            34916;
                        }
                        protocol udp;
                    }
                    then {
                        destination-nat {
                            pool {
                                VPNBox;
                            }
                        }
                    }
                }
            }
        }
    }
    policies {
        from-zone Home to-zone Internet {
            policy home-internet {
                match {
                    source-address any;
                    destination-address any;
                    application any;
                }
                then {
                    permit;
                }
            }
        }
        from-zone Internet to-zone Home {
            policy internet-home {
                match {
                    source-address any;
                    destination-address any;
                    application any;
                }
                then {
                    deny;
                    log {
                        session-init;
                        session-close;
                    }
                }
            }
        }
        from-zone Work to-zone Internet {
            policy work-internet {
                match {
                    source-address any;
                    destination-address any;
                    application any;
                }
                then {
                    permit;
                }
            }
        }
        from-zone Internet to-zone Work {
            policy internet-work {
                match {
                    source-address any;
                    destination-address any;
                    application any;
                }
                then {
                    deny;
                    log {
                        session-init;
                        session-close;
                    }
                }
            }
        }
        from-zone VPN to-zone Internet {
            policy vpn-internet {
                match {
                    source-address any;
                    destination-address any;
                    application any;
                }
                then {
                    permit;
                }
            }
        }
        from-zone Internet to-zone VPN {
            policy openvpnin {
                match {
                    source-address any-ipv4;
                    destination-address home;
                    application openvpn_custom;
                }
                then {
                    permit;
                }
            }
            policy internet-vpn {
                match {
                    source-address any;
                    destination-address any;
                    application any;
                }
                then {
                    deny;
                    log {
                        session-init;
                        session-close;
                    }
                }
            }
        }
        from-zone Work to-zone Home {
            policy work-home {
                match {
                    source-address any;
                    destination-address any;
                    application any;
                }
                then {
                    deny;
                    log {
                        session-init;
                        session-close;
                    }
                }
            }
        }
        from-zone Home to-zone Work {
            policy home-work {
                match {
                    source-address any;
                    destination-address any;
                    application any;
                }
                then {
                    deny;
                    log {
                        session-init;
                        session-close;
                    }
                }
            }
        }
        from-zone Work to-zone VPN {
            policy work-vpn {
                match {
                    source-address any;
                    destination-address any;
                    application any;
                }
                then {
                    deny;
                    log {
                        session-init;
                        session-close;
                    }
                }
            }
        }
        from-zone VPN to-zone Work {
            policy vpn-work {
                match {
                    source-address any;
                    destination-address any;
                    application any;
                }
                then {
                    deny;
                    log {
                        session-init;
                        session-close;
                    }
                }
            }
        }
        from-zone VPN to-zone Home {
            policy vpn-home {
                match {
                    source-address any;
                    destination-address any;
                    application any;
                }
                then {
                    deny;
                    log {
                        session-init;
                        session-close;
                    }
                }
            }
        }
        from-zone Home to-zone VPN {
            policy home-vpn {
                match {
                    source-address any;
                    destination-address any;
                    application any;
                }
                then {
                    deny;
                    log {
                        session-init;
                        session-close;
                    }
                }
            }
        }
    }
    zones {
        security-zone Home {
            interfaces {
                vlan.1 {
                    host-inbound-traffic {
                        system-services {
                            all;
                        }
                        protocols {
                            all;
                        }
                    }
                }
            }
        }
        security-zone VPN {
            address-book {
                address home 75.72.76.40/32;
            }
            interfaces {
                vlan.2 {
                    host-inbound-traffic {
                        system-services {
                            all;
                        }
                        protocols {
                            all;
                        }
                    }
                }
            }
        }
        security-zone Work {
            interfaces {
                vlan.3 {
                    host-inbound-traffic {
                        system-services {
                            all;
                        }
                        protocols {
                            all;
                        }
                    }
                }
            }
        }
        security-zone Internet {
            address-book {
                address home 75.72.76.40/32;
            }
            screen untrust-screen;
            interfaces {
                ge-0/0/0.0 {
                    host-inbound-traffic {
                        system-services {
                            dhcp;
                        }
                    }
                }
            }
        }
    }
}
interfaces {
    ge-0/0/0 {
        unit 0 {
            family inet {
                dhcp;
            }
        }
    }
    ge-0/0/1 {
        unit 0 {
            family ethernet-switching {
                vlan {
                    members vlan1;
                }
            }
        }
    }
    ge-0/0/2 {
        unit 0 {
            family ethernet-switching {
                vlan {
                    members vlan1;
                }
            }
        }
    }
    ge-0/0/3 {
        unit 0 {
            family ethernet-switching {
                vlan {
                    members vlan1;
                }
            }
        }
    }
    ge-0/0/4 {
        unit 0 {
            family ethernet-switching {
                vlan {
                    members vlan1;
                }
            }
        }
    }
    ge-0/0/5 {
        unit 0 {
            family ethernet-switching {
                vlan {
                    members vlan1;
                }
            }
        }
    }
    ge-0/0/6 {
        unit 0 {
            family ethernet-switching {
                vlan {
                    members vlan1;
                }
            }
        }
    }
    ge-0/0/7 {
        unit 0 {
            family ethernet-switching {
                vlan {
                    members vlan1;
                }
            }
        }
    }
    ge-0/0/8 {
        unit 0 {
            family ethernet-switching {
                vlan {
                    members vlan3;
                }
            }
        }
    }
    ge-0/0/9 {
        unit 0 {
            family ethernet-switching {
                vlan {
                    members vlan3;
                }
            }
        }
    }
    ge-0/0/10 {
        unit 0 {
            family ethernet-switching {
                vlan {
                    members vlan3;
                }
            }
        }
    }
    ge-0/0/11 {
        unit 0 {
            family ethernet-switching {
                vlan {
                    members vlan3;
                }
            }
        }
    }
    ge-0/0/12 {
        unit 0 {
            family ethernet-switching {
                vlan {
                    members vlan3;
                }
            }
        }
    }
    ge-0/0/13 {
        unit 0 {
            family ethernet-switching {
                vlan {
                    members vlan3;
                }
            }
        }
    }
    ge-0/0/14 {
        unit 0 {
            family ethernet-switching {
                port-mode trunk;
                vlan {
                    members [ vlan1 vlan3 ];
                }
            }
        }
    }
    ge-0/0/15 {
        unit 0 {
            family ethernet-switching {
                port-mode access;
                vlan {
                    members vlan2;
                }
            }
        }
    }
    vlan {
        unit 1 {
            family inet {
                address 192.168.1.1/24;
            }
        }
        unit 2 {
            family inet {
                address 172.19.143.1/24;
            }
        }
        unit 3 {
            family inet {
                address 192.168.2.1/24;
            }
        }
    }
}
protocols {
    stp {
        disable;
    }
}
applications {
    application openvpn_custom {
        protocol udp;
        destination-port 34916;
    }
}
wlan {
    admin-authentication {
        encrypted-password "SCRUBBED";
    }
}
vlans {
    vlan1 {
        description Home;
        vlan-id 3;
        interface {
            ge-0/0/2.0;
        }
        l3-interface vlan.1;
    }
    vlan2 {
        description VPN;
        vlan-id 2;
        interface {
            ge-0/0/15.0;
        }
        l3-interface vlan.2;
    }
    vlan3 {
        description Work;
        vlan-id 4;
        interface {
            ge-0/0/14.0;
        }
        l3-interface vlan.3;
    }
}