smb URL syntax brain teaser

Christopher R. Hertel crh at nts.umn.edu
Tue Mar 20 17:44:18 GMT 2001


> "Allen, Michael B (RSCH)" wrote:
> > ...
> > Right now my parser assumes the '@' sign cannot appear
> > in a filename or path. Anyone have an ingenious way
> > around this problem?
> 
> Follow the URL/URI RFC and require these special characters be
> encoded using the %XX notation...

Yep.  That's the way to do it.  Any URL-special characters that are part 
of the underlying information must be escaped and then decoded after the 
URL is parsed.

Mike:  I have C code that can do this at:
       http://www.ubiqx.org/libcifs/SMB/URI

One thing I noted from other sources is that the string %XZ, where X is a 
digit char but Z is *not* a hex digit, would be interpreted as %0X.  The 
string %ZZ is sometimes interpreted as %.

Chris -)-----

-- 
Christopher R. Hertel -)-----                   University of Minnesota
crh at nts.umn.edu              Networking and Telecommunications Services

    Ideals are like stars; you will not succeed in touching them
    with your hands...you choose them as your guides, and following
    them you will reach your destiny.  --Carl Schultz





More information about the samba-technical mailing list