TS-1373: Silence spurious error when adding SSL certificates with alternate names
When a certificate has the name hostname for the CN and the DNS alternative name, we get a spurious error message from the hash collision. The error is spurious, so it's ok to just silence it. Review/Test: jpeach, zwoop, igalic backport: igalic Project: http://git-wip-us.apache.org/repos/asf/trafficserver/repo Commit: http://git-wip-us.apache.org/repos/asf/trafficserver/commit/7a96191a Tree: http://git-wip-us.apache.org/repos/asf/trafficserver/tree/7a96191a Diff: http://git-wip-us.apache.org/repos/asf/trafficserver/diff/7a96191a Branch: refs/heads/3.2.x Commit: 7a96191a99e8981e20583fcb118b94a7ca0f92c3 Parents: ff40d5f Author: James Peach <[email protected]> Authored: Sun Jul 8 16:11:57 2012 -0700 Committer: Igor GaliÄ <[email protected]> Committed: Thu Jul 19 18:26:45 2012 -0700 ---------------------------------------------------------------------- CHANGES | 3 +++ STATUS | 6 ------ iocore/net/SSLCertLookup.cc | 2 +- lib/ts/Trie.h | 2 +- 4 files changed, 5 insertions(+), 8 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/trafficserver/blob/7a96191a/CHANGES ---------------------------------------------------------------------- diff --git a/CHANGES b/CHANGES index 6df2aeb..4db2093 100644 --- a/CHANGES +++ b/CHANGES @@ -1,7 +1,10 @@ -*- coding: utf-8 -*- +<<<<<<< HEAD Changes with Apache Traffic Server 3.2.1 *) [TS-1358] Don't link libreadline with all binaries and plugins. + *) [TS-1373] Silence spurious error when adding SSL certificates with alternate names + *) [TS-1338] SSL not handling some events properly *) [TS-1362] Allow to open cache disk without O_DIRECT, for e.g. tmpfs http://git-wip-us.apache.org/repos/asf/trafficserver/blob/7a96191a/STATUS ---------------------------------------------------------------------- diff --git a/STATUS b/STATUS index 65ed3ad..27ea661 100644 --- a/STATUS +++ b/STATUS @@ -75,12 +75,6 @@ PATCHES PROPOSED TO BACKPORT FROM TRUNK: PATCHES ACCEPTED TO BACKPORT FROM TRUNK: [ New patches should be added at the end of the list ] - *) Silence spurious error when adding SSL certificates with - alternate names. - Trunk: b512fef66fd3f2118517eb5ac6b3a879cfa2caaa - Jira: https://issues.apache.org/jira/browse/TS-1373 - +1: jpeach, zwoop, igalic - *) Cert path not working using intermdiate certificate Trunk patch: 4ed023427a90c0d2bfa9c0c9dab26304f9aaf9fb Jira: https://issues.apache.org/jira/browse/TS-1374 http://git-wip-us.apache.org/repos/asf/trafficserver/blob/7a96191a/iocore/net/SSLCertLookup.cc ---------------------------------------------------------------------- diff --git a/iocore/net/SSLCertLookup.cc b/iocore/net/SSLCertLookup.cc index aef62c9..8c323a5 100644 --- a/iocore/net/SSLCertLookup.cc +++ b/iocore/net/SSLCertLookup.cc @@ -501,7 +501,7 @@ SSLContextStorage::insert(SSL_CTX * ctx, const char * name) } Debug("indexed wildcard certificate for '%s' as '%s'", name, reversed); - this->wildcards.Insert(reversed, new SslEntry(ctx), 0 /* rank */, -1 /* keylen */); + return this->wildcards.Insert(reversed, new SslEntry(ctx), 0 /* rank */, -1 /* keylen */); } else { ink_hash_table_insert(this->hostnames, name, (void *)ctx); } http://git-wip-us.apache.org/repos/asf/trafficserver/blob/7a96191a/lib/ts/Trie.h ---------------------------------------------------------------------- diff --git a/lib/ts/Trie.h b/lib/ts/Trie.h index 64d80a2..eed9207 100644 --- a/lib/ts/Trie.h +++ b/lib/ts/Trie.h @@ -142,7 +142,7 @@ Trie<T>::Insert(const char *key, T* value, int rank, int key_len /* = -1 */) } if (curr_node->occupied) { - Error("Cannot insert duplicate!"); + Debug("Trie::Insert", "Cannot insert duplicate!"); return false; }
