Menu

Show posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Show posts Menu

Messages - RamSense

#706
I use Opnsense with Sensei and have ads blocked for the Lan devices. Works great. Only problem is with the mobile devices connected by 4g-vpn redirect gateway- sensei -> does not block ads on those devices. Everything else is working. This while I have added both interfaces in sensei-configuration.

Anybody else having this issue? Know how to solve?
#707
I got the sensei working on VPN. I found this link and firewall NAT OUTBOUND RULE. After I added it, it works.
But I do not know what this NAT OUTBOUND RULE does.

https://preview.redd.it/37la84y46xs51.png?width=1583&format=png&auto=webp&s=66c26b7660fe4084ac1ef9e3838ab871c3655766

#708
thnx again for your help and fast reply.

regards
Ramon
#709
Thanks for the explanation. Maybe I can change the behavior by pointing the isp ip in nginx to another (empty) webpage on the synology? should have a self signed certificate I presume?

thnx again for helping with my learning curve in OPNSense
#710
Hi Fabian,
I have one strange thing left. When I use my ISP ip on an external device, it shows up my webserver website, while using the mydomain.com show the correct website, I do not want to have my ISP ip to load a website.
do you know how to prevent this?

best regards
Ramon
#711
openVPN -> OpnSense + DoH + DNSsec + Suricata + Sensei protection

What I want to achieve is -> Iphone or other wireless device with openvpn connection to opnsense vpn and have all the data pushed through the opnsense firewall so that all devices have the protection of opnsense with suricata and sensei and DoH and DNSsec running already on it and available to opnsense LAN devices.

So in short: iphone vpn -> all data communication with -> opnsense + DoH + DNSsec + suricata + sensei

My opnsense is running already with opnsense + DoH + DNSsec + suricata + sensei

I have added openvpn and I can make connection with my iphone 4g.
When I do visit page 1.1.1.1/help I noticed not being protected.
I added on the client export custom config: dhcp-option DNS 192.168.1.1

Did again test 1.1.1.1/help and now I do have connection to 1.1.1.1 and DoH.
But when I do a check on " what is my ip". On my iphone I see that it is still the ip of the cellular company and not the address of my home ISP IP. ?
And also ads are not being blocked on my iphone by sensei.
(When I change server with redirect gateway enabled, the result is that facebook app loads slow/weird and it looks like something is not configured right. So disabled this in my current config. )

What am I doing wrong here. or what am I missing / failed to add, or should I configure differently?

This is the setup:
2 interfaces. LAN – igb 1 and WAN – igb0

Firewall rules OpenVPN
interface openvpn, TCP/IP version: IPv4, protocol ANY, source "single host or Network" 10.0.8.0/24, destination any and destination port ANY.

Firewall rules WAN
interface WAN, TCP/IP version: IPv4, protocol UDP, source any, destination any, destination port range OpenVPN (1194)

VPN server:
protocol UDP, device mode TUN, interface WAN, port 1194, IPv4 tunnel network: 10.0.8.0/24, IPv4 local network 192.168.1.0/24.

VPN Client
Hostname: my ISP ip, port 1194, custom config: dhcp-option DNS 192.168.1.1

Thanks in advance for the solution! Would be great to have all devices protected with opnsense.

Ramon
#712
Thanks again for your help!
That sounds logic. I am going to experiment further with this. It feels great to have this working. Could not have done it without you! Loving OPNsense more and more everyday.

Best regards
Ramon
#713
Dear Fabian, First Merry Christmas!
I have nginx running with the " manual mode". The lets encrypt certificate imported at opnsense and used them in nginx. The website is running, so thank you for your help with that. With this manual mode I have to manually import the certificate every time there is a renewal. I understand that.

Now if I go for the automation option with ACME. Do I understand it correctly that ACME will make and renew the lets encrypt certificate automatically and I use then in nginx proxy. And does the synology webstation also maintain its lets encrypt certificate like currently in the manual version I am using now, or is that not correct? and has synology webstation in this ACME solution no longer a certificate on the synology itself?

Kind regards
Ramon
#714
Thanks Fabian!
The firewall rule was the key. Got nginx running... somewhat.
Now I have to figure out how to get it working with proper ssl certificate and HTTPS.
i will do a web search/google into ACME plugin..

do you know of some sort of a guide for nginx https and acme?

Thanks again for pointing me into the right direction!
#715
Thank you Fabian for your reply.
So in the firewall I should delete the portforward, go to firewall rule- wan  - and add a rule for ports HTTPS and HTTP, and to what destination do I point? the wan address?
And I have to export the lets encrypt certificate from synology and import it in opnsense. ok.
And every time the free certificated is being updated I have to change it in opnsens? Is there not an automation way like synology updates it with lets encrypt? Sorry if this sounds like easy questions. Opnsense is very new for me

thanks again,
Ramon
#716
Nginx website protection opnsense

Hi all, I am recently running opnsense and I love all that it does. It works like a charm, but now I want to make my website protected behind nginx plugin with WAF.
I changed the default port of OPNsense to 444, so now port conflicts

My setup is now ISP – Opnsense – access point – Synology webstation.
I have on my opnsense – firewall – NAT - a port forward  for 80 and 443 to the IP of the Synology webstation 198.168.1.133
Synology runs the webstation with an Lets encrypt certificate for the webserver, and the site runs correctly with https. Port 80 is for lets encrypt to renew certificates and 443 for the ssl for instance I think.

Now I want to remove the port forward and have the website behind / through the nginx plugin with waf. This is what I have done, but it does not work. What have I done wrong? What steps do I have to add / change?
Your help is very much appreciated!

1.  I have configured the upstream server. Description "webserver", ip 198.168.1.133, port 80, priority 1, maximum connections 2500, max fails 10 and time out 60

2. I have configured the upstream. Description "backend", server  I selected the above "webserver", load balancing "weighted round robin", enable tls: selected/checked, tls supported tls v1.2 and v1.3, tls session reuse: selected/checked, tls trusted certificate: none selected

3. I have downloaded the NAXSI WAF rules

4. I added a new location HTTPS:  description "webserver_root", URL pattern / , match type " none", url rewriting " nothing selected", enable security rules: selected/checked, then 3 blank, custom security policy: I have selected all the options. Upstream servers "backend", patch prefix empty, cache directory " empty", Force HTTPS: selected/checked, enable HTTP/2 preloading: selected/checked.

5. I added HTTP server: http listen port: 80, https listen port: 443, domain "mywebserverdomain.com", locations "webserver root", url rewriting " nothing selected", file system root: empty, TLS sertificate "none", client CA certificate "none", access log "default", enable Lets Encrypt plugin support: selected/checked, Charset utf-8, HTTPS only: selected/checked, IP ACL "none", advanced ACL_authentication backend "local database", security header "none", limit request " nothing selected"

(Do I need to install the lets encrypt plugin in opnsense? And how to configure that? I have not done so because the certificates are on the sinology. )

6. I made a port forward rule: NAT – portfoward: interface WAN, tcp/ip version: IPv4, protocal TCP/UDP, destination " wan address", destination port range from HTTPS to HTTPS, redirect target ip " 192.168.1.1" (opnsense ip), redirect target port HTTPS, description "port forward to nginx proxy". (p.s. I have deleted the earlier made port forward rules 80 and 443 to the ip of the synology web station.)

7. Nginx global settings,  enable nginx selected/checked

The result is that my website does not load on LAN devices, and it does not load from external devices.
What have I done wrong / forgot / have to change?!

Thank you very much in advance for your help!!

Regards
Ramon