Remove the trust_anchor_negotiation property from CertificatePropertyList

This reflects draft-08. There's still the equivalent flag on
SSL_CREDENTIAL, but we realized the property did not actually make
sense. (The codepoint is reserved, so we won't have to worry about
collisions.)

Change-Id: I6b939d63310fe3e0ad14800370210b228fafd6f7
Reviewed-on: https://boringssl-review.googlesource.com/c/boringssl/+/106828
Commit-Queue: David Benjamin <davidben@google.com>
Commit-Queue: Lily Chen <chlily@google.com>
Reviewed-by: Lily Chen <chlily@google.com>
Auto-Submit: David Benjamin <davidben@google.com>
diff --git a/ssl/ssl_credential.cc b/ssl/ssl_credential.cc
index c088708..cb782be 100644
--- a/ssl/ssl_credential.cc
+++ b/ssl/ssl_credential.cc
@@ -880,15 +880,6 @@
         }
         break;
       }
-      case 2: {  // trust_anchor_negotiation
-        // See draft-ietf-tls-trust-anchor-ids-06, Section 7.3.
-        if (CBS_len(&data) != 0) {
-          OPENSSL_PUT_ERROR(SSL, SSL_R_INVALID_CERTIFICATE_PROPERTY_LIST);
-          return 0;
-        }
-        SSL_CREDENTIAL_set_must_match_issuer(cred_impl, 1);
-        break;
-      }
       default:
         break;
     }
diff --git a/ssl/test/runner/common.go b/ssl/test/runner/common.go
index e8c3e64..d73a82d 100644
--- a/ssl/test/runner/common.go
+++ b/ssl/test/runner/common.go
@@ -2418,15 +2418,13 @@
 }
 
 const (
-	certPropTrustAnchorID          uint16 = 0
-	certPropTrustAnchorGroups      uint16 = 1
-	certPropTrustAnchorNegotiation uint16 = 2
+	certPropTrustAnchorID     uint16 = 0
+	certPropTrustAnchorGroups uint16 = 1
 )
 
 type CertificatePropertyList struct {
-	TrustAnchorID          []byte
-	TrustAnchorGroups      [][]byte
-	TrustAnchorNegotiation bool
+	TrustAnchorID     []byte
+	TrustAnchorGroups [][]byte
 }
 
 func (c *CertificatePropertyList) Empty() bool {
@@ -2452,10 +2450,6 @@
 				})
 			})
 		}
-		if c.TrustAnchorNegotiation {
-			props.AddUint16(certPropTrustAnchorNegotiation)
-			props.AddUint16(0) // Zero-length property
-		}
 	})
 	return bb.BytesOrPanic()
 }
diff --git a/ssl/test/runner/trust_anchor_tests.go b/ssl/test/runner/trust_anchor_tests.go
index cd29288..773d4bd 100644
--- a/ssl/test/runner/trust_anchor_tests.go
+++ b/ssl/test/runner/trust_anchor_tests.go
@@ -386,7 +386,7 @@
 	// on an issuer match.
 	testCases = append(testCases, testCase{
 		testType: serverTest,
-		name:     "TrustAnchors-NoTrustAnchorNegotiationProperty",
+		name:     "TrustAnchors-NoMustMatchIssuer",
 		config: Config{
 			MinVersion:          VersionTLS13,
 			RequestTrustAnchors: [][]byte{id2},
@@ -397,36 +397,13 @@
 			}),
 			ecdsaP256Certificate.WithTrustAnchorID(id2),
 		},
-		// The first credential is chosen because it is not gated on a trust anchors.
+		// The first credential is chosen because it is not gated on trust anchors.
 		flags: []string{"-expect-selected-credential", "0"},
 		expectations: connectionExpectations{
 			peerCertificate: &rsaCertificate,
 		},
 	})
 
-	// The trust_anchor_negotiation property, however, does gate it.
-	testCases = append(testCases, testCase{
-		testType: serverTest,
-		name:     "TrustAnchors-TrustAnchorNegotiationProperty",
-		config: Config{
-			MinVersion:          VersionTLS13,
-			RequestTrustAnchors: [][]byte{id2},
-		},
-		shimCredentials: []*Credential{
-			rsaCertificate.WithProperties(CertificatePropertyList{
-				TrustAnchorID:          id1,
-				TrustAnchorNegotiation: true,
-			}),
-			ecdsaP256Certificate.WithTrustAnchorID(id2),
-		},
-		// The second credential is chosen because the first is gated on trust
-		// anchors and does not match.
-		flags: []string{"-expect-selected-credential", "1"},
-		expectations: connectionExpectations{
-			peerCertificate: &ecdsaP256Certificate,
-		},
-	})
-
 	group := MakeTrustAnchorID(32473, 100, 200, 300, 400)
 	// These ranges match the test group.
 	match := MakeTrustAnchorIDPattern(32473).Range(50, 100).Exact(200).Range(300, 350).AtLeast(350).Bytes()