Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 1 addition & 7 deletions src/node_crypto.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1099,15 +1099,9 @@ void SSLWrap<Base>::OnClientHello(void* arg,


static bool SafeX509ExtPrint(BIO* out, X509_EXTENSION* ext) {
// Only alt_name is escaped at the moment
if (OBJ_obj2nid(ext->object) != NID_subject_alt_name)
return false;

const X509V3_EXT_METHOD* method = X509V3_EXT_get(ext);
if (method == NULL || method->it == NULL)
return false;

if (method->i2v != reinterpret_cast<X509V3_EXT_I2V>(i2v_GENERAL_NAMES))
if (method != X509V3_EXT_get_nid(NID_subject_alt_name))
return false;

const unsigned char* p = ext->value->data;
Expand Down