MAJOR_VERSION=1
 MINOR_VERSION=1.5
 PATCH_VERSION=1.5.3
-VERSION=$(PATCH_VERSION)
 DEFVERSION=010503
+VERSION=$(PATCH_VERSION)
 
 /*  #define GACLprintCred(x,y) GRSTgaclCredPrint((x),(y)) */
 int        GRSTgaclCredCredPrint(GRSTgaclCred *, FILE *);
 
+int       GRSTgaclCredCmp(GRSTgaclCred *, GRSTgaclCred *);
 
 /*  #define GACLnewEntry(x)            GRSTgaclEntryNew((x)) */
 GRSTgaclEntry *GRSTgaclEntryNew(void);
 
                  $(prefix)/share/man/man8 \
                  $(prefix)/lib/httpd/modules \
                  $(prefix)/share/doc/gridsite-$(MINOR_VERSION)
-       echo "#define GRST_VERSION $DEFVERSION" > $(prefix)/include/gridsite.h
+       echo '#define' GRST_VERSION $(DEFVERSION) > $(prefix)/include/gridsite.h
        cat ../interface/gridsite.h >>$(prefix)/include/gridsite.h
        cp -f ../interface/gridsite-gacl.h $(prefix)/include
        cp -f urlencode $(prefix)/bin
 
       return 1;
     }
     
-  return 0;  
+  return 0;
+}
+
+int GRSTgaclCredCmp(GRSTgaclCred *cred1, GRSTgaclCred *cred2)
+/*
+    GRSTgaclCredCmp - compare two credentials for exact match in AURI values
+                      (this means a string match, not just any-user=DN etc)
+*/
+{
+  if ((cred1 == NULL) && (cred2 == NULL) return 0;
+  
+  if (cred1 == NULL) return -1;
+
+  if (cred2 == NULL) return 1;
+  
+  if ((cred1->auri == NULL) && (cred2->auri == NULL) return 0;
+  
+  if (cred1->auri == NULL) return -1;
+
+  if (cred2->auri == NULL) return 1;
+  
+  return strcmp(cred1->auri, cred2->auri);
 }
 
 /*                                              *