forked from thinkst/canarytokens
-
Notifications
You must be signed in to change notification settings - Fork 0
/
exception.py
36 lines (26 loc) · 936 Bytes
/
exception.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
class UnknownAttribute(Exception):
def __init__(self, attribute=None):
self.message = '{attribute} is unrecognized'.format(attribute=attribute)
class MissingAttribute(Exception):
def __init__(self, attribute=None):
self.message = '{attribute} is missing'.format(attribute=attribute)
class NoCanarytokenPresent(Exception):
def __init__(self, attribute=None):
self.message = '{attribute} is unrecognized'.format(attribute=attribute)
def __str__(self,):
return 'No Canarytoken present'
class NoCanarytokenFound(Exception):
def __init__(self, haystack):
self._haystack = haystack
def __str__(self,):
return 'No Canarytoken found in %s' % self._haystack
class DuplicateChannel(Exception):
pass
class InvalidChannel(Exception):
pass
class NoUser(Exception):
pass
class LinkedInFailure(Exception):
pass
class BitcoinFailure(Exception):
pass