Posts

Add and enable/disable Windows Firewall rules with Python

Image
0 I have this following module using for adding and enabling/disabling Windows Firewall rules using Python. I currently use subprocess.call to execute the netsh command inside Python. I'm wondering if there is any better method to do this? Executing the cmd command inside Python seems to be impractical to me. import subprocess, ctypes, os, sys from subprocess import Popen, DEVNULL def chkAdmin(): """ Force to start application with admin rights """ try: isAdmin = ctypes.windll.shell32.IsUserAnAdmin() except AttributeError: isAdmin = False if not isAdmin: ctypes.windll.shell32.ShellExecuteW(None, "runas", sys.executable, __file__, None, 1) def addRule(rule_name, file_path): """ Add rule to Windows Fir...

Placówka Straży Celnej „Łączki”

Image
.mw-parser-output table.zolnierz-lotnictwo td.naglowek{color:black!important;background:#95a7b9!important}.mw-parser-output table.zolnierz-marynarka td.naglowek{color:white!important;background:#6082B6!important}.mw-parser-output table.zolnierz-lądowe td.naglowek{color:white!important;background:#556B2F!important}.mw-parser-output table.zolnierz-paramilitarny td.naglowek{color:black!important;background:#b6b3c7!important} Placówka SC „Łączki” Historia Państwo   II Rzeczpospolita Organizacja Dyslokacja Łączki Formacja Straż Celna Podległość Komisariat SC „Leman” Rozmieszczenie placówek SC komisariatu "Leman" w 1926 roku Placówka Straży Celnej „Łączki” – jednostka organizacyjna Straży Celnej pełniąca w okresie międzywojennym służbę ochronną na granicy polsko-niemieckiej. Spis treści 1 Formowanie i zmiany organizacyjne 2 Służba graniczna 3 Funkcjonariusze placówki 4 Uwagi 5 Przypisy 6 Bibliografia ...