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 - monateng

#1
Habe einen allgemeinen Leitfaden geschrieben.
Damit habe ich den Fehler zwischen den Paketen os-squid & os-cicap gelöst. Wobei os-squid noch immer ein "Segmentation fault" wirft.

Das Thema mit squid behandelt bereits das folgende Ticket:
> https://forum.opnsense.org/index.php?topic=47622.0 (Deutsch: June 15, 2025)
> https://forum.opnsense.org/index.php?topic=45502.0 (Englisch: January 30, 2025)

Lösung zu os-squid soll ein Update in Zukunft bringen: (https://github.com/opnsense/plugins/issues/4500)


---- Anleitung extra in Englisch
open Web Dashboard

[ Set OPNsense to old Version ]
System > Firmware > Settings
# advanced mode
# Flavour > (custom) > 25.1/MINT/25.1/latest/
# Reboot > [x] Always reboot after a successful update
{ Save }


[ Install ClamAV ]
System > Firmware > Plugins
# os-clamav
{ + }


System > Settings > Administration
### Secure Shell
# [x] Enable Secure Shell
# SSH Port
# Listen Interface
{ Save }


[ Fix it in CLI / SSH / Shell ]
> ssh USER@IP
# rm /var/db/clamav/freshclam.dat


[ Download initial signatures ]
#> freshclam


Go back to Web Dashboard
[ Enable and start clamAV-daemon ]
OPNsense > Services > ClamAV > Configuration

[x] Enable clamd Service
[x] Enable freshclam Service
{ Save }


[ Install CICAP ]
System > Firmware > Plugins
# os-c-icap
{ + }


Services > C-ICAP > Configuration > General
# [x] Enable c-icap service
{ Save }


Services > C-ICAP > Configuration > Antivirus
# [x] Enable ClamAV
# [x] Pass on error
{ Save }


[ Generate certificate ]
System > Trust > Authorities
{+}
[Create an internal Certificate Authority] Method
# Description
[SHA512] Digest Algorithm
[825] Lifetime (days)

# Description
# Country Code
# State or Province
# City
# Organization
# Organizational Unit
# Email Address
# Common Name




[ Install Squid / Web Proxy ]
System > Firmware > Plugins
# os-squid
{ + }


Services > Squid Web Proxy > Administration > General Proxy Settings
[x] Enable Proxy
[OPNsense] User error pages
{ Apply }


Services > Squid Web Proxy > Administration > Forward Proxy > General Forward Settings
[LAN] Proxy interfaces
[x] Enable Transparent HTTP Proxy
[x] Enable SSL inspection
# CA to use
{ Apply }


Services > Squid Web Proxy > Administration > Forward Proxy > ICAP Settings
[x] Enable ICAP
[icap://[::1]:1344/avscan] Request Modify URL
[icap://[::1]:1344/avscan] Response Modify URL
{ Apply }



#> REBOOT OPNsense


[ ADD Firewall Rule for HTTP ]
Services > Squid Web Proxy > Administration > Forward Proxy > General Forward Settings
[x] Enable Transparent HTTP Proxy
{i} Add a new Firewall rule
# Description I - HTTP > Squid > c-icap > ClamAV > WAN
{ Save }
{ Apply changes}


[ ADD Firewall Rule for HTTP ]
Services > Squid Web Proxy > Administration > Forward Proxy > General Forward Settings
[x] Enable SSL inspection
{i} Add a new Firewall rule
# Description I - HTTPs > Squid > c-icap > ClamAV > WAN
{ Save }
{ Apply changes}



[ Add CA to Windows 10/11 ]
>> https://learn.microsoft.com/de-de/biztalk/adapters-and-accelerators/accelerator-swift/adding-certificates-to-the-certificates-store-on-the-client


[ Add CA to your Browser ]
>> brave://certificate-manager/localcerts/usercerts
>> chrome://certificate-manager/localcerts/usercerts
>> edge://certificate-manager/localcerts/usercerts


[ Test Browsing ]
>> https://www.eicar.org/download-anti-malware-testfile/
>> https://secure.eicar.org/eicarcom2.zip
>> https://secure.eicar.org/eicar_com.zip
>> https://raw.githubusercontent.com/fire1ce/eicar-standard-antivirus-test-files/refs/heads/master/eicar-excel-dde-cmd-powershell-echo.xls
>> https://raw.githubusercontent.com/fire1ce/eicar-standard-antivirus-test-files/refs/heads/master/eicar-com.com
>> https://raw.githubusercontent.com/fire1ce/eicar-standard-antivirus-test-files/refs/heads/master/eicar-excel-macro-cmd-echo.xls
>> https://raw.githubusercontent.com/fire1ce/eicar-standard-antivirus-test-files/refs/heads/master/eicar-powerpoint-action-powershell-echo.ppt
>> https://raw.githubusercontent.com/fire1ce/eicar-standard-antivirus-test-files/refs/heads/master/eicar-word-macro-msgbox.doc


> https://forum.opnsense.org/index.php?topic=47622.0


[ Download BackUp ]
System > Configuration > Backups



#> REBOOT OPNsense

Check until reboot all Websites if they can be visited as normal and expected

System > Firmware > Settings
Update Version
> https://pkg.opnsense.org/
#2
Hey @SirBoerky
bei der Lösung meines Problems bin ich auf deinen Post hier gestoßen.

Bei meinem Problem ist das Zusammenspiel os-squid & os-cicap fehlerhaft gewesen.
> https://forum.opnsense.org/index.php?topic=48208.0


Aber auch bei mir hat squid erst ab Version 25.7.1 das Problem mit dem "Segmentation fault".
Jedoch die 'alte' config aus der 25.1 Version startet squid am Ende zuverlässig.


Ansatz ist:
Version ausssuchen auf:
https://pkg.opnsense.org/FreeBSD:14:amd64/25.1/MINT/

Web Dashboard

[ Version ]
System > Firmware > Settings
# advanced mode
# Flavour > (custom) > 25.1/MINT/{VERSION}/latest/
# Reboot > [x] Always reboot after a successful update
{ Save }


System > Firmware > Status
{ Check for updates }

....


Nach erfolgreicher Konfiguration und Test auf die aktuelle Version (heut: 25.7.1) zu aktualisieren.


Hoffe ich konnte dir helfen, so dass der Service deiner Firewall nutzbar ist.
#3
Hi @fw115
vielen Dank für deine Erklärung. Leider habe gab es keine clamd_mod Datei mit dem Inhalt "*version*".

Auch ein weiteres Update heut hat keine Veränderung gebracht.

root@fw001x:~ # clamd --version
ClamAV 1.4.3/27720/Sat Aug  2 10:36:59 2025


root@fw001x:~ # c-icap-config --version
0.6.3


root@fw001x:~ # opnsense-version
OPNsense 25.7.1_1 (amd64)


Habe zur "Lösung" nun die mir bekannte Version wie folgt festgesetzt.

System > Firmware > Settings > Flavour >> "{OPNsense-release}/MINT/{OPNsense-Version}/latest/" > { Save }

System > Firmware > Status > { Check for updates }
Per Browser könnt Ihr den Pfad vorab Testen
> https://pkg.opnsense.org/releases/
>> >> https://pkg.opnsense.org/FreeBSD:{VERSION}:{ARCH}/{OPNsense-release}/MINT/{OPNsense-Version}/


Um den Fehler allerdings am Ende in der aktuellen Version zu eliminieren, habe ich keine Lösung.
#4
Vielen Dank @fw115,
auch bei der Neuinstallation habe ich den Fehler. Deshalb habe ich auch nur expliziet diese Zeile herausgenommen.

Hast Du eine Idee wie man dies (manuell) lösen kann?
> https://sourceforge.net/p/c-icap/news/2025/07/the-c-icap-064-is-released-/
#5
Servus,
meine Firewall hat 32GB RAM. Als Version läuft derzeit die aktuelle 25.7

Wer hat mit dieser Version bereits ein ClamAV mit einem transparenten Proxy erfolgreich im Einsatz?



Wir wollen zentral auf der Firewall mit ClamAV uns vor bereits bekannten Viren schützen.

Habe dazu mehrere Anleitungen gesichtet.
- https://www.xinux.net/index.php/OPNsense_Transparenter_Proxy_Schritt_f%C3%BCr_Schritt
- https://www.zenarmor.com/docs/de/netzwerksicherheitstutorials/wie-aktiviert-man-den-virenschutz-in-opnsense


Anpassungen der conf Dateien habe ich nicht umgesetzt.
> /usr/local/etc/c-icap/c-icap.conf


Erhalte diese Meldung.
Critical   c-icap   main proc, WARNING: Can not check the used c-icap release to build service clamd_mod.so


Vielleicht ist ja auch meine Vorgehensweise fehlerhaft.
#6
Das hat wunderbar funktioniert 👍☺️
#7
Hallo,
gibt es eine Möglichkeit ein WireGuard Interface per CLI / Konfiguration ein angepassten Namen zu vergeben?
Hab bisher keine Lösung gefunden ein Interface umzubenennen.

Bisher benenne ich ein Interfaces bei OpenWRT und Linux-Kisten nach einem Namenschema.
So dass ich es, wie bei einem vLAN anhand des Namens sofort zuordnen kann.


Vielen Dank
#8
Servus,
bin neu bei dem Thema OPNsense und konnte bisher alle meine Fragen durch euch im Forum lösen.

Lokal habe ich drei Subnetze. Jedes Subnetz soll eine Virtuelle IP bekommen. Die Virtuellen IPs sollen den Port 53 UDP
an das lo0 weiterreichen auf Port 5353.

Laut meinem Verständnis der OPNsense Doku sollte man bei MultiWAN den Unbound DNS laufen lassen.
Deshalb brauche ich es jetzt umständlich, um per "Client settings" in AdGuard Home Host spezifische Regeln anwenden
zu können. D.h. ein NAT ist leider nicht die Lösung.


Firewall: NAT: Outbound steht auf "Manual outbound NAT rule generation (no automatic rules are being generated)".


Stehe für eine Lösung bereit und würde mich sehr freuen.