Add explanation and warning to TLS id table.
authorDr. Stephen Henson <steve@openssl.org>
Sat, 13 Feb 2016 15:27:43 +0000 (15:27 +0000)
committerDr. Stephen Henson <steve@openssl.org>
Tue, 16 Feb 2016 14:01:40 +0000 (14:01 +0000)
Reviewed-by: Matt Caswell <matt@openssl.org>
ssl/t1_lib.c

index 522f0e68b175f2af6290765e603ebf019f9f94db..7aa4350331033cb096c13263088b2107797c5d72 100644 (file)
@@ -224,6 +224,12 @@ typedef struct {
 # define TLS_CURVE_CHAR2         0x1
 # define TLS_CURVE_PRIME         0x0
 
 # define TLS_CURVE_CHAR2         0x1
 # define TLS_CURVE_PRIME         0x0
 
+/*
+ * Table of curve information.
+ * NB: do not delete entries or reorder this array. It is used as a lookup
+ * table: the index of each entry is one less than the TLS curve id.
+ */
+
 static const tls_curve_info nid_list[] = {
     {NID_sect163k1, 80, TLS_CURVE_CHAR2}, /* sect163k1 (1) */
     {NID_sect163r1, 80, TLS_CURVE_CHAR2}, /* sect163r1 (2) */
 static const tls_curve_info nid_list[] = {
     {NID_sect163k1, 80, TLS_CURVE_CHAR2}, /* sect163k1 (1) */
     {NID_sect163r1, 80, TLS_CURVE_CHAR2}, /* sect163r1 (2) */