~certify-web-dev/twisted/certify-trunk

« back to all changes in this revision

Viewing changes to twisted/conch/error.py

  • Committer: Bazaar Package Importer
  • Author(s): Matthias Klose
  • Date: 2007-01-17 14:52:35 UTC
  • mfrom: (1.1.5 upstream) (2.1.2 etch)
  • Revision ID: james.westby@ubuntu.com-20070117145235-btmig6qfmqfen0om
Tags: 2.5.0-0ubuntu1
New upstream version, compatible with python2.5.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
# Copyright (c) 2001-2004 Twisted Matrix Laboratories.
 
2
# See LICENSE for details.
 
3
 
 
4
#
 
5
# Paul, why didn't you check in an error.py?
 
6
 
 
7
"""An error to represent bad things happening in Conch.
 
8
 
 
9
This module is unstable.
 
10
 
 
11
Maintainer: U{Paul Swartz<mailto:z3p@twistedmatrix.com>}
 
12
"""
 
13
 
 
14
class ConchError(Exception):
 
15
    def __init__(self, value, data = None):
 
16
        Exception.__init__(self, value, data)
 
17
        self.value = value
 
18
        self.data = data
 
19
 
 
20
class NotEnoughAuthentication(Exception):
 
21
    """This is thrown if the authentication is valid, but is not enough to
 
22
    successfully verify the user.  i.e. don't retry this type of
 
23
    authentication, try another one.
 
24
    """
 
25
 
 
26
class ValidPublicKey(Exception):
 
27
    """This is thrown during the authentication process if the public key
 
28
    is valid for the user.
 
29
    """
 
30
 
 
31
class IgnoreAuthentication(Exception):
 
32
    """This is thrown to let the UserAuthServer know it doesn't need to handle
 
33
    the authentication anymore.
 
34
    """