Hi all,
during a recent deployment, we ran into the problem of wanting
special subjects for the smartcard personalization. In our case,
they were supposed to look like:
CN=John W Doe (if an initial was present) or
CN=John Doe (if no initial was present)
Now, if one uses the standard replacement, one could write something
like
CN=%givenName% %initials% %sn%.
But of course you run into trouble when no initial is present, as you
get two spaces instead of one.
For the deployment, we solved this quick and dirty (replacing two spaces
by one), but we did not really like the solution.
This is why I just checked in code that allows you to use the whole
power of Template Toolkit within those expressions, which allows us
to rewrite the above to
CN=[% givenName %] [% IF initials != '' %][% initials %] [% END %][ % sn %].
Greetings,
Alex
--
Dipl.-Math. Alexander Klink | IT-Security Engineer
[EMAIL PROTECTED] | working @ urn:oid:1.3.6.1.4.1.11417
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
OpenXPKI-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openxpki-devel