@@ -583,13 +583,16 @@ For Example: `{ type: 'ECDH', name: 'prime256v1', size: 256 }` |
583 | 583 | added: v0.11.4 |
584 | 584 | --> |
585 | 585 |
|
586 | | -* `detailed` {boolean} Specify `true` to request that the full certificate |
587 | | - chain with the `issuer` property be returned; `false` to return only the |
588 | | - top certificate without the `issuer` property. |
| 586 | +* `detailed` {boolean} Include the full certificate chain if `true`, otherwise |
| 587 | + include just the peer's certificate. |
589 | 588 |
|
590 | 589 | Returns an object representing the peer's certificate. The returned object has |
591 | 590 | some properties corresponding to the fields of the certificate. |
592 | 591 |
|
| 592 | +If the full certificate chain was requested, each certificate will include a |
| 593 | +`issuerCertificate` property containing an object representing its issuer's |
| 594 | +certificate. |
| 595 | + |
593 | 596 | For example: |
594 | 597 |
|
595 | 598 | ```text |
@@ -600,24 +603,23 @@ For example: |
600 | 603 | O: 'node.js', |
601 | 604 | OU: 'Test TLS Certificate', |
602 | 605 | CN: 'localhost' }, |
603 | | - issuerInfo: |
| 606 | + issuer: |
604 | 607 | { C: 'UK', |
605 | 608 | ST: 'Acknack Ltd', |
606 | 609 | L: 'Rhys Jones', |
607 | 610 | O: 'node.js', |
608 | 611 | OU: 'Test TLS Certificate', |
609 | 612 | CN: 'localhost' }, |
610 | | - issuer: |
611 | | - { ... another certificate ... }, |
| 613 | + issuerCertificate: |
| 614 | + { ... another certificate, possibly with a .issuerCertificate ... }, |
612 | 615 | raw: < RAW DER buffer >, |
613 | 616 | valid_from: 'Nov 11 09:52:22 2009 GMT', |
614 | 617 | valid_to: 'Nov 6 09:52:22 2029 GMT', |
615 | 618 | fingerprint: '2A:7A:C2:DD:E5:F9:CC:53:72:35:99:7A:02:5A:71:38:52:EC:8A:DF', |
616 | 619 | serialNumber: 'B9B0D332A1AA5635' } |
617 | 620 | ``` |
618 | 621 |
|
619 | | -If the peer does not provide a certificate, `null` or an empty object will be |
620 | | -returned. |
| 622 | +If the peer does not provide a certificate, an empty object will be returned. |
621 | 623 |
|
622 | 624 | ### tlsSocket.getProtocol() |
623 | 625 | <!-- YAML |
|