From da78a9e329e272dedb2400b79a3bdeebff387d47 Mon Sep 17 00:00:00 2001 From: Peter Bengtsson Date: Tue, 8 Dec 2020 14:42:17 -0500 Subject: initial commit --- files/ko/web/api/crypto/getrandomvalues/index.html | 73 ++++++++++++++++++++++ files/ko/web/api/crypto/index.html | 35 +++++++++++ files/ko/web/api/crypto/subtle/index.html | 36 +++++++++++ 3 files changed, 144 insertions(+) create mode 100644 files/ko/web/api/crypto/getrandomvalues/index.html create mode 100644 files/ko/web/api/crypto/index.html create mode 100644 files/ko/web/api/crypto/subtle/index.html (limited to 'files/ko/web/api/crypto') diff --git a/files/ko/web/api/crypto/getrandomvalues/index.html b/files/ko/web/api/crypto/getrandomvalues/index.html new file mode 100644 index 0000000000..4bf373c855 --- /dev/null +++ b/files/ko/web/api/crypto/getrandomvalues/index.html @@ -0,0 +1,73 @@ +--- +title: Crypto.getRandomValues() +slug: Web/API/Crypto/getRandomValues +tags: + - API + - Cryptography + - Method + - Reference +translation_of: Web/API/Crypto/getRandomValues +--- +
{{APIRef("Web Crypto API")}}
+ +

Crypto.getRandomValues() 함수는 암호학적으로 강력한 수준의 임의의(random) 값을 생성합니다. 매개 변수로 제공된 배열은 임의의 숫자로 채워집니다 (암호화의 의미는 무작위입니다).

+ +

충분한 성능을 보장하기 위해 구현에서는 진정한 난수 생성기(pseudo-random number)를 사용하지 않지만 충분한 엔트로피가있는 값으로 시드 된 의사 난수 생성기를 사용하고 있습니다. 사용 된 유사난수 생성기(pseudorandom number generator, PRNG)는 구현마다 다르지만 암호화 용도에 적합합니다. 시스템 수준의 엔트로피 소스처럼 충분한 엔트로피가있는 시드를 사용하려면 구현이 필요합니다.

+ +

구문

+ +
cryptoObj.getRandomValues(typedArray);
+ +

매개변수

+ +
+
typedArray
+
Is an integer-based {{jsxref("TypedArray")}}, that is an {{jsxref("Int8Array")}}, a {{jsxref("Uint8Array")}}, an {{jsxref("Int16Array")}}, a {{jsxref("Uint16Array")}}, an {{jsxref("Int32Array")}}, or a {{jsxref("Uint32Array")}}. 배열의 모든 요소는 임의의 숫자로 재정의됩니다.
+
+ +

예외

+ + + +

예제

+ +
/* window.crypto.getRandomValues 를 사용가능하다고 가정한다. */
+
+var array = new Uint32Array(10);
+window.crypto.getRandomValues(array);
+
+console.log("나의 행운의 숫자들:");
+for (var i = 0; i < array.length; i++) {
+    console.log(array[i]);
+}
+
+ +

명세

+ + + + + + + + + + + + + + +
SpecificationStatusComment
{{SpecName('Web Crypto API', '#RandomSource-method-getRandomValues')}}{{Spec2('Web Crypto API')}}Initial definition
+ +

브라우저 호환성

+ +

{{Compat("api.Crypto.getRandomValues")}}

+ +

같이 보기

+ + diff --git a/files/ko/web/api/crypto/index.html b/files/ko/web/api/crypto/index.html new file mode 100644 index 0000000000..759b7c045d --- /dev/null +++ b/files/ko/web/api/crypto/index.html @@ -0,0 +1,35 @@ +--- +title: Crypto +slug: Web/API/Crypto +translation_of: Web/API/Crypto +--- +

{{APIRef("Web Crypto API")}}

+ +

Crypto 인터페이스는 현재 환경에서 사용 가능한 기본적인 암호화 기법을 제공합니다. 이 인터페이스를 통해 암호학적으로 강력한 무작위 숫자 생성기나 암호화에 필요한 기본 요소에 접근할 수 있습니다.

+ +

이 인터페이스 객체는 {{domxref("Window.crypto")}} 속성을 통해 웹에서 사용 가능합니다.

+ +

속성

+ +

이 인터페이스는 {{domxref("RandomSource")}}에 정의된 속성을 구현하고 있습니다.

+ +
+
{{domxref("Crypto.subtle")}} {{experimental_inline}}{{readOnlyInline}}
+
해싱, 서명, 암호화, 복호화같은 암호화 기법에 필요한 공통 요소들에 접근할 수 있는 객체를 반환.
+
+ +

메소드

+ +

이 인터페이스는 {{domxref("RandomSource")}}에 정의된 속성을 구현하고 있습니다.

+ +
+
{{ domxref("RandomSource.getRandomValues()") }}
+
넘겨받은 {{ jsxref("TypedArray") }}를 암호학적으로 무작위인 값으로 채움.
+
+

더보기

+ + +
+
diff --git a/files/ko/web/api/crypto/subtle/index.html b/files/ko/web/api/crypto/subtle/index.html new file mode 100644 index 0000000000..a3e0e6e40c --- /dev/null +++ b/files/ko/web/api/crypto/subtle/index.html @@ -0,0 +1,36 @@ +--- +title: Crypto.subtle +slug: Web/API/Crypto/subtle +translation_of: Web/API/Crypto/subtle +--- +
{{APIRef("Web Crypto API")}}
+ +

Crypto.subtle 은 읽기전용 속성이며 암호화 기법을 수행할 수 있는 {{domxref("SubtleCrypto")}} 객체를 반환합니다.

+ +

명세

+ + + + + + + + + + + + + + +
명세상태비고
{{ SpecName('Web Crypto API', '#dfn-Crypto', 'Crypto.subtle') }}{{ Spec2('Web Crypto API') }}Initial definition.
+ +

브라우저 호환성

+ +

{{Compat("api.Crypto.subtle")}}

+ +

같이 보기

+ + -- cgit v1.2.3-54-g00ecf