Détails du package

smp-add-rules-block-firewall

retour Revenir à la liste des packages

smp-add-rules-block-firewall

Fichier control :

package           : smp-add-rules-block-firewall
version           : 2
architecture      : all
section           : base
priority          : standard
name              : 
categories        : 
maintainer        : Simon Fonteneau
description       : Bloque les ports 135,139,445,5357
depends           : 
conflicts         : 
maturity          : 
locale            : 
target_os         : windows
min_os_version    : 
max_os_version    : 
min_wapt_version  : 
sources           : 
installed_size    : 
impacted_process  : 
description_fr    : 
description_pl    : 
description_de    : 
description_es    : 
description_pt    : 
description_it    : 
description_nl    : 
description_ru    : 
audit_schedule    : 
editor            : 
keywords          : 
licence           : 
homepage          : 
package_uuid      : 6b6cfdaa-b5af-4cec-94cd-0665de1294cf
valid_from        : 
valid_until       : 
forced_install_on : 
changelog         : 
signer            : wapt.lesfourmisduweb.org
signer_fingerprint: 1e54425be03a2a3ea1a264b40d984c31f17a6a489a3b722acb993cbf6561e903
signature         : GIclLEVbqKcJtWIANXxLUYoAL2El9dbhXQHStvxXpHsBeXIoHbhnwT+FljK6gpaHwzBARbpykEJksWD5aSqrb2n8+u5cyXcQpn9Vj4KhJWDVr0yHX5M3V0aVnJvWcGYka6ryiEVqeSKcXoMdKybc489cpKVOZPLlQKNlc4hFRO2fdKr10uJOVsQFVrplVOA8o1zGlXoKQ6hB/477e7/hY5zJ57Zhy7LEFWpqExMzn4AzScEOz/+6WdR65BCUAt7B59IQplc2WT3NcSA4wu6BR9H/VQUOXaOAcJqoJoxdJZrUEa0TivC9mnwapOQXf+ipEzNI2WdssD9UGvHvrJnWsw==
signature_date    : 2020-07-04T01:17:49.915341
signed_attributes : package,version,architecture,section,priority,name,categories,maintainer,description,depends,conflicts,maturity,locale,target_os,min_os_version,max_os_version,min_wapt_version,sources,installed_size,impacted_process,description_fr,description_pl,description_de,description_es,description_pt,description_it,description_nl,description_ru,audit_schedule,editor,keywords,licence,homepage,package_uuid,valid_from,valid_until,forced_install_on,changelog,signer,signer_fingerprint,signature_date,signed_attributes






Fichier setup.py :

# -*- coding: utf-8 -*-
from setuphelpers import *

uninstallkey = []
listport=['135','139','445','5357']

def install():
    if windows_version() > Version('5.2'):
        for port in listport:
            print ('ADD FIREWALL RULES BLOCK PORT ' + port)
            run_notfatal('netsh advfirewall firewall delete rule "block_%s"' % port)
            run('netsh advfirewall firewall add rule name=block_%s action=block localport=%s protocol=tcp dir=in' %(port,port))

def uninstall():
    if windows_version() > Version('5.2'):
        for port in listport:
            run('netsh advfirewall firewall delete rule "block_%s"' % port)