sachinw Posted October 1, 2009 Share Posted October 1, 2009 Hi,Can someone please help me to encode string in XSL.You can also suggest me any pointers on the same.I searched on net but dint get concrete way to encode string.Actually I want to generate password at XSLT level.The input xml has password element which will hold password in string, after applying XSLT it will encode that string and will send it for further processing.Thanks,Sachin. Link to comment Share on other sites More sharing options...
Martin Honnen Posted October 1, 2009 Share Posted October 1, 2009 I am afraid "encode string" is not a very precise description of what you want to achieve. XPath 2.0 has a function encode-for-URI. Whether that is the kind of encoding you want I doubt but you haven't told us any details. Link to comment Share on other sites More sharing options...
sachinw Posted October 5, 2009 Author Share Posted October 5, 2009 Hi Martin,Thanks for your reply.The requirement is I want to encrypt the string (plain text password) using XSLT and then will decrypt it at server.So if my password is - abcusing XSLT, I want to encrypt it as - @fdf34%# (using some key)and on server, I will decrypt above encrypted string to - abcPlease let me know if it possible. I am afraid "encode string" is not a very precise description of what you want to achieve. XPath 2.0 has a function encode-for-URI. Whether that is the kind of encoding you want I doubt but you haven't told us any details. Link to comment Share on other sites More sharing options...
Martin Honnen Posted October 5, 2009 Share Posted October 5, 2009 XSLT has no functions built in to encrypt and decrypt strings therefore I don't think using XSLT for that is a good choice. I would be tempted to use a different language or at least delegate that task to an extension function. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.