For Programmers: Free Programming Magazines  


Home > Archive > PERL Miscellaneous > March 2008 > Re: Parse x.500 DN and change order displayed









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Re: Parse x.500 DN and change order displayed
SecureIT

2008-03-31, 9:09 pm

On Mar 31, 8:26=A0am, Hallvard B Furuseth <h.b.furus...@usit.uio.no>
wrote:
> SecureIT writes:
>
> Without escape sequences like "\," and "\+" in the DNs (if that's
> allowed anyway, I don't remember the details of X.500 Dn syntax), this
> moves serialNumber first in each RDN:
>
> s/(^|,)([^,]*)\+(serialNumber=3D[^+,]*)(?=3D[+,])/$1$3+$2/gi;
> die "didn't catch all 'foo+serialNumber's" if /\+serialNumber=3D/i;
>
> --
> Hallvard


That worked great, thanks so much. Just ran it and all 2000 DN's are
properly formatted now.

-G
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com