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 - p.dungel

#1
thanks for your reply but

firstly that would not have solved the problem, since I could not access the domain via gui as well and secondly as it turned out, since I left the https port for the gui at 443 it seens that the response came from the opnsense client and not the webserver, because since I changed the https port to something different I again get no answer as my original problem was
#2
Ich hab das LAN nur auch noch dazugenommen in der Hoffnung, dass das was bringt - leider nicht - war beim ursprünglichen Setting nicht dabei.

Prinzipiell bin ich mir ziemlich sicher, dass mein NAT passt (ist ja eigentlich nicht so kompliziert), fällt dir noch eine andere Möglichkeit ein, warum ich genau vom OPNsense Client nicht auf den Webserver zugreifen kann, von allen anderen Clients im LAN aber schon?

Kann es sein, dass ich irgendwie OPNsense (also den Router) durch eine Einstellung (Interface, ...) geblockt habe.



Danke im voraus
#3
ich habe bei
NAT -> Port Forward:

  • Interface: LAN und WAN
  • Protocol: TCP
  • Source: any
  • Source port range: any
  • Destination: meine externe IP
  • Destination Port Range: HTTPS/443
  • Redirect target IP: 192.168.0.2 (IP von meinem Webserver)
  • Redirect target port: HTTPS/443

und bei
NAT -> Outbound

  • Interface: LAN
  • Protocol: TCP
  • Source Address: 192.168.0.0/24 (das interne LAN)
  • Source Port: any
  • Destination Address: 192.168.0.2 (LAN Adresse des Webservers)
  • Destination Port: HTTPS/443
  • Translation/target 192.168.0.1 (LAN Adresse des Routers)

Für alle LAN-Clients außer dem Router funktioniert alles, bemerkt habe ich das ganze, weil ich meine Config auf eine lokale Nextclound Instanz über ihre externe Domain backupen wollte.
#4
ja damit hattest du recht, das behebt das "curl ssl problem" :)
Allerdings nicht so wie ich das wollen würde. Die antwort wohl vom gui und nicht vom webserver, weil nun bekomme ich wieder keine antwort vom server :(
#5
I setup network reflection based on this guidehttps://docs.opnsense.org/manual/how-tos/nat_reflection.html#nat-method1
, now I'm finally able to reach my local webserver via its external ip from my router - which has not worked before, even though i could access the webserver via external ip from other lan clients.

the problem now is, when I try to curl https://mydomain.com  from the routers console I get  an error (curl: (60) SSL: no alternative certificate subject name matches target host name 'mydomain.com')
I use letsencypt wildcard certificates who work both for my other lan clients and for external clients

anyone got an idea what the problem could be?

my setup:

                ISP
                   |
                   |
        Router 192.168.0.1
                    |
                  /   \
                /       \
              /           \
webserver       other lan clients
192.168.0.2    192.168.0.3-100 (from dhcp)
#6
ich habe nach dieser Anleitung https://docs.opnsense.org/manual/how-tos/nat_reflection.html#nat-method1 network reflection eingerichtet, damit kann ich endlich von meinem router auf den lokalen webserver über seine externe ip adresse zugreifen - das ging vorher nicht, für andere lan clients hat das problemlos funktionert.

das problem ist, dass wenn ich curl https://meinedomain.com ausführe einen fehler bekomme (curl: (60) SSL: no alternative certificate subject name matches target host name 'meinedomain.com')
ich habe ein letsencryp wildcard zertifikat für die domain, und sowohl von extern als auch anderen lan clients funktioniert alles ohne probleme.

irgendjemand eine idee woran das liegen kann?

mein setup:

                ISP
                   |
                   |
        Router 192.168.0.1
                    |
                  /   \
                /       \
              /           \
webserver       andere lan clients
192.168.0.2    192.168.0.3-100 (von dhcp zugewiesen)


#7
Danke für die Antwort, leider hat das nicht geholfen

ich hatte die haken bei Reflection for Port Forwards und Automatic outbound NAT for Reflection ohnehin gesetzt nur der bei Reflection for 1:1 hat gefehlt, den habe ich nun auch gesetzt, hat aber wie schon geschrieben leider nicht geholfen.

Irgendeine Idee wie ich dem Fehler auf die Spur kommen könnte?
#8
Yesterday i tried to backup the config to my local nextcoud instance, while doing so I noticed, that the firewall cannot access my webserver via the public ip address

The firewall has the IP 192.168.0.1, the webserver 192.168.0.200 all other clients on the LAN are in the range 192.168.0.100 to 192.168.0.150

I can access my webserver from the web and all clients in the LAN except from the firewall either via the public IP or the domain name e.g. https://example.com. All requests are forwarded to the webserver by portfowarding (Firewall -> NAT -> Portforward)


The Forward rules are:
Source
Interface WAN
Proto TCP
Address *
Port *

Destination
Address WAN Address
Ports 80 resp 443

NAT
IP Webserver IP
Ports 80 resp 443

From the firewall (OpnSense) I can connect to the weserver via its internal IP (192.168.0.200) but not via public IP


This is a simple schematic of the networt - generally pretty simple

     WAN / Internet
            :
            : /Cable-Provider
            :
            |
        WAN | IP or Protocol
            |
      .-----+------.   
      |  OPNsense  |
      '-----+------'   192.168.0.1
            |
        LAN | 192.168.0.1/24
            |
      .-----+------.
      | LAN-Switch |
      '-----+------'
            |
    ...-----+------... (Clients/Servers)
#9
Ich habe gestern versucht, meine config-Datei auf meine lokale nextcloud zu backuppen, dabei ist mir aufgefallen, dass ich von der Firewall aus nicht auf meine öffentliche Adresse zugreifen kann.

Die Firewall hat die IP 192.168.0.1, der Webserver 192.168.0.200 die normalen Lan Clients befinden sich zwischen 192.168.0.100 und 192.168.0.150

Von allen Clients und auch dem Internet kann ich normal über die öffentliche IP auf den Webserver zugreifen also z.B. mittels https://example.com, diese Anfragen werden per Port Forward Regel (Firewall -> NAT -> Portforward) an den Webserver weitgerleitet:

Source
Interface WAN
Proto TCP
Address *
Port *

Destination
Address WAN Address
Ports 80 bzw 443

NAT
IP Webserver IP
Ports 80 bzw 443

Von der Firewall (OpnSense) kann ich den Webserver nur über die interne IP Adresse 192.168.0.200 erreichen aber weder über die öffentliche direkt noch die domain


Prinzipiell ist das der Aufbau des Neztwerkes


     WAN / Internet
            :
            : /Cable-Provider
            :
            |
        WAN | IP or Protocol
            |
      .-----+------.   
      |  OPNsense  |
      '-----+------'   192.168.0.1
            |
        LAN | 192.168.0.1/24
            |
      .-----+------.
      | LAN-Switch |
      '-----+------'
            |
    ...-----+------... (Clients/Servers)