summaryrefslogtreecommitdiffstats
path: root/ipalib/plugins/f_service.py
diff options
context:
space:
mode:
authorRob Crittenden <rcritten@redhat.com>2009-01-28 21:47:21 -0700
committerRob Crittenden <rcritten@redhat.com>2009-02-03 15:29:04 -0500
commit5717c9d6689f15c46801f2d251e174fad4ce4748 (patch)
tree31e2a3378638bd63005a3d65d7fe74159860456c /ipalib/plugins/f_service.py
parent48a278047db50f919a45ef82a57a6983804ed523 (diff)
downloadfreeipa-5717c9d6689f15c46801f2d251e174fad4ce4748.tar.gz
freeipa-5717c9d6689f15c46801f2d251e174fad4ce4748.tar.xz
freeipa-5717c9d6689f15c46801f2d251e174fad4ce4748.zip
Applied Rob's errors patch
Diffstat (limited to 'ipalib/plugins/f_service.py')
-rw-r--r--ipalib/plugins/f_service.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/ipalib/plugins/f_service.py b/ipalib/plugins/f_service.py
index 06d6a5d08..99446b598 100644
--- a/ipalib/plugins/f_service.py
+++ b/ipalib/plugins/f_service.py
@@ -22,7 +22,7 @@
Frontend plugins for service (Identity).
"""
-from ipalib import api, crud, errors
+from ipalib import api, crud, errors2
from ipalib import Object # Plugin base classes
from ipalib import Str, Flag # Parameter types
@@ -72,11 +72,11 @@ class service_add(crud.Add):
# may not include the realm.
sp = principal.split('/')
if len(sp) != 2:
- raise errors.MalformedServicePrincipal
+ raise errors2.MalformedServicePrincipal
service = sp[0]
if service.lower() == "host":
- raise errors.HostService
+ raise errors2.HostService
sr = sp[1].split('@')
if len(sr) == 1:
@@ -86,7 +86,7 @@ class service_add(crud.Add):
hostname = sr[0].lower()
realm = sr[1]
else:
- raise MalformedServicePrincipal
+ raise errors2.MalformedServicePrincipal
"""
FIXME once DNS client is done
@@ -102,7 +102,7 @@ class service_add(crud.Add):
# At some point we'll support multiple realms
if (realm != self.api.env.realm):
- raise errors.RealmMismatch
+ raise errors2.RealmMismatch
# Put the principal back together again
princ_name = service + "/" + hostname + "@" + realm