Ejemplo n.º 1
0
  def __init__(self, otherLogin = None, otherPassword = None):
    if otherLogin and otherPassword:
      self.login = otherLogin
      self.passw = otherPassword

    self.client = webdavlib.WebDAVClient(hostname, port)

    authCookie = sogoLogin.getAuthCookie(hostname, port, self.login, self.passw)
    self.cookie = authCookie

    # map between preferences/jsonDefaults and the webUI names
    # should probably be unified...
    self.preferencesMap = {
        "SOGoLanguage": "language",
        "SOGoTimeZone": "timezone",
        "SOGoSieveFilters": "sieveFilters",

        # Vacation stuff
        "Vacation": "enableVacation", # to disable, don't specify it
        "autoReplyText": "autoReplyText", # string
        "autoReplyEmailAddresses":  "autoReplyEmailAddresses", # LIST
        "daysBetweenResponse":  "daysBetweenResponsesList", 
        "ignoreLists":  "ignoreLists", #bool

        # forward stuff
        "Forward": "enableForward", # to disable, don't specify it
        "forwardAddress": "forwardAddress",
        "keepCopy": "forwardKeepCopy",

        # Calendar stuff
        "enablePreventInvitations": "preventInvitations",
        "PreventInvitations": "PreventInvitations",
        "whiteList": "whiteList",
    }
Ejemplo n.º 2
0
    def __init__(self, otherLogin=None, otherPassword=None):
        if otherLogin and otherPassword:
            self.login = otherLogin
            self.passw = otherPassword

        self.client = webdavlib.WebDAVClient(hostname, port)

        authCookie = sogoLogin.getAuthCookie(hostname, port, username,
                                             password)
        self.cookie = authCookie

        # map between preferences/jsonDefaults and the webUI names
        # should probably be unified...
        self.preferencesMap = {
            "SOGoLanguage": "language",
            "SOGoTimeZone": "timezone",
            "SOGoSieveFilters": "sieveFilters",

            # Vacation stuff
            "Vacation": "enableVacation",  # to disable, don't specify it
            "autoReplyText": "autoReplyText",  # string
            "autoReplyEmailAddresses": "autoReplyEmailAddresses",  # LIST
            "daysBetweenResponse": "daysBetweenResponsesList",
            "ignoreLists": "ignoreLists",  #bool

            # forward stuff
            "Forward": "enableForward",  # to disable, don't specify it
            "forwardAddress": "forwardAddress",
            "keepCopy": "forwardKeepCopy",
        }
Ejemplo n.º 3
0
    def __init__(self, otherLogin = None, otherPassword = None):
        if otherLogin and otherPassword:
            self.login = otherLogin
            self.passw = otherPassword

        self.client = webdavlib.WebDAVClient(hostname, port)

        authCookie = sogoLogin.getAuthCookie(hostname, port, self.login, self.passw)
        self.cookie = authCookie

        #- If this is not set, we CAN'T save preferences
        self.preferences = None
Ejemplo n.º 4
0
 def setUp(self):
     self.client = webdavlib.WebDAVClient(hostname, port)
     self.gcClient = webdavlib.WebDAVClient(hostname, port)
     self.cookie = sogoLogin.getAuthCookie(hostname, port, username,
                                           password)
Ejemplo n.º 5
0
 def setUp(self):
   self.client = webdavlib.WebDAVClient(hostname, port)
   self.gcClient = webdavlib.WebDAVClient(hostname, port)
   self.cookie = sogoLogin.getAuthCookie(hostname, port, username, password)