728x90 반응형 보안기능6 보안약점 진단 #3 01 private static final boolean PRIVATE_STATIC_FINAL_TRUE = true; 02 private static final boolean PRIVATE_STATIC_FINAL_FALSE = false; 03 04 public void do(String password) throws Throwable { 05 if (password == null) { 06 return; 07 } 08 if (PRIVATE_STATIC_FINAL_TRUE) { 09 MessageDigest hash = MessageDigest.getInstance("SHA-512"); 10 byte[] hashValue = hash.digest(password.getBytes("UTF-8")); 11 .. 2020. 7. 12. 중요정보 평문전송 [안전하지 않은 코드] [안전한 코드] setMaxAge public void setMaxAge(int expiry) Sets the maximum age of the cookie in seconds. A positive value indicates that the cookie will expire after that many seconds have passed. Note that the value is the maximum age when the cookie will expire, not the cookie's current age. A negative value means that the cookie is not stored persistently and will be deleted when the .. 2019. 10. 1. 중요정보 평문저장 [안전하지 않은 코드] [안전한 코드] 2019. 10. 1. 중요한 자원에 대한 잘못된 권한 설정 [안전하지 않은 코드] [안전한 코드] 2019. 10. 1. 이전 1 2 다음 728x90 반응형