lib/gettor/utils.py
def addWhitelistEntry(conf, address):
    """Add an entry to the global whitelist
    """
    wlStateDir = conf.BASEDIR + "/wl"
    logging.debug("Adding address to whitelist: %s" % address)
    try:
        whiteList = gettor.blacklist.BWList(wlStateDir)
    except IOError, e:
        logging.error("Whitelist error: %s" % e)
        return False
    if not whiteList.createListEntry(normalizeAddress(address), "general"):
        logging.error("Creating whitelist entry failed.")
        return False
    else:
        logging.debug("Creating whitelist entry ok.")
        return True
Add an entry to the global whitelist
    
Add an entry to the global whitelist
Add an entry to the global whitelist
def addWhitelistEntry(conf, address):
    wlStateDir = conf.BASEDIR + "/wl"
    logging.debug("Adding address to whitelist: %s" % address)
    try:
        whiteList = gettor.blacklist.BWList(wlStateDir)
    except IOError, e:
        logging.error("Whitelist error: %s" % e)
        return False
    if not whiteList.createListEntry(normalizeAddress(address), "general"):
        logging.error("Creating whitelist entry failed.")
        return False
    else:
        logging.debug("Creating whitelist entry ok.")
        return True
def addWhitelistEntry ( conf , address ) : wlStateDir = conf . BASEDIR + "/wl" logging . debug ( "Adding address to whitelist: %s" % address ) try : whiteList = gettor . blacklist . BWList ( wlStateDir ) except IOError , e : logging . error ( "Whitelist error: %s" % e ) return False if not whiteList . createListEntry ( normalizeAddress ( address ) , "general" ) : logging . error ( "Creating whitelist entry failed." ) return False else : logging . debug ( "Creating whitelist entry ok." ) return True
Add an entry to the global whitelist
Add an entry to the global whitelist
"""Add an entry to the global whitelist
    """
conf
address