fedletEncode.jsp revision 8589dad18873c72c72a41284cf70a88eb0c56f79
34b317241b7401a4b0a90472e73d769d64d69a2aChristian Maeder DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
9c5b1136299d9052e4e995614a3a36a051a2682fChristian Maeder Copyright (c) 2009 Sun Microsystems, Inc. All Rights Reserved.
c18e9c3c6d5039618f1f2c05526ece84c7794ea3Christian Maeder The contents of this file are subject to the terms
34b317241b7401a4b0a90472e73d769d64d69a2aChristian Maeder of the Common Development and Distribution License
48c4688439e0aade4faeebf25ca8b16d661e47afChristian Maeder (the License). You may not use this file except in
34b317241b7401a4b0a90472e73d769d64d69a2aChristian Maeder compliance with the License.
48c4688439e0aade4faeebf25ca8b16d661e47afChristian Maeder You can obtain a copy of the License at
34b317241b7401a4b0a90472e73d769d64d69a2aChristian Maeder https://opensso.dev.java.net/public/CDDLv1.0.html or
cf30d3de6f9d875af714651287352b46a66f376dChristian Maeder See the License for the specific language governing
699511266869036921be9c7ae6ac83d1b66ba51dChristian Maeder permission and limitations under the License.
7dec34aee2b609b9535c48d060e0f7baf3536457Christian Maeder When distributing Covered Code, include this CDDL
34b317241b7401a4b0a90472e73d769d64d69a2aChristian Maeder Header Notice in each file and include the License file
48c4688439e0aade4faeebf25ca8b16d661e47afChristian Maeder If applicable, add the following below the CDDL Header,
34b317241b7401a4b0a90472e73d769d64d69a2aChristian Maeder with the fields enclosed by brackets [] replaced by
48c4688439e0aade4faeebf25ca8b16d661e47afChristian Maeder your own identifying information:
48c4688439e0aade4faeebf25ca8b16d661e47afChristian Maeder "Portions Copyrighted [year] [name of copyright owner]"
48c4688439e0aade4faeebf25ca8b16d661e47afChristian Maeder $Id: fedletEncode.jsp,v 1.1 2009/11/12 17:30:30 exu Exp $
48c4688439e0aade4faeebf25ca8b16d661e47afChristian Maeder Portions Copyrighted 2016 ForgeRock AS.
34b317241b7401a4b0a90472e73d769d64d69a2aChristian Maeder<%@page contentType="text/html; charset=UTF-8" %>
645b0104b011ed77fd0173c156cadc98324f336aChristian Maeder <title>Fedlet Encode</title>
c18e9c3c6d5039618f1f2c05526ece84c7794ea3Christian Maeder <link rel="stylesheet" type="text/css" href="com_sun_web_ui/css/css_ns6up.css" />
c18e9c3c6d5039618f1f2c05526ece84c7794ea3Christian Maeder <link rel="shortcut icon" href="com_sun_web_ui/images/favicon/favicon.ico" type="image/x-icon" />
715ffaf874309df081d1e1cd8e05073fc1227729Christian Maeder<%@page import="com.iplanet.services.util.Crypt,
715ffaf874309df081d1e1cd8e05073fc1227729Christian Maeder<%@page import="com.sun.identity.security.EncodeAction,
715ffaf874309df081d1e1cd8e05073fc1227729Christian Maeder<body class="DefBdy">
715ffaf874309df081d1e1cd8e05073fc1227729Christian Maeder <div class="SkpMedGry1"><a href="#SkipAnchor3860"><img src="com_sun_web_ui/images/other/dot.gif" alt="Jump to End of Masthead" border="0" height="1" width="1" /></a></div><div class="MstDiv">
715ffaf874309df081d1e1cd8e05073fc1227729Christian Maeder <table class="MstTblBot" title="" border="0" cellpadding="0" cellspacing="0" width="100%">
715ffaf874309df081d1e1cd8e05073fc1227729Christian Maeder <td class="MstTdTtl" width="99%">
715ffaf874309df081d1e1cd8e05073fc1227729Christian Maeder <div class="MstDivTtl"><img name="AMConfig.configurator.ProdName" src="console/images/PrimaryProductName.png" alt="OpenAM" border="0" /></div>
715ffaf874309df081d1e1cd8e05073fc1227729Christian Maeder <td class="MstTdLogo" width="1%"><img name="AMConfig.configurator.BrandLogo" src="com_sun_web_ui/images/other/javalogo.gif" alt="Java(TM) Logo" border="0" height="55" width="31" /></td>
715ffaf874309df081d1e1cd8e05073fc1227729Christian Maeder <table class="MstTblEnd" border="0" cellpadding="0" cellspacing="0" width="100%"><tr><td><img name="RMRealm.mhCommon.EndorserLogo" src="com_sun_web_ui/images/masthead/masthead-sunname.gif" alt="Sun(TM) Microsystems, Inc." align="right" border="0" height="10" width="108" /></td></tr></table>
715ffaf874309df081d1e1cd8e05073fc1227729Christian Maeder <table class="SkpMedGry1" border="0" cellpadding="5" cellspacing="0" width="100%"><tr><td><img src="com_sun_web_ui/images/other/dot.gif" alt="Jump to End of Masthead" border="0" height="1" width="1" /></a></td></tr></table>
715ffaf874309df081d1e1cd8e05073fc1227729Christian Maeder <table border="0" cellpadding="10" cellspacing="0" width="100%"><tr><td></td></tr></table>
715ffaf874309df081d1e1cd8e05073fc1227729Christian Maeder <table border="0" cellpadding="10" cellspacing="0" width="100%"><tr><td>
2986838ec286d67e7c199e7ea81e7364ca36ad25Christian Maeder ResourceBundle rb = null;
b05f8aa9196e5ae50805066953ff0180abc5036cChristian Maeder rb = ResourceBundle.getBundle("libSAML2",request.getLocale());
b05f8aa9196e5ae50805066953ff0180abc5036cChristian Maeder if (rb == null) {
bf089e1d4db3bf389ac1a352f4242e82c8f2b3c2Christian Maeder String strPwd = request.getParameter("password");
b05f8aa9196e5ae50805066953ff0180abc5036cChristian Maeder if ((strPwd != null) && (strPwd.trim().length() > 0)) {
b05f8aa9196e5ae50805066953ff0180abc5036cChristian Maeder out.println(rb.getString("result-encoded-pwd") + " ");
5214cf3742dc626a7efc5ec851db09bf0ff1f579Christian Maeder out.println((String) AccessController.doPrivileged(
48c4688439e0aade4faeebf25ca8b16d661e47afChristian Maeder new EncodeAction(strPwd.trim())));
48c4688439e0aade4faeebf25ca8b16d661e47afChristian Maeder out.println("<br /><br /><a href=\"fedletEncode.jsp\">" +
48c4688439e0aade4faeebf25ca8b16d661e47afChristian Maeder rb.getString("encode-another-pwd") + "</a>");
48c4688439e0aade4faeebf25ca8b16d661e47afChristian Maeder "<form name=\"frm\" action=\"fedletEncode.jsp\" method=\"post\">");
41859342472c9349707a4bbd7a05340c639013c0Christian Maeder out.println("<input type=\"text\" name=\"password\" />");
2986838ec286d67e7c199e7ea81e7364ca36ad25Christian Maeder out.println("<input type=\"submit\" value=\"" +
41859342472c9349707a4bbd7a05340c639013c0Christian Maeder rb.getString("btn-encode") + "\" />");
41859342472c9349707a4bbd7a05340c639013c0Christian Maeder } catch (Exception e) {
2986838ec286d67e7c199e7ea81e7364ca36ad25Christian Maeder out.println(rb.getString("failed-to-encode"));
5214cf3742dc626a7efc5ec851db09bf0ff1f579Christian Maeder</td></tr></table>
5214cf3742dc626a7efc5ec851db09bf0ff1f579Christian Maeder</body></html>