| 양쪽 이전 판
이전 판
다음 판
|
이전 판
|
wiki:miscellaneous:base64 [2022/05/12 07:59] emblim98 |
wiki:miscellaneous:base64 [2023/01/13 18:44] (현재) |
| } | } |
| </code> | </code> |
| \\ | |
| ==== 3.2 문제 ==== | |
| Crypto-unescapeHtml에서 Decrypt Text 실행 시 에러 발생\\ | |
| \\ | |
| Decrypt Text 버튼 클릭 전\\ | |
| {{:wiki:miscellaneous:decode-unescapehtml01.png?600|}}\\ | |
| \\ | |
| Decrypt Text 버튼 클릭 후\\ | |
| {{:wiki:miscellaneous:decode-unescapehtml02.png?600|}}\\ | |
| \\ | |
| 결과값이 출력되면서 동시에 input Text란에 입력했던 값이 ''**%%<p>MyName</p>%%**'' → ''**%%&lt;p&gt;MyName&lt;/p&gt;%%**''으로 변경됨.\\ | |
| \\ | \\ |
| |
| === 3.2.1 - 코드 === | |
| \\ | |
| 코드 수정 전\\ | |
| |
| <code java> | |
| <!-- Input Encrypted ID or Password field --> | |
| <label for="decryptInptText" class="decryptInptTtl">Input Text</label> | |
| <input id="decryptInptText" class="decryptInptFld" name="decryptInptFld" type="text" placeholder="암호화된 ID 또는 Password를 입력하세요" value="<c:out value="${inputParam.decryptInptFld}" />"/> | |
| </code> | |
| \\ | |
| |
| 코드 수정 후\\ | |
| <code java> | |
| <!-- Input Encrypted ID or Password field --> | |
| <label for="decryptInptText" class="decryptInptTtl">Input Text</label> | |
| <input id="decryptInptText" class="decryptInptFld" name="decryptInptFld" type="text" placeholder="암호화된 ID 또는 Password를 입력하세요" value="<c:out value="${inputParam.decryptInptFld}" escapeXml="false"/>"/> | |
| </code> | |
| \\ | |
| 코드 수정 후 Decrypt Text 버튼 클릭 후의 캡쳐\\ | |
| {{:wiki:miscellaneous:decode-unescapehtml03.png?600|}}\\ | |
| \\ | |
| 결과값이 출력되면서 동시에 input Text란에 입력했던 값 ''**%%<p>MyName</p>%%**''이 변하지 않고 그대로 표시됨을 확인.\\ | |
| \\ | |
| === Ref Link === | |
| [[https://needjarvis.tistory.com/51|[JSTL] Tag가 jsp화면에 그대로 노출될 경우, escapeXml]]\\ | |
| [[https://docs.oracle.com/javaee/5/jstl/1.1/docs/tlddocs/c/out.html|JSTL Core - Tag out]]\\ | |
| \\ | |
| JSTL Core - Tag out에서 ''**%%escapeXml%%**''에 대한 설명은 아래와 같습니다.\\ | |
| |
| >>Determines whether characters <,>,&,'," in the resulting string should be converted to their corresponding character entity codes. Default value is true. | |
| >> 결과 문자열의 문자 ''**%%<%%**'', ''**%%>%%**'', ''**%%&%%**'', ''**%%'%%**'', ''**%%"%%**''를 해당 문자 엔티티 코드로 변환해야 하는지 여부를 결정합니다. 기본값은 true입니다.\\ | |
| |
| |
| |
| {{tag> 오션, base64}} | {{tag> 오션, base64}} |