Roll src/third_party/WebKit d9c6159:8139f33 (svn 201974:201975)
[chromium-blink-merge.git] / net / cert / internal / verify_name_match.h
blob99d09f0e1077b7c8781c5de0ccca818c88e0eab7
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef NET_CERT_INTERNAL_VERIFY_NAME_MATCH_H_
6 #define NET_CERT_INTERNAL_VERIFY_NAME_MATCH_H_
8 #include "base/strings/string_piece.h"
9 #include "net/base/net_export.h"
11 namespace net {
13 namespace der {
14 class Input;
15 } // namespace der
17 // Compare DER-encoded X.501 Name values according to RFC 5280 rules.
18 // |a_rdn_sequence| and |b_rdn_sequence| should be the DER-encoded RDNSequence
19 // values (not including the Sequence tag).
20 // Returns true if |a_rdn_sequence| and |b_rdn_sequence| match.
21 NET_EXPORT bool VerifyNameMatch(const der::Input& a_rdn_sequence,
22 const der::Input& b_rdn_sequence);
24 } // namespace net
26 #endif // NET_CERT_INTERNAL_VERIFY_NAME_MATCH_H_