Created
August 9, 2011 11:55
-
-
Save koichik/1133842 to your computer and use it in GitHub Desktop.
Revisions
-
koichik revised this gist
Aug 10, 2011 . 1 changed file with 2 additions and 2 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,7 +1,7 @@ ### tls.CleartextStream This is a stream on top of the *Encrypted* stream. This makes it possible to read/write an encrypted data as a cleartext data. This instance implements a duplex Stream interfaces. It has all the common stream methods and events. @@ -40,4 +40,4 @@ Example: valid_to: 'Nov 6 09:52:22 2029 GMT', fingerprint: '2A:7A:C2:DD:E5:F9:CC:53:72:35:99:7A:02:5A:71:38:52:EC:8A:DF' } If the peer does not provide a certificate, it returns `null` or an empty object. -
koichik revised this gist
Aug 10, 2011 . 1 changed file with 19 additions and 7 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -8,24 +8,36 @@ It has all the common stream methods and events. #### cleartextStream.authorized A boolean that is `true` if the peer certificate was signed by one of the specified CAs, otherwise `false` #### cleartextStream.authorizationError The reason why the peer's certificate has not been verified. This property becomes available only when `cleartextStream.authorized === false`. #### cleartextStream.getPeerCertificate() Returns an object representing the peer's certicicate. The returned object has some properties corresponding to the field of the certificate. Example: { subject: { C: 'UK', ST: 'Acknack Ltd', L: 'Rhys Jones', O: 'node.js', OU: 'Test TLS Certificate', CN: 'localhost' }, issuer: { C: 'UK', ST: 'Acknack Ltd', L: 'Rhys Jones', O: 'node.js', OU: 'Test TLS Certificate', CN: 'localhost' }, valid_from: 'Nov 11 09:52:22 2009 GMT', valid_to: 'Nov 6 09:52:22 2029 GMT', fingerprint: '2A:7A:C2:DD:E5:F9:CC:53:72:35:99:7A:02:5A:71:38:52:EC:8A:DF' } If the peer has not been verified, it returns `null` -
koichik created this gist
Aug 9, 2011 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,31 @@ ### tls.CleartextStream This is a stream on top of the *Encrypted* stream. それ (Encrypted stream) の上で平文で読み書きできるって書きたいんだにょ。 This instance implements a duplex Stream interfaces. It has all the common stream methods and events. #### cleartextStream.authorized A boolean that is `true` if the peer certificate was signed by one of the specified CAs. #### cleartextStream.authorizationError The reason the peer's certificate has not been verified. This property exists only if `cleartextStream.authorized === false`. #### cleartextStream.getPeerCertificate() Returns an object representing the peer's certicicate. The returning object has some properties corresponding to the field of the certificate. Example: { subject: '/C=UK/ST=Acknack Ltd/L=Rhys Jones/O=node.js/OU=Test TLS Certificate/CN=localhost', issuer: '/C=UK/ST=Acknack Ltd/L=Rhys Jones/O=node.js/OU=Test TLS Certificate/CN=localhost', valid_from: 'Nov 11 09:52:22 2009 GMT', valid_to: 'Nov 6 09:52:22 2029 GMT', fingerprint: '2A:7A:C2:DD:E5:F9:CC:53:72:35:99:7A:02:5A:71:38:52:EC:8A:DF' } If the peer has not been verified, returns `null`