On the svn-auth-x509 branch: Teach the cert parser to return the subject CN
as well as the whole subject DN. Will use this later in JavaHL to restruct
the matching range for the subject patterin in SVNUtil.searchCredentials.

* subversion/include/svn_x509.h
  (svn_x509_certinfo_get_subject,
   svn_x509_certinfo_get_issuer): Clarify in docs that these functions
   return the whole Distinguished Name.
  (svn_x509_certinfo_get_subject_cn): New prototype.
* subversion/libsvn_subr/x509.h
  (svn_x509_certinfo_t): New member subject_cn.
* subversion/libsvn_subr/x509info.c
  (svn_x509_certinfo_dup): Copy the subject_cn.
  (svn_x509_certinfo_get_subject_cn): Implement.
* subversion/libsvn_subr/x509parse.c
  (x509parse_dn_gets): Optionally return the CN in a separate stringbuf.
  (svn_x509_parse_cert): Retreive and return the subject CN.


git-svn-id: https://svn.apache.org/repos/asf/subversion/branches/svn-auth-x509@1614643 13f79535-47bb-0310-9956-ffa450edef68
On the svn-auth-x509 branch: Expose the subject CN as a separate property
in JavaHL, and restrict the subject pattern in the search to the CN
instead of the whole subject (the latter is still scanned in full-text
search mode).

[in subversion/bindings/javahl]

* src/org/apache/subversion/javahl/SVNUtil.java
  (SVNUtil.searchCredentials): Update docs about the subjectPattern.
  (top-level): Remove unused, commented-out boilerplate code.
* src/org/apache/subversion/javahl/callback/AuthnCallback.java
  (AuthnCallback.SSLServerCertInfo.getSubject): Update docstring.
  (AuthnCallback.SSLServerCertInfo.getIssuer): Update docstring.
  (AuthnCallback.SSLServerCertInfo.getSubjectCommonName): New.
  (AuthnCallback.SSLServerCertInfo.SSLServerCertInfo):
   Update constructor signature with a new subjectCN parameter.

* native/AuthnCallback.cpp
  (AuthnCallback::SSLServerCertInfo::ClassImpl::ClassImpl):
   Update the Java constructor signature.
  (AuthnCallback::SSLServerCertInfo::SSLServerCertInfo):
   Pass the subject CN to the Java constructor.
* native/org_apache_subversion_javahl_util_ConfigLib.cpp
  (Java_org_apache_subversion_javahl_util_ConfigLib_nativeSearchCredentials):
   Restrict the subjectPattern search to the subject CN + hostnames.
   
* tests/org/apache/subversion/javahl/UtilTests.java
  (UtilTests.testCredentials): Test the new getSubjectCommonName function.


git-svn-id: https://svn.apache.org/repos/asf/subversion/branches/svn-auth-x509@1614648 13f79535-47bb-0310-9956-ffa450edef68