<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <title>Class Poco::Net::X509Certificate</title> <meta http-equiv="content-type" content="text/html; charset=utf-8"/> <meta name="author" content="Applied Informatics Software Engineering GmbH and Contributors"/> <meta name="publisher" content="Applied Informatics Software Engineering GmbH and Contributors"/> <meta name="copyright" content="Copyright (c) 2009, Applied Informatics Software Engineering GmbH and Contributors"/> <meta name="language" content="en"/> <meta name="date" content="2009-11-24"/> <meta name="generator" content="PocoDoc"/> <link rel="stylesheet" href="css/styles.css" type="text/css"/> </head> <body bgcolor="#ffffff" leftmargin="0" topmargin="0"> <div class="header"> <h1 class="namespace"><a href="Poco.Net.html" class="namespace">Poco::Net</a></h1> <h1 class="symbol">class X509Certificate</h1> </div> <div class="body"> <p> <b>Library:</b> NetSSL_OpenSSL<br /> <b>Package:</b> SSLCore<br /> <b>Header:</b> Poco/Net/X509Certificate.h</p> <h2>Description</h2> <div class="description"> <p>This class extends <a href="Poco.Crypto.X509Certificate.html" title="class Poco::Crypto::X509Certificate">Poco::Crypto::X509Certificate</a> with the feature to validate a certificate. </p> </div> <h2>Inheritance</h2> <p><b>Direct Base Classes: </b><a href="Poco.Crypto.X509Certificate.html" title="class Poco::Crypto::X509Certificate">Poco::Crypto::X509Certificate</a></p> <p><b>All Base Classes: </b><a href="Poco.Crypto.X509Certificate.html" title="class Poco::Crypto::X509Certificate">Poco::Crypto::X509Certificate</a></p> <h2>Member Summary</h2> <p><b>Member Functions: </b><a href="Poco.Net.X509Certificate.html#16311" title="Poco::Net::X509Certificate::containsWildcards()">containsWildcards</a>, <a href="Poco.Net.X509Certificate.html#16313" title="Poco::Net::X509Certificate::matchByAlias()">matchByAlias</a>, <a href="Poco.Net.X509Certificate.html#16303" title="Poco::Net::X509Certificate::operator =()">operator =</a>, <a href="Poco.Net.X509Certificate.html#16306" title="Poco::Net::X509Certificate::verify()">verify</a></p> <p><b>Inherited Functions: </b><a href="Poco.Crypto.X509Certificate.html#376" title="Poco::Crypto::X509Certificate::certificate()">certificate</a>, <a href="Poco.Crypto.X509Certificate.html#364" title="Poco::Crypto::X509Certificate::commonName()">commonName</a>, <a href="Poco.Crypto.X509Certificate.html#369" title="Poco::Crypto::X509Certificate::expiresOn()">expiresOn</a>, <a href="Poco.Crypto.X509Certificate.html#365" title="Poco::Crypto::X509Certificate::extractNames()">extractNames</a>, <a href="Poco.Crypto.X509Certificate.html#381" title="Poco::Crypto::X509Certificate::init()">init</a>, <a href="Poco.Crypto.X509Certificate.html#374" title="Poco::Crypto::X509Certificate::issuedBy()">issuedBy</a>, <a href="Poco.Crypto.X509Certificate.html#358" title="Poco::Crypto::X509Certificate::issuerName()">issuerName</a>, <a href="Poco.Crypto.X509Certificate.html#377" title="Poco::Crypto::X509Certificate::load()">load</a>, <a href="Poco.Crypto.X509Certificate.html#353" title="Poco::Crypto::X509Certificate::operator =()">operator =</a>, <a href="Poco.Crypto.X509Certificate.html#370" title="Poco::Crypto::X509Certificate::save()">save</a>, <a href="Poco.Crypto.X509Certificate.html#361" title="Poco::Crypto::X509Certificate::subjectName()">subjectName</a>, <a href="Poco.Crypto.X509Certificate.html#355" title="Poco::Crypto::X509Certificate::swap()">swap</a>, <a href="Poco.Crypto.X509Certificate.html#368" title="Poco::Crypto::X509Certificate::validFrom()">validFrom</a></p> <h2>Constructors</h2> <h3><a name="16295">X509Certificate</a></h3> <p class="decl">explicit <a href="Poco.Net.X509Certificate.html" title="class Poco::Net::X509Certificate">X509Certificate</a>(<br /> std::istream & istr<br />);</p> <div class="description"> <p>Creates the <a href="Poco.Net.X509Certificate.html" title="class Poco::Net::X509Certificate">X509Certificate</a> object by reading a certificate in PEM format from a stream. </p> </div> <h3><a name="16297">X509Certificate</a></h3> <p class="decl">explicit <a href="Poco.Net.X509Certificate.html" title="class Poco::Net::X509Certificate">X509Certificate</a>(<br /> const std::string & path<br />);</p> <div class="description"> <p>Creates the <a href="Poco.Net.X509Certificate.html" title="class Poco::Net::X509Certificate">X509Certificate</a> object by reading a certificate in PEM format from a file. </p> </div> <h3><a name="16299">X509Certificate</a></h3> <p class="decl">explicit <a href="Poco.Net.X509Certificate.html" title="class Poco::Net::X509Certificate">X509Certificate</a>(<br /> X509 * pCert<br />);</p> <div class="description"> <p>Creates the <a href="Poco.Net.X509Certificate.html" title="class Poco::Net::X509Certificate">X509Certificate</a> from an existing OpenSSL certificate. Ownership is taken of the certificate. </p> </div> <h3><a name="16301">X509Certificate</a></h3> <p class="decl"><a href="Poco.Net.X509Certificate.html" title="class Poco::Net::X509Certificate">X509Certificate</a>(<br /> const <a href="Poco.Crypto.X509Certificate.html" title="class Poco::Crypto::X509Certificate">Poco::Crypto::X509Certificate</a> & cert<br />);</p> <div class="description"> <p>Creates the certificate by copying another one. </p> </div> <h2>Destructor</h2> <h3><a name="16305">~X509Certificate</a></h3> <p class="decl">~<a href="Poco.Net.X509Certificate.html" title="class Poco::Net::X509Certificate">X509Certificate</a>();</p> <div class="description"> <p>Destroys the <a href="Poco.Net.X509Certificate.html" title="class Poco::Net::X509Certificate">X509Certificate</a>. </p> </div> <h2>Member Functions</h2> <h3><a name="16303">operator =</a></h3> <p class="decl"><a href="Poco.Net.X509Certificate.html" title="class Poco::Net::X509Certificate">X509Certificate</a> & operator = (<br /> const <a href="Poco.Crypto.X509Certificate.html" title="class Poco::Crypto::X509Certificate">Poco::Crypto::X509Certificate</a> & cert<br />);</p> <div class="description"> <p>Assigns a certificate. </p> </div> <h3><a name="16306">verify</a></h3> <p class="decl">long verify(<br /> const std::string & hostName<br />) const;</p> <div class="description"> <p>Verifies the validity of the certificate against the host name. </p> <p>Returns X509_V_OK if verification succeeded, or an error code (X509_V_ERR_APPLICATION_VERIFICATION) otherwise. </p> </div> <h3><a name="16308">verify</a> <img src="images/static.gif" alt="static" title="static" style="vertical-align:baseline;" border="0" /> </h3> <p class="decl">static long verify(<br /> const <a href="Poco.Crypto.X509Certificate.html" title="class Poco::Crypto::X509Certificate">Poco::Crypto::X509Certificate</a> & cert,<br /> const std::string & hostName<br />);</p> <div class="description"> <p>Verifies the validity of the certificate against the host name. </p> <p>Returns X509_V_OK if verification succeeded, or an error code (X509_V_ERR_APPLICATION_VERIFICATION) otherwise. </p> </div> <h3><a name="16311">containsWildcards</a> <img src="images/protected.gif" alt="protected" title="protected" style="vertical-align:baseline;" border="0" /> <img src="images/static.gif" alt="static" title="static" style="vertical-align:baseline;" border="0" /> </h3> <p class="decl">static bool containsWildcards(<br /> const std::string & commonName<br />);</p> <div class="description"> <p></p> </div> <h3><a name="16313">matchByAlias</a> <img src="images/protected.gif" alt="protected" title="protected" style="vertical-align:baseline;" border="0" /> <img src="images/static.gif" alt="static" title="static" style="vertical-align:baseline;" border="0" /> </h3> <p class="decl">static bool matchByAlias(<br /> const std::string & alias,<br /> const <a href="Poco.Net.HostEntry.html" title="class Poco::Net::HostEntry">HostEntry</a> & heData<br />);</p> <div class="description"> <p></p> </div> <p class="footer">POCO C++ Libraries 1.3.6-all<br /> Copyright © 2009, <a href="http://pocoproject.org/" target="_blank">Applied Informatics Software Engineering GmbH and Contributors</a></p> </div> </body> </html>