diff --git a/cadc-access-control-server/build.gradle b/cadc-access-control-server/build.gradle index c8bc364c..1fa08618 100644 --- a/cadc-access-control-server/build.gradle +++ b/cadc-access-control-server/build.gradle @@ -13,7 +13,7 @@ sourceCompatibility = 1.8 group = 'org.opencadc' -version = '1.3.33' +version = '1.3.35' description = 'OpenCADC User+Group server library' def git_url = 'https://github.com/opencadc/ac' diff --git a/cadc-access-control-server/src/main/java/ca/nrc/cadc/ac/server/ldap/LdapGroupDAO.java b/cadc-access-control-server/src/main/java/ca/nrc/cadc/ac/server/ldap/LdapGroupDAO.java index 0d303630..9dbdc53e 100755 --- a/cadc-access-control-server/src/main/java/ca/nrc/cadc/ac/server/ldap/LdapGroupDAO.java +++ b/cadc-access-control-server/src/main/java/ca/nrc/cadc/ac/server/ldap/LdapGroupDAO.java @@ -3,7 +3,7 @@ ******************* CANADIAN ASTRONOMY DATA CENTRE ******************* ************** CENTRE CANADIEN DE DONNÉES ASTRONOMIQUES ************** * - * (c) 2019. (c) 2019. + * (c) 2023. (c) 2023. * Government of Canada Gouvernement du Canada * National Research Council Conseil national de recherches * Ottawa, Canada, K1A 0R6 Ottawa, Canada, K1A 0R6 @@ -473,8 +473,12 @@ public void searchEntryReturned(SearchResultEntry sre) String gname = sre.getAttributeValue(LDAP_CN); String gidstr = sre.getAttributeValue(LDAP_GID_NUMBER); Integer gid = Integer.valueOf(gidstr); - PosixGroup pg = new PosixGroup(gid, new GroupURI(gmsResourceID, gname)); - ret.add(pg); + try { + PosixGroup pg = new PosixGroup(gid, new GroupURI(gmsResourceID, gname)); + ret.add(pg); + } catch (IllegalArgumentException ex) { + logger.warn("invalid group name: " + gname + " -- SKIP"); + } long t2 = System.currentTimeMillis(); long dt = t2 - t1;