Skip to Content.
Sympa Menu

grouper-users - RE: [grouper-users] grouperClient: error adding members when stem contains forward slash

Subject: Grouper Users - Open Discussion List

List archive

RE: [grouper-users] grouperClient: error adding members when stem contains forward slash


Chronological Thread 
  • From: Chris Hyzer <>
  • To: "" <>, Grouper Users Mailing List <>
  • Subject: RE: [grouper-users] grouperClient: error adding members when stem contains forward slash
  • Date: Fri, 3 Apr 2009 00:32:21 -0400
  • Accept-language: en-US
  • Acceptlanguage: en-US

Loris, this is fixed in the latest 1.4 branch, if you want to get latest and
try again:

https://bugs.internet2.edu/jira/browse/GRP-263

The rest web services were already unescaping (url unencoding) data in the
URL. However, grouper client was not encoding it. This affected three
client operations: addMember, deleteMember, and hasMember. These are all
fixed, and I add a test case.

This is not completely staightforward, since if you try to send a url encoded
slash to tomcat (not sure about other servlet containers), it rejects it with:

HTTP/1.1 400 Invalid URI: noSlash

However, if you start tomcat with this system param:

-Dorg.apache.tomcat.util.buf.UDecoder.ALLOW_ENCODED_SLASH=true

Then it works. See this:
http://www.archivum.info//2008-01/msg00977.html

Yes, this is added to my reasons of loving strict rest... :) since if data
is in url params or the http body, or in xml, it will be automatically
escaped, but if data in the URL has slashes or other chars, you need to
manually escape/unescape it and not forget.

btw, after 1.4.1 (early march) I fixed a client template issue, but somehow
the delete output template has the result printed as the overall result and
not the line item result. Not sure if it affected anyone, but it is now
switched back.

Regards,
Chris

> -----Original Message-----
> From: Chris Hyzer
> [mailto:]
> Sent: Tuesday, March 31, 2009 3:03 AM
> To:
> ;
> Grouper Users Mailing List
> Subject: RE: [grouper-users] grouperClient: error adding members when
> stem contains forward slash
>
> I wasn’t expecting that input... I opened a bug for it
>
> https://bugs.internet2.edu/jira/browse/GRP-263
>
> Sorry for inconvenience.
>
> Chris
>
> > -----Original Message-----
> > From: Loris Bennett
> > [mailto:]
> > Sent: Tuesday, March 31, 2009 2:41 AM
> > To: Grouper Users Mailing List
> > Subject: [grouper-users] grouperClient: error adding members when
> stem
> > contains forward slash
> >
> > Hi,
> >
> > I have been playing around with folders and groups with forward
> slashes
> > in their IDs. As far as I remember there used to be an issue with
> > LDAPPC
> > regarding this. However now I seems LDAPPC can cope, but I have
> problem
> > with grouperClient. I can add group with the ID
> >
> > group_with_a_/_in_its_id
> >
> > but when I try to add members to a group without forwards slashes,
> but
> > in a folder with forward slashes, I get an error
> >
> > java.lang.RuntimeException: java.lang.RuntimeException: Cant find
> > GrouperWsRestPutGroup from string: 'informatik', expecting one of:
> > members, ,
> > uri: /grouper-
> >
> ws/servicesRest/v1_4_000/groups/targets:fb_mathematik/informatik/physik
> > :test_group/members, method: POST, decoded url strings: 0:
> 'v1_4_000',
> > 1: 'groups', 2: 'targets:fb_mathematik', 3: 'informatik', 4:
> > 'physik:test_group', 5: 'members'
> >
> > Is there some way to escape the forwardslashes?
> >
> > Cheers
> >
> > Loris
> > --
> > Dr. Loris Bennett (Mr.)
> > Freie Universität Berlin
> > ZEDAT - Zentraleinrichtung für Datenverarbeitung / Computer Center
> > Compute & Media Service
> > Fabeckstr. 32, Room 221
> > D-14195 Berlin
> > Tel ++49 30 838 51024
> > Fax ++49 30 838 56721
> > Email
> >
> > Web www.zedat.fu-berlin.de



  • RE: [grouper-users] grouperClient: error adding members when stem contains forward slash, Chris Hyzer, 04/03/2009

Archive powered by MHonArc 2.6.16.

Top of Page