Advertisement
Rick0

EXPORT_VPN

Jul 20th, 2020
586
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Batch 0.66 KB | None | 0 0
  1. @echo off
  2. setlocal EnableDelayedExpansion
  3. pushd "%~dp0"
  4. IF %PROCESSOR_ARCHITECTURE% EQU AMD64 (SET "VPN=%PROGRAMFILES(X86)%\Fortinet\FortiClient") ELSE (SET "VPN=%PROGRAMFILES%\Fortinet\FortiClient")
  5. SET "CONF=%VPN%\FCConfig.exe"
  6. SET "FCLI=%VPN%\Forticlient.exe"
  7. ::CAMINHO ARQUIVO EXPORTADO=PASTA ATUAL
  8. SET "FVPN=%~dp0CONFIGVPN"
  9. ::EXPORTANDO CONFIGURACAO VPN E SETANDO UMA SENHA
  10. ::REMOVENDO A OPCAO export -p "senhavpn45*" exporta a configuracao sem senha
  11. IF EXIST "%FCLI%" (start "" "%FCLI%")
  12. IF EXIST "%CONF%" ("%CONF%" -f "%FVPN%" -m all -o export -p "senhavpn45*" & tasklist | find /i "Forticlient.exe" && taskkill /im "Forticlient.exe" /F >nul &CLS)
  13. POPD
  14. EXIT
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement