2018년 4월 19일 목요일

[links] PBKDF2, RSA-OAEP

PBKDF2

: https://en.wikipedia.org/wiki/PBKDF2

In cryptography, PBKDF1 and PBKDF2 (Password-Based Key Derivation Function 2) are key derivation functions with a sliding computational cost, aimed to reduce the vulnerability of encrypted keys to brute force attacks.

PBKDF2 applies a pseudorandom function, such as hash-based message authentication code (HMAC), to the input password or passphrase along with a salt value and repeats the process many times to produce a derived key, which can then be used as a cryptographic key in subsequent operations. The added computational work makes password cracking much more difficult, and is known as key stretching.


한글 설명과 그림으로 잘 설명하고 있는 글
: http://d2.naver.com/helloworld/318732

가장 많이 사용되는 key derivation function은 PBKDF2(Password-Based Key Derivation Function)이다. 해시 함수의 컨테이너인 PBKDF2는 솔트를 적용한 후 해시 함수의 반복 횟수를 임의로 선택할 수 있다. PBKDF2는 아주 가볍고 구현하기 쉬우며, SHA와 같이 검증된 해시 함수만을 사용한다.


출처 : 네이버 d2 게시물(링크참조)

PBKDF2의 기본 파라미터는 다음과 같은 5개 파라미터다.

DIGEST = PBKDF2(PRF, Password, Salt, c, DLen)
PRF: 난수(예: HMAC)
 : https://en.wikipedia.org/wiki/HMAC

Password: 패스워드
Salt: 암호학 솔트
c: 원하는 iteration 반복 수
DLen: 원하는 다이제스트 길이

위 네이버 d2 게시물(링크참조)


RSA-OAEP

https://en.wikipedia.org/wiki/Optimal_asymmetric_encryption_padding

In cryptography, Optimal Asymmetric Encryption Padding (OAEP) is a padding scheme often used together with RSA encryption. OAEP was introduced by Bellare and Rogaway, and subsequently standardized in PKCS#1 v2 and RFC 2437.

OAEP satisfies the following two goals:


  • Add an element of randomness which can be used to convert a deterministic encryption scheme (e.g., traditional RSA) into a probabilistic scheme.
  • Prevent partial decryption of ciphertexts (or other information leakage) by ensuring that an adversary cannot recover any portion of the plaintext without being able to invert the trapdoor one-way permutation.



: https://seed.kisa.or.kr/iwt/ko/intro/EgovPublicKey.do

RSA(Rivest, Shamir and Adleman)
RSA[25]는 공개키 암호 시스템으로 암호화와 인증에 사용된다. RSA는 일반 정수론적인 면에서 정의되었다. 이 시스템은 큰 수의 인수분해의 어려움에 안전성을 두고 있다. 전자 서명의 길이는 RSA 시스템에서의 키 길이와 같다. RSA 시스템을 깨는 문제가 인수분해 문제로 귀결된다는 완전한 수학적 증명의 부족과 인수분해 문제가 NP-hard임에도 불구하고, RSA는 수많은 국제기구의 표준일 뿐만 아니라 산업 표준으로 권장되고 있다.

ElGamal
이산 대수 문제의 어려움에 기반을 둔 최초의 공개키 암호 알고리즘인 ElGamal[26]은 1984년 스탠퍼드 대학의 암호 학자 T. ElGamal에 의해 제안되었다. ElGamal으로 암호화하면 메시지의 길이가 두 배로 늘어나는 특징이 있다. 하지만 암호화할 때 난수를 이용하므로 같은 메시지에 대해 암호화하여도 암호화할 때마다 서로 다른 암호문을 얻게 되는데, 이것은 정보보호 측면에서 큰 장점이 된다. RSA에서는 난수를 사용하지 않기 때문에 같은 메시지에 대한 암호문은 항상 같다는 특징이 있는데, 이것은 공격자가 암호문을 복호화하지 않고도 평문을 추측할 수 있는 단점이 된다. 그러므로 실제 적용 시 RSA는 난수를 사용하는 OAEP(Optimal Asymmetric Encryption Padding)이라는 난수화 패딩 알고리즘과 함께 사용된다.

댓글 없음:

댓글 쓰기