@PreAuthorize("hasRole('POLICY_READ')")
@RequestMapping(method = RequestMethod.GET, value = "/password/global/read")
public PasswordPolicyTO getGlobalPasswordPolicy() {
LOG.debug("Reading global password policy");
PasswordPolicy policy = policyDAO.getGlobalPasswordPolicy();
if (policy == null) {
throw new NotFoundException("No password policy found");
}
auditManager.audit(Category.policy, PolicySubCategory.read, Result.success,
"Successfully read global password policy: " + policy.getId());
return (PasswordPolicyTO) binder.getPolicyTO(policy);
}