subdomains to pacdomain are not allowed
This commit is contained in:
parent
b82497d4fb
commit
9188fd5e42
@ -108,6 +108,9 @@ public class DomainModuleImpl extends AbstractModuleImpl {
|
||||
List<?> resultList = domainQuery.getResultList();
|
||||
if (resultList.size() > 0) {
|
||||
Domain superDom = (Domain) resultList.get(0);
|
||||
if (superDom.isPacDomain()) {
|
||||
throw new HSAdminException("subdomains to pacdomain " + superDom.getName() + " are not allowed");
|
||||
}
|
||||
if (loginUser.hasPacAdminRoleFor(superDom.getUser().getPac())) {
|
||||
break; // same pac
|
||||
}
|
||||
@ -118,7 +121,7 @@ public class DomainModuleImpl extends AbstractModuleImpl {
|
||||
if (dnsCheck.checkDomain(dom.getName())) {
|
||||
break;
|
||||
} else {
|
||||
throw new HSAdminException("domain " + dom.getName() + " is not delegated to " + dom.getDnsMaster());
|
||||
throw new AuthorisationException(loginUser, "add", dom);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user