Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse

Veyon Community Forum

  1. Home
  2. Help & Troubleshooting
  3. Problem with internet add-on when firewall is disabled

Problem with internet add-on when firewall is disabled

Scheduled Pinned Locked Moved Help & Troubleshooting
1 Posts 1 Posters 11 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • J Offline
    J Offline
    JMBiansan
    wrote last edited by
    #1

    Hello
    I'm doing tests with internet add-on with option block by firewall (I do not want to change routing) on windows computers.
    It doesn't work because the three firewalls are disabled on our computers.
    Would it be possible to modify the add-on so that:

    • when blocking is enabled, the add-on verifies and store firewall state
    • it activates firewall and then applies rules
    • when blocking is disabled, it restores firewall initial state
      ?

    Exemple of batch script to do that:

    @echo off
    :: Script pour activer le pare-feu Windows s'il est désactivé,
    :: puis le réactiver s'il était initialement activé

    :: Chemin du fichier temporaire pour sauvegarder l'état initial
    set "tempfile=%temp%\firewall_state.txt"

    :: Sauvegarde l'état initial de chaque profil
    (
    for %%p in (Domain,Private,Public) do (
    echo Verifying profile %%p...
    netsh advfirewall show %%pprofile state | find "ON" >nul
    if errorlevel 1 (
    echo %%p=OFF
    ) else (
    echo %%p=ON
    )
    )
    ) > "%tempfile%"

    :: Active le pare-feu pour chaque profil s'il est désactivé
    for %%p in (Domain,Private,Public) do (
    netsh advfirewall show %%pprofile state | find "ON" >nul
    if errorlevel 1 (
    echo Firewall is disabled for profile %%p.
    echo Firewall activation for profile %%p...
    netsh advfirewall set %%pprofile state on
    ) else (
    echo Firewall already activated for profile %%p.
    )
    )

    echo Firewall activated for all profiles

    echo Press any key to return to initial state...
    pause

    :: Rétablit l'état initial
    for /f "tokens=1,2 delims==" %%a in (%tempfile%) do (
    if "%%b"=="OFF" (
    echo Go back profile %%a to OFF...
    netsh advfirewall set %%aprofile state off
    )
    )

    :: Nettoyage
    del "%tempfile%" 2>nul

    echo Initial state restored

    Thanks in advance
    JM Biansan

    1 Reply Last reply
    0
    Reply
    • Reply as topic
    Log in to reply
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes


    Powered by NodeBB | Contributors
    • Login

    • Don't have an account? Register

    • Login or register to search.
    • First post
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups