private void addRoles(ILdapAttribute attr) {
                // Treat value as an RDN
                for (ILdapDn dn : attr.getValuesAsDn()) {
                    for (ILdapRdn rdns : dn.getRdns()) {
                        if (rdns.hasAttribute(config.getRolenameAttribute())) {
                            for (String value : rdns.getAttributeValues()) {
                                roles.add(value);
                            }
                        }
                    }
                }
            }
@see io.apiman.gateway.engine.policies.auth.IIdentityValidator#validate(java.lang.String, java.lang.String, io.apiman.gateway.engine.beans.ApiRequest, io.apiman.gateway.engine.policy.IPolicyContext, java.lang.Object, io.apiman.gateway.engine.async.IAsyncResultHandler)
gateway/engine/policies/src/main/java/io/apiman/gateway/engine/policies/auth/LDAPIdentityValidator.java