tis-active-directory-picture

1-5
adds support for active directory pictures
0 downloads
Download
View on luti logo
tis-active-directory-picture icon

  Description 

  • package : tis-active-directory-picture
  • version : 1-5
  • architecture : x64
  • categories :
  • maintainer : administrator
  • description : adds support for active directory pictures
  • locale :
  • target_os : windows
  • min_wapt_version :
  • sources :
  • installed_size :
  • impacted_process :
  • description_fr :
  • description_pl :
  • description_de :
  • description_es :
  • description_pt :
  • description_it :
  • description_nl :
  • description_ru :
  • editor :
  • licence :
  • signature_date : 2022-06-21T16:05:12.373841
  • Depends :

  Setup.py 

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

def install():

    filecopyto('AdExt.dll',r'C:\Windows\Microsoft.NET\Framework64\AdExt.dll')
    for e in glob.glob(r'C:\Windows\Microsoft.NET\Framework64\*\InstallUtil.exe'):
        run(e + " C:\Windows\Microsoft.NET\Framework64\AdExt.dll")


def uninstall():

    for e in glob.glob(r'C:\Windows\Microsoft.NET\Framework64\*\InstallUtil.exe'):
        try:
            run(e + r' /u C:\Windows\Microsoft.NET\Framework64\AdExt.dll')
        except:
            pass

def audit():
    if not isfile(r'C:\Windows\Microsoft.NET\Framework64\AdExt.dll'):
        print('File AdExt.dll not found')
        return "ERROR"
    else:
        return "OK"

def update_package():
    # Declaring local variables
    result = False
    proxies = get_proxies()
    if not proxies:
        proxies = get_proxies_from_wapt_console()

    wget(r'https://github.com/ScribbleGhost/AdExt.dll/raw/master/AdExt.dll','AdExt.dll',proxies=proxies)

def get_proxies():
    r"""Return system proxy with the urllib python library

    >>> get_proxies()
    {'http': 'http://srvproxy.ad.domain.lan:8080',
    'https': 'http://srvproxy.ad.domain.lan:8080'}

    """
    if platform.python_version_tuple()[0] == "3":
        from urllib.request import getproxies
    else:
        from urllib import getproxies
    return getproxies()


def get_proxies_from_wapt_console():
    r"""Return proxy information from the current user WAPT console

    >>> get_proxies_from_wapt_console()
    {'http': 'http://srvproxy.ad.domain.lan:8080',
    'https': 'http://srvproxy.ad.domain.lan:8080'}

    """
    proxies = {}
    if platform.system() == "Windows":
        waptconsole_ini_path = makepath(user_local_appdata(), "waptconsole", "waptconsole.ini")
    else:
        waptconsole_ini_path = makepath(user_home_directory(), ".config", "waptconsole", "waptconsole.ini")
    if isfile(waptconsole_ini_path):
        proxy_wapt = inifile_readstring(waptconsole_ini_path, "global", "http_proxy")
        if proxy_wapt:
            proxies = {"http": proxy_wapt, "https": proxy_wapt}
    return proxies
										

  Changelog 



No changelog.txt.
									
  manifest.sha256