{"id":211474,"date":"2014-02-05T14:13:03","date_gmt":"2014-02-05T10:13:03","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=211474"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=211474","title":{"rendered":"<span class=\"post_title\">\u041f\u0440\u043e\u0441\u0442\u0435\u0439\u0448\u0438\u0439 \u043a\u0440\u043e\u0441c\u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0435\u043d\u043d\u044b\u0439 \u0441\u0435\u0440\u0432\u0435\u0440 \u0441 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u043e\u0439 ssl<\/span>"},"content":{"rendered":"<div class=\"content html_format\"> \t\t\t\u041d\u0435 \u0442\u0430\u043a \u0434\u0430\u0432\u043d\u043e \u043f\u0435\u0440\u0435\u0434\u043e \u043c\u043d\u043e\u0439 \u0432\u0441\u0442\u0430\u043b\u0430 \u0437\u0430\u0434\u0430\u0447\u0430: \u043d\u0430\u043f\u0438\u0441\u0430\u0442\u044c \u043a\u0440\u043e\u0441\u0441\u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0435\u043d\u043d\u044b\u0439 \u0441\u0435\u0440\u0432\u0435\u0440 \u0434\u043b\u044f \u043e\u0431\u0440\u0430\u0431\u043e\u0442\u043a\u0438 \u0437\u0430\u043f\u0440\u043e\u0441\u043e\u0432 \u043f\u043e \u043f\u0440\u043e\u0442\u043e\u043a\u043e\u043b\u0443 ssl. \u0414\u043e \u044d\u0442\u043e\u0433\u043e \u044f \u043f\u0438\u0441\u0430\u043b \u0441\u0435\u0440\u0432\u0435\u0440\u0430 \u0434\u043b\u044f \u043e\u0431\u044b\u0447\u043d\u044b\u0445, \u043d\u0435 \u0448\u0438\u0444\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0445 \u043f\u0440\u043e\u0442\u043e\u043a\u043e\u043b\u043e\u0432, \u043d\u043e \u0441 ssl \u0441\u0442\u043e\u043b\u043a\u043d\u0443\u043b\u0441\u044f \u0432\u043f\u0435\u0440\u0432\u044b\u0435.<br \/>  \u0411\u0435\u0433\u043b\u044b\u0439 \u043e\u0431\u0437\u043e\u0440 \u0438\u043d\u0442\u0435\u0440\u043d\u0435\u0442\u0430 \u043f\u043e\u043a\u0430\u0437\u0430\u043b, \u0447\u0442\u043e \u043b\u0443\u0447\u0448\u0438\u043c \u0440\u0435\u0448\u0435\u043d\u0438\u0435\u043c \u0431\u0443\u0434\u0435\u0442 \u043d\u0435 \u0432\u0435\u043b\u043e\u0441\u0438\u043f\u0435\u0434\u043e\u0441\u0442\u0440\u043e\u0435\u043d\u0438\u0435, \u0430 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 OpenSSL.<br \/>  \u0412 \u044d\u0442\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0435 \u044f \u043d\u0435 \u0445\u043e\u0447\u0443 \u0440\u0430\u0441\u0441\u043c\u0430\u0442\u0440\u0438\u0432\u0430\u0442\u044c \u043f\u0440\u043e\u0446\u0435\u0441\u0441 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438 OpenSSL \u043d\u0430 Linux \u0438 Windows, \u0437\u0430\u043c\u0435\u0447\u0443 \u043b\u0438\u0448\u044c, \u0447\u0442\u043e \u0434\u043b\u044f Windows \u043f\u0440\u043e\u0446\u0435\u0441\u0441 \u044d\u0442\u043e\u0442 \u043e\u043a\u0430\u0437\u0430\u043b\u0441\u044f \u043d\u0435\u0442\u0440\u0438\u0432\u0438\u0430\u043b\u044c\u043d\u044b\u043c. \u0410 \u0440\u0430\u0441\u0441\u043a\u0430\u0437\u0430\u0442\u044c \u044f \u0445\u043e\u0447\u0443 \u043e \u0442\u043e\u043c, \u043a\u0430\u043a \u043c\u043d\u0435 \u0443\u0434\u0430\u043b\u043e\u0441\u044c \u0441\u043a\u043e\u043c\u043f\u0438\u043b\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0432 Visual Studio \u043f\u0440\u0438\u043c\u0435\u0440 \u043f\u0440\u043e\u0441\u0442\u0435\u0439\u0448\u0435\u0433\u043e \u0441\u0435\u0440\u0432\u0435\u0440\u0430, \u0432\u0445\u043e\u0434\u044f\u0449\u0438\u0439 \u0432 \u0441\u043e\u0441\u0442\u0430\u0432 \u0438\u0441\u0445\u043e\u0434\u043d\u0438\u043a\u043e\u0432 OpenSSL.<br \/>  \u041d\u0435\u0438\u0441\u043a\u0443\u0448\u0435\u043d\u043d\u043e\u043c\u0443 \u0447\u0438\u0442\u0430\u0442\u0435\u043b\u044e \u043c\u043e\u0436\u0435\u0442 \u043f\u043e\u043a\u0430\u0437\u0430\u0442\u044c\u0441\u044f: \u00ab\u0447\u0442\u043e \u0442\u0443\u0442 \u043e\u0441\u043e\u0431\u0435\u043d\u043d\u043e\u0433\u043e \u2014 \u0441\u043e\u0437\u0434\u0430\u043b \u043f\u0440\u043e\u0435\u043a\u0442, \u0432\u043a\u043b\u044e\u0447\u0438\u043b \u0432 \u043d\u0435\u0433\u043e \u0433\u043e\u0442\u043e\u0432\u044b\u0439 \u0438\u0441\u0445\u043e\u0434\u043d\u0438\u043a, \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u043b\u00bb\u2026 \u041e\u0434\u043d\u0430\u043a\u043e \u043e\u0431\u043e \u0432\u0441\u0435\u043c \u043f\u043e \u043f\u043e\u0440\u044f\u0434\u043a\u0443.<\/p>\n<p>  <a name=\"habracut\"><\/a>\u041c\u043d\u0435, \u043a\u0430\u043a \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0438\u0441\u0442\u0443 \u043f\u0440\u043e\u0449\u0435 \u0440\u0430\u0441\u0441\u043a\u0430\u0437\u044b\u0432\u0430\u0442\u044c \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u044f \u043f\u043e \u0448\u0430\u0433\u0430\u043c:<\/p>\n<p>  1. \u0421\u043e\u0437\u0434\u0430\u0435\u043c \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u044e \u0434\u043b\u044f \u044d\u043a\u0441\u043f\u0435\u0440\u0438\u043c\u0435\u043d\u0442\u043e\u0432: <br \/>  \u041f\u0443\u0441\u0442\u044c \u044d\u0442\u043e \u0431\u0443\u0434\u0435\u0442 \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 <b>\u0421:\\testssl<\/b><\/p>\n<p>  2. \u0421\u043a\u0430\u0447\u0438\u0432\u0430\u0435\u043c \u0438\u0441\u0445\u043e\u0434\u043d\u044b\u0439 \u043a\u043e\u0434 OpenSSL<br \/>  \u041f\u0443\u0441\u0442\u044c \u044d\u0442\u043e\u0442 \u043a\u043e\u0434 \u0445\u0440\u0430\u043d\u0438\u0442\u0441\u044f \u043d\u0438\u043f\u0440\u0438\u043c\u0435\u0440 \u0432 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u0438 <b>C:\\openssl-1.0.1c<\/b><br \/>  3. \u041a\u043e\u043c\u043f\u0438\u043b\u0438\u0440\u0443\u0435\u043c OpenSSL<br \/>  \u041f\u043e\u0441\u043b\u0435 \u043a\u043e\u043c\u043f\u0438\u043b\u044f\u0446\u0438\u0438 \u0443 \u0432\u0430\u0441 \u0431\u0443\u0434\u0435\u0442 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u044f \u0441 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u0447\u043d\u044b\u043c\u0438 \u0438 \u0437\u0430\u0433\u043e\u043b\u043e\u0432\u043e\u0447\u043d\u044b\u043c\u0438 \u0444\u0430\u0439\u043b\u0430\u043c\u0438. \u0421\u043a\u043e\u043f\u0438\u0440\u0443\u0439\u0442\u0435 \u044d\u0442\u0443 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u044e \u0432 \u043d\u0430\u0448\u0443 \u0442\u0435\u0441\u0442\u043e\u0432\u0443\u044e. \u0412 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0435 \u0434\u043e\u043b\u0436\u043d\u0430 \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c\u0441\u044f \u0442\u0430\u043a\u0430\u044f \u0441\u0442\u0440\u0443\u043a\u0442\u0443\u0440\u0430 \u0444\u0430\u0439\u043b\u043e\u0432 \u0438 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u0439:<br \/>  \u0421:\\testssl<br \/>  \u0421:\\testssl\\openssl<br \/>  \u0421:\\testssl\\openssl\\bin<br \/>  \u0421:\\testssl\\openssl\\bin\\openssl.exe<br \/>  \u0421:\\testssl\\openssl\\include<br \/>  \u0421:\\testssl\\openssl\\include\\openssl<br \/>  \u0421:\\testssl\\openssl\\include\\openssl\\aes.h<br \/>  &#8230;..<i>(\u0442\u0443\u0442 \u043c\u043d\u043e\u0433\u043e \u0437\u0430\u0433\u043e\u043b\u043e\u0432\u043e\u0447\u043d\u044b\u0445 \u0444\u0430\u0439\u043b\u043e\u0432)<\/i><br \/>  \u0421:\\testssl\\openssl\\include\\openssl\\x509v3.h<br \/>  \u0421:\\testssl\\openssl\\lib<br \/>  \u0421:\\testssl\\openssl\\lib\\libeay32.lib<br \/>  \u0421:\\testssl\\openssl\\lib\\ssleay32.lib<br \/>  \u0421:\\testssl\\openssl\\ssl<br \/>  \u0421:\\testssl\\openssl\\ssl\\openssl<\/p>\n<p>  4. \u0421\u043a\u043e\u043f\u0438\u0440\u0443\u0435\u043c \u043d\u0443\u0436\u043d\u044b\u0439 \u043f\u0440\u0438\u043c\u0435\u0440 \u0438\u0437 <b>C:\\openssl-1.0.1c\\demos\\ssl\\serv.cpp<\/b> \u0432 <b>\u0421:\\testssl\\serv.cpp<\/b><\/p>\n<p>  5. \u0414\u043b\u044f \u0440\u0430\u0431\u043e\u0442\u044b \u043f\u0440\u0438\u043c\u0435\u0440\u0430 \u043f\u043e\u0442\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044f \u0444\u0430\u0439\u043b \u0441 \u0441\u0435\u043a\u0440\u0435\u0442\u043d\u044b\u043c \u043a\u043b\u044e\u0447\u0435\u043c. \u042d\u0442\u043e\u0442 \u0444\u0430\u0439\u043b \u043c\u043e\u0436\u043d\u043e \u0442\u043e\u0436\u0435 \u0432\u0437\u044f\u0442\u044c \u0438\u0437 \u0438\u0441\u0445\u043e\u0434\u043d\u0438\u043a\u043e\u0432.<br \/>  \u0421\u043a\u043e\u043f\u0438\u0440\u0443\u0435\u043c \u0435\u0433\u043e \u0438\u0437 <b>C:\\openssl-1.0.1c\\certs\\demo\\ca-cert.pem<\/b> \u0432 <b>\u0421:\\testssl\\ca-cert.pem<\/b><\/p>\n<p>  5. \u0421\u043e\u0437\u0434\u0430\u0435\u043c \u043f\u0443\u0441\u0442\u043e\u0439 \u043a\u043e\u043d\u0441\u043e\u043b\u044c\u043d\u044b\u0439 \u043f\u0440\u043e\u0435\u043a\u0442 \u0432 Visual Studio \u0438 \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u043c \u0432 \u043d\u0435\u0433\u043e \u0444\u0430\u0439\u043b serv.cpp.<br \/>  6. \u0412 \u0441\u0432\u043e\u0439\u0441\u0442\u0432\u0430\u0445 \u043f\u0440\u043e\u0435\u043a\u0442\u0430 \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u043c \u043f\u0443\u0442\u044c \u0434\u043b\u044f \u0437\u0430\u0433\u043e\u043b\u043e\u0432\u043a\u043e\u0432: <b>\u0421:\\testssl\\openssl\\include<\/b> \u0438 \u043f\u0443\u0442\u044c \u0434\u043b\u044f \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a: <b>\u0421:\\testssl\\openssl\\lib<\/b>. \u0410 \u0442\u0430\u043a\u0436\u0435 \u0441\u0430\u043c\u0438 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 <b>libeay32.lib, ssleay32.lib<\/b><\/p>\n<p>  7. \u0422\u0435\u043f\u0435\u0440\u044c \u0432 \u043a\u043e\u0434\u0435 \u0438\u0441\u043f\u0440\u0430\u0432\u043b\u044f\u0435\u043c<\/p>\n<pre><code class=\"cpp\">#define CERTF  HOME &quot;foo-cert.pem&quot; #define KEYF  HOME  &quot;foo-cert.pem&quot; <\/code><\/pre>\n<p>  \u043d\u0430   <\/p>\n<pre><code class=\"cpp\">#define CERTF  HOME &quot;ca-cert.pem&quot; #define KEYF  HOME  &quot;ca-cert.pem <\/code><\/pre>\n<p>  8. \u041a\u0430\u0437\u0430\u043b\u043e\u0441\u044c \u0431\u044b \u0432\u043e\u0442 \u0438 \u0432\u0441\u0435, \u043d\u043e \u043a\u043e\u0434 \u043a\u043e\u043d\u0435\u0447\u043d\u043e \u043d\u0435 \u0441\u043a\u043e\u043c\u043f\u0438\u043b\u0438\u0440\u0443\u0435\u0442\u0441\u044f. \u0414\u0435\u043b\u043e \u0432 \u0442\u043e\u043c, \u0447\u0442\u043e \u0432 Windows \u0438 Linux \u043d\u0443\u0436\u043d\u043e \u0432\u043a\u043b\u044e\u0447\u0430\u0442\u044c \u0440\u0430\u0437\u043d\u044b\u0435 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u044b\u0435 \u0437\u0430\u0433\u043e\u043b\u043e\u0432\u043e\u0447\u043d\u044b\u0435 \u0444\u0430\u0439\u043b\u044b.<\/p>\n<p>  \u041d\u0443\u0436\u043d\u043e \u0438\u0441\u043f\u0440\u0430\u0432\u0438\u0442\u044c  <\/p>\n<pre><code class=\"cpp\">#include &lt;stdio.h&gt; #include &lt;unistd.h&gt; #include &lt;stdlib.h&gt; #include &lt;memory.h&gt; #include &lt;errno.h&gt; #include &lt;sys\/types.h&gt; #include &lt;sys\/socket.h&gt; #include &lt;netinet\/in.h&gt; #include &lt;arpa\/inet.h&gt; #include &lt;netdb.h&gt;  #include &lt;openssl\/rsa.h&gt;       \/* SSLeay stuff *\/ #include &lt;openssl\/crypto.h&gt; #include &lt;openssl\/x509.h&gt; #include &lt;openssl\/pem.h&gt; #include &lt;openssl\/ssl.h&gt; #include &lt;openssl\/err.h&gt;  <\/code><\/pre>\n<p>  \u043d\u0430  <\/p>\n<pre><code class=\"cpp\">#include &lt;stdio.h&gt; #include &lt;stdlib.h&gt; #include &lt;memory.h&gt; #include &lt;errno.h&gt; #include &lt;sys\/types.h&gt;  #ifndef WIN32 #include &lt;unistd.h&gt; #include &lt;sys\/socket.h&gt; #include &lt;netinet\/in.h&gt; #include &lt;arpa\/inet.h&gt; #include &lt;netdb.h&gt; #else #include &lt;io.h&gt; #include &lt;Winsock2.h&gt; #pragma comment(lib, &quot;ws2_32.lib&quot;) #endif  #include &lt;openssl\/rsa.h&gt;       \/* SSLeay stuff *\/ #include &lt;openssl\/crypto.h&gt; #include &lt;openssl\/x509.h&gt; #include &lt;openssl\/pem.h&gt; #include &lt;openssl\/ssl.h&gt; #include &lt;openssl\/err.h&gt; <\/code><\/pre>\n<p>  \u041a\u0430\u043a \u0432\u0438\u0434\u043d\u043e, \u0434\u043b\u044f Windows \u043d\u0443\u0436\u043d\u043e \u0432\u043a\u043b\u044e\u0447\u0438\u0442\u044c \u0444\u0430\u0439\u043b \u00abWinsock2.h\u00bb, \u0430 \u0442\u0430\u043a \u0436\u0435 \u043d\u0430 \u0432\u0441\u044f\u043a\u0438\u0439 \u0441\u043b\u0443\u0447\u0430\u0439 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0443 \u0441\u043e\u043a\u0435\u0442\u043e\u0432.<\/p>\n<p>  9. \u041d\u043e \u0438 \u044d\u0442\u043e \u0435\u0449\u0435 \u043d\u0435 \u0432\u0441\u0435! \u0415\u0441\u043b\u0438 \u0442\u0435\u043f\u0435\u0440\u044c \u043f\u043e\u043f\u044b\u0442\u0430\u0442\u044c\u0441\u044f \u0441\u043a\u043e\u043c\u043f\u0438\u043b\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043f\u0440\u043e\u0435\u043a\u0442, \u0442\u043e \u0431\u0443\u0434\u0443\u0442 \u0432\u044b\u0434\u0430\u043d\u044b \u043e\u0448\u0438\u0431\u043a\u0438:<br \/>  error C2440: &#8216;=&#8217;: cannot convert from &#8216;const SSL_METHOD *&#8217; to &#8216;SSL_METHOD *&#8217;<br \/>  error C2664: &#8216;accept&#8217;: cannot convert parameter 3 from &#8216;size_t *&#8217; to &#8216;int *&#8217;<\/p>\n<p>  \u042d\u0442\u0438 \u043e\u0448\u0438\u0431\u043a\u0438 \u043b\u0435\u0433\u043a\u043e \u043d\u0430\u0445\u043e\u0434\u044f\u0442\u0441\u044f \u0438 \u0438\u0441\u043f\u0440\u0430\u0432\u043b\u044f\u044e\u0442\u0441\u044f, \u043d\u043e \u0435\u0441\u043b\u0438 \u0432\u044b \u0445\u043e\u0442\u0438\u0442\u0435 \u043a\u0440\u043e\u0441\u043f\u043b\u043e\u0442\u0444\u043e\u0440\u043c\u0435\u043d\u043d\u043e\u0441\u0442\u0438, \u0442\u043e \u0438\u0441\u043f\u0440\u0430\u0432\u043b\u044f\u0442\u044c \u043d\u0430\u0434\u043e \u0430\u043a\u043a\u0443\u0440\u0430\u0442\u043d\u043e:<\/p>\n<p>  \u0414\u043b\u044f \u043f\u0435\u0440\u0432\u043e\u0439 \u043e\u0448\u0438\u0431\u043a\u0438 \u043d\u0430\u0434\u043e  <\/p>\n<pre><code class=\"cpp\">  meth = SSLv23_server_method(); <\/code><\/pre>\n<p>  \u0438\u0441\u043f\u0440\u0430\u0432\u0438\u0442\u044c \u043d\u0430 <\/p>\n<pre><code class=\"cpp\">#ifdef WIN32   const SSL_METHOD *meth = SSLv23_server_method(); #else   SSL_METHOD *meth = SSLv23_server_method(); #endif <\/code><\/pre>\n<p>  \u0414\u043b\u044f \u0432\u0442\u043e\u0440\u043e\u0439 \u043e\u0448\u0438\u0431\u043a\u0438 \u043d\u0430\u0434\u043e  <\/p>\n<pre><code class=\"cpp\">  sd = accept (listen_sd, (struct sockaddr*) &sa_cli, &client_len); <\/code><\/pre>\n<p>  \u0438\u0441\u043f\u0440\u0430\u0432\u0438\u0442\u044c \u043d\u0430<\/p>\n<pre><code class=\"cpp\">#ifdef WIN32 \tsd = accept (listen_sd, (struct sockaddr*) &sa_cli, (int *)&client_len); #else \tsd = accept (listen_sd, (struct sockaddr*) &sa_cli, &client_len); #endif   <\/code><\/pre>\n<p>  10. \u0412\u043e\u0442 \u0442\u0435\u043f\u0435\u0440\u044c \u043a\u043e\u0434 \u0441\u043a\u043e\u043c\u043f\u0438\u043b\u0438\u0440\u0443\u0435\u0442\u0441\u044f \u0438 \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u0441\u044f, \u043d\u043e \u0432\u044b\u0434\u0430\u0441\u0442 \u043e\u0448\u0438\u0431\u043a\u0443 \u0432 \u0441\u0442\u0440\u043e\u043a\u0435<br \/>  \u00ablisten_sd = socket (AF_INET, SOCK_STREAM, 0); CHK_ERR(listen_sd, \u201esocket\u201c);\u00bb<br \/>  \u0414\u0430. \u0412 Windows, \u0447\u0442\u043e\u0431\u044b \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0441 \u0441\u043e\u043a\u0435\u0442\u0430\u043c\u0438, \u043d\u0430\u0434\u043e \u0441\u043d\u0430\u0447\u0430\u043b\u0430 \u0432\u044b\u0437\u0432\u0430\u0442\u044c \u0444\u0443\u043d\u043a\u0446\u0438\u044e WSAStartup()!<br \/>  \u0414\u043e\u0431\u0430\u0432\u0438\u043c \u0435\u0435 \u0432 \u043d\u0430\u0447\u0430\u043b\u043e \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u044b:  <\/p>\n<pre><code class=\"cpp\">void main () {   int err;   int listen_sd;   int sd;   struct sockaddr_in sa_serv;   struct sockaddr_in sa_cli;   size_t client_len;   SSL_CTX* ctx;   SSL*     ssl;   X509*    client_cert;   char*    str;   char     buf [4096];    #ifdef WIN32 \tWSADATA wsaData; \tif ( WSAStartup( MAKEWORD( 2, 2 ), &wsaData ) != 0 ) \t{ \t\tprintf(&quot;Could not to find usable WinSock in WSAStartup\\n&quot;); \t\treturn; \t} #endif <\/code><\/pre>\n<p>  11. \u0417\u0430\u043f\u0443\u0441\u0430\u0435\u043c \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0443, Windows \u043f\u0440\u043e\u0441\u0438\u0442 \u0440\u0430\u0437\u0440\u0435\u0448\u0435\u043d\u0438\u044f \u0447\u0442\u043e\u0431\u044b \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u043c\u043e\u0433\u043b\u043e \u043e\u0442\u043a\u0440\u044b\u0442\u044c \u043f\u043e\u0440\u0442. \u0420\u0430\u0437\u0440\u0435\u0448\u0430\u0435\u043c.<br \/>  \u041f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u0434\u043e\u0445\u043e\u0434\u0438\u0442 \u0434\u043e \u0441\u0442\u0440\u043e\u043a\u0438  <\/p>\n<pre><code class=\"cpp\">sd = accept (listen_sd, (struct sockaddr*) &sa_cli, (int *)&client_len); <\/code><\/pre>\n<p>  \u0438 \u043f\u043e\u0434\u0432\u0438\u0441\u0430\u0435\u0442.<br \/>  \u0412\u0441\u0435 \u043f\u0440\u0430\u0432\u0438\u043b\u044c\u043d\u043e, \u043d\u0430\u0448 \u0441\u0435\u0440\u0432\u0435\u0440 \u0436\u0434\u0435\u0442 \u043f\u043e\u043a\u0430 \u043a \u043d\u0435\u043c\u0443 \u043a\u0442\u043e-\u043d\u0438\u0431\u0443\u0434\u044c \u043f\u043e\u0434\u0441\u043e\u0435\u0434\u0438\u043d\u0438\u0442\u0441\u044f.<br \/>  \u041d\u0430 \u044d\u0442\u043e\u043c \u044d\u0442\u0430\u043f\u0435 \u0441\u043e\u0435\u0434\u0438\u043d\u0438\u0442\u044c\u0441\u044f \u043c\u043e\u0436\u043d\u043e \u0438\u0437 \u043a\u043e\u043c\u0430\u043d\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0438: \u00abtelnet localhost 1111\u00bb. \u041a\u0430\u043a \u0442\u043e\u043b\u044c\u043a\u043e \u0441\u043e\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u0435 \u043f\u0440\u043e\u0438\u0437\u043e\u0439\u0434\u0435\u0442, \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0430 \u043f\u0440\u043e\u0434\u043e\u043b\u0436\u0438\u0442 \u0440\u0430\u0431\u043e\u0442\u0443 \u0434\u043e \u0441\u0442\u0440\u043e\u043a\u0438  <\/p>\n<pre><code class=\"cpp\">close (listen_sd); <\/code><\/pre>\n<p>  \u041d\u0430 \u044d\u0442\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0435 Visual Studio \u0432\u044b\u0434\u0430\u0441\u0442 \u043d\u0435\u043f\u043e\u043d\u044f\u0442\u043d\u0443\u044e \u043e\u0448\u0438\u0431\u043a\u0443.<br \/>  \u041d\u043e \u0435\u0441\u043b\u0438 \u0440\u0430\u0437\u043e\u0431\u0440\u0430\u0442\u044c\u0441\u044f \u0442\u043e \u043e\u043a\u0430\u0436\u0435\u0442\u0441\u044f, \u0447\u0442\u043e \u0432 Windows \u0441\u043e\u043a\u0435\u0442\u044b \u0437\u0430\u043a\u0440\u044b\u0432\u0430\u044e\u0442 \u0434\u0440\u0443\u0433\u043e\u0439 \u0444\u0443\u043d\u043a\u0446\u0438\u0435\u0439: \u00abclosesocket()\u00bb.<br \/>  \u0427\u0442\u043e\u0431\u044b \u0438\u0437\u0431\u0435\u0436\u0430\u0442\u044c \u043e\u0448\u0438\u0431\u043e\u043a \u2014 \u043c\u0435\u043d\u044f\u0435\u043c \u0432\u0435\u0437\u0434\u0435 close \u043d\u0430 closesocket, \u0430 \u0434\u043b\u044f \u043a\u0440\u043e\u0441\u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0435\u043d\u043d\u043e\u0441\u0442\u0438 \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u043c \u043a\u043e\u0434:  <\/p>\n<pre><code class=\"cpp\">#ifndef WIN32 #define closesocket  close #endif <\/code><\/pre>\n<p>  12. \u0422\u0435\u043f\u0435\u0440\u044c \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u043b\u043e\u0441\u044c \u0438 \u043e\u0442\u0440\u0430\u0431\u043e\u0442\u0430\u043b\u043e \u0434\u043e \u0441\u0442\u0440\u043e\u043a\u0438  <\/p>\n<pre><code class=\"cpp\">err = SSL_accept (ssl);                        CHK_SSL(err); <\/code><\/pre>\n<p>  \u0417\u0434\u0435\u0441\u044c \u043e\u043d\u043e \u043e\u043f\u044f\u0442\u044c \u043f\u043e\u0432\u0438\u0441\u043b\u043e, \u043e\u0447\u0435\u0432\u0438\u0434\u043d\u043e \u043e\u0436\u0438\u0434\u0430\u044f \u043e\u0442 \u043a\u043b\u0438\u0435\u043d\u0442\u0430 \u043e\u0431\u043c\u0435\u043d\u0430 \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u044f\u043c\u0438 \u043f\u043e \u043f\u0440\u043e\u0442\u043e\u043a\u043e\u043b\u0443 ssl.<br \/>  \u041a\u0430\u043a \u043e\u0431\u043c\u0435\u043d\u0438\u0432\u0430\u0442\u044c\u0441\u044f \u044d\u0442\u0438\u043c\u0438 \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u044f\u043c\u0438 \u0432\u0440\u0443\u0447\u043d\u0443\u044e \u0442\u0435\u043b\u043d\u0435\u0442\u043e\u043c, \u044f \u043b\u0438\u0447\u043d\u043e \u043d\u0435 \u0437\u043d\u0430\u044e. \u041d\u043e \u0447\u0442\u043e\u0431\u044b \u043f\u0440\u043e\u0432\u0435\u0440\u0438\u0442\u044c \u0440\u0430\u0431\u043e\u0442\u0443 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u044b \u0434\u043e \u043a\u043e\u043d\u0446\u0430 \u043c\u043e\u0436\u043d\u043e \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u043e\u0431\u044b\u0447\u043d\u044b\u043c \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u043e\u043c!<\/p>\n<p>  13. \u0414\u043b\u044f \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0438 \u0440\u0430\u0431\u043e\u0442\u043e\u0441\u043f\u043e\u0441\u043e\u0431\u043d\u043e\u0441\u0442\u0438 \u043d\u0430\u0448\u0435\u0433\u043e \u0441\u0435\u0440\u0432\u0435\u0440\u0430 \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u043c \u0435\u0433\u043e, \u0430 \u0432\u043c\u0435\u0441\u0442\u043e \u043a\u043e\u043c\u0430\u043d\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0438 \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u043c \u0431\u0440\u0430\u0443\u0437\u0435\u0440.<br \/>  \u0412 \u0430\u0434\u0440\u0435\u0441\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0435 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u0430 \u043d\u0430\u0431\u0438\u0440\u0430\u0435\u043c: <code>https:\/\/localhost:1111<\/code><br \/>  \u0411\u0440\u0430\u0443\u0437\u0435\u0440 \u043f\u0440\u0435\u0434\u0443\u043f\u0440\u0435\u0434\u0438\u0442 \u043e \u043d\u0435\u0431\u0435\u0437\u043e\u043f\u0430\u0441\u043d\u043e\u043c \u0441\u0435\u0440\u0442\u0438\u0444\u0438\u043a\u0430\u0442\u0435. \u041d\u0443\u0436\u043d\u043e \u043f\u0440\u0438\u043d\u044f\u0442\u044c \u0440\u0438\u0441\u043a. \u041e\u0434\u043d\u0430\u043a\u043e \u043f\u043e\u043a\u0430 \u043c\u044b \u043e\u0431\u0449\u0430\u0435\u043c\u0441\u044f \u0441 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u043e\u043c, \u0441\u0435\u0440\u0432\u0435\u0440 \u043c\u043e\u0436\u0435\u0442 \u043e\u043f\u044f\u0442\u044c \u0437\u0430\u0432\u0435\u0440\u0448\u0438\u0442\u044c\u0441\u044f \u0441 \u043e\u0448\u0438\u0431\u043a\u043e\u0439. \u042d\u0442\u043e \u043d\u043e\u0440\u043c\u0430\u043b\u044c\u043d\u043e, \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u0435 \u0435\u0433\u043e \u0435\u0449\u0435 \u0440\u0430\u0437.<\/p>\n<p>  14. \u0422\u0435\u043f\u0435\u0440\u044c, \u043a\u043e\u0433\u0434\u0430 \u0441\u0435\u0440\u0432\u0435\u0440 \u0437\u0430\u043f\u0443\u0449\u0435\u043d, \u0430 \u0431\u0440\u0430\u0443\u0437\u0435\u0440 \u043f\u043e\u043c\u043d\u0438\u0442 \u0447\u0442\u043e \u043c\u044b \u044d\u0442\u043e\u043c\u0443 \u0441\u0435\u0440\u0432\u0435\u0440\u0443 \u0434\u043e\u0432\u0435\u0440\u044f\u0435\u043c, \u043d\u0430\u0448\u0430 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0430 \u043d\u0430\u043a\u043e\u043d\u0435\u0446 \u043e\u0442\u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u0434\u043e \u043a\u043e\u043d\u0446\u0430 \u0438 \u043f\u0440\u0438\u043c\u0435\u0442 \u043e\u0442 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u0430 \u0431\u0443\u043a\u0432\u0443 \u00abG\u00bb (\u043d\u0430\u0447\u0430\u043b\u043e \u0437\u0430\u043f\u0440\u043e\u0441\u0430 \u00abGET\u00bb), \u043f\u043e \u0437\u0430\u0448\u0438\u0444\u0440\u043e\u0432\u0430\u043d\u043d\u043e\u043c\u0443 \u0441\u043e\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u044e!<\/p>\n<p>  15. \u041d\u0430 \u044d\u0442\u043e\u043c \u043c\u043e\u0436\u043d\u043e \u0431\u044b\u043b\u043e \u0431\u044b \u0437\u0430\u043a\u043e\u043d\u0447\u0438\u0442\u044c, \u043d\u043e \u044f \u0440\u0435\u0448\u0438\u043b \u0434\u043b\u044f \u0447\u0438\u0441\u0442\u043e\u0442\u044b \u044d\u043a\u0441\u043f\u0435\u0440\u0438\u043c\u0435\u043d\u0442\u0430 \u0441\u043a\u043e\u043c\u043f\u0438\u043b\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043f\u043e\u043b\u0443\u0447\u0438\u0432\u0448\u0438\u0439\u0441\u044f \u0444\u0430\u0439\u043b \u043d\u0430 Linux. \u041e\u043a\u0430\u0437\u0430\u043b\u043e\u0441\u044c, \u0447\u0442\u043e \u0438 \u0442\u0443\u0442 \u043d\u0435 \u0431\u0435\u0437 \u0441\u044e\u0440\u043f\u0440\u0438\u0437\u043e\u0432.<br \/>  \u041d\u0430 \u044d\u0442\u0430\u043f\u0435 \u043a\u043e\u043c\u043f\u0438\u043b\u044f\u0446\u0438\u0438 \u043c\u043d\u0435 \u0432\u044b\u0434\u0430\u043b\u0430\u0441\u044c \u043e\u0448\u0438\u0431\u043a\u0430: <br \/>  serv.cpp:51: error: \u2018::main\u2019 must return \u2018int\u2019<\/p>\n<p>  \u0412\u043e\u0442 \u0442\u0430\u043a \u0432\u043e\u0442. \u041e\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u043f\u0440\u0438\u043c\u0435\u0440 \u0438\u0437 \u0438\u0441\u0445\u043e\u0434\u043d\u0438\u043a\u043e\u0432 OpenSSL \u043d\u0435 \u043a\u043e\u043c\u043f\u0438\u043b\u0438\u0440\u0443\u0435\u0442\u0441\u044f \u043d\u0435 \u0442\u043e\u043b\u044c\u043a\u043e \u0432 Windows, \u043d\u043e \u0438 \u0432 Linux.<br \/>  \u041a\u043e\u043d\u0435\u0447\u043d\u043e, \u044f \u0438\u0441\u043f\u0440\u0430\u0432\u0438\u043b \u00abvoid main()\u00bb \u043d\u0430 \u00abint main()\u00bb \u0438 \u0432\u0435\u0437\u0434\u0435 \u0432\u043c\u0435\u0441\u0442\u043e \u00abreturn\u00bb \u043d\u0430\u043f\u0438\u0441\u0430\u043b \u00abreturn 0\u00bb, \u043d\u043e \u043e\u0441\u0430\u0434\u043e\u043a \u043e\u0441\u0442\u0430\u043b\u0441\u044f.<\/p>\n<p>  \u0418 \u0435\u0441\u043b\u0438 \u0432\u0434\u0440\u0443\u0433 \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043d\u043e, \u0442\u043e \u043a\u043e\u043c\u043f\u0438\u043b\u0438\u0440\u0443\u0435\u0442\u0441\u044f \u0432 Linux \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0439 \u0441\u0442\u0440\u043e\u043a\u043e\u0439: \u00abg++ -L\/usr\/lib -lssl -lcrypto serv.cpp\u00bb.<\/p>\n<p>  \u041f\u0421: \u044d\u0442\u043e \u043c\u043e\u0439 \u043f\u0435\u0440\u0432\u044b\u0439 \u043f\u043e\u0441\u0442 \u043d\u0430 \u0445\u0430\u0431\u0440\u0435, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u043f\u0440\u043e\u0448\u0443 \u043f\u0440\u043e\u0449\u0435\u043d\u0438\u044f \u0443 \u0441\u043e\u043e\u0431\u0449\u0435\u0441\u0442\u0432\u0430, \u0435\u0441\u043b\u0438 \u043f\u043e\u043b\u0443\u0447\u0438\u043b\u043e\u0441\u044c \u0434\u043b\u0438\u043d\u043d\u043e \u0438 \u043f\u0443\u0442\u0430\u043d\u043d\u043e. \u041f\u0440\u043e\u0435\u043a\u0442 \u0434\u043b\u044f Visual Studio 2012 \u0434\u043e\u0441\u0442\u0443\u043f\u0435\u043d \u0432 \u0430\u0440\u0445\u0438\u0432\u0435: <a href=\"http:\/\/s0.3s3s.org\">s0.3s3s.org<\/a> \t\t\t<\/p>\n<div class=\"clear\"><\/div>\n<\/p><\/div>\n<p> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"http:\/\/habrahabr.ru\/post\/211474\/\"> http:\/\/habrahabr.ru\/post\/211474\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<div class=\"content html_format\"> \t\t\t\u041d\u0435 \u0442\u0430\u043a \u0434\u0430\u0432\u043d\u043e \u043f\u0435\u0440\u0435\u0434\u043e \u043c\u043d\u043e\u0439 \u0432\u0441\u0442\u0430\u043b\u0430 \u0437\u0430\u0434\u0430\u0447\u0430: \u043d\u0430\u043f\u0438\u0441\u0430\u0442\u044c \u043a\u0440\u043e\u0441\u0441\u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0435\u043d\u043d\u044b\u0439 \u0441\u0435\u0440\u0432\u0435\u0440 \u0434\u043b\u044f \u043e\u0431\u0440\u0430\u0431\u043e\u0442\u043a\u0438 \u0437\u0430\u043f\u0440\u043e\u0441\u043e\u0432 \u043f\u043e \u043f\u0440\u043e\u0442\u043e\u043a\u043e\u043b\u0443 ssl. \u0414\u043e \u044d\u0442\u043e\u0433\u043e \u044f \u043f\u0438\u0441\u0430\u043b \u0441\u0435\u0440\u0432\u0435\u0440\u0430 \u0434\u043b\u044f \u043e\u0431\u044b\u0447\u043d\u044b\u0445, \u043d\u0435 \u0448\u0438\u0444\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0445 \u043f\u0440\u043e\u0442\u043e\u043a\u043e\u043b\u043e\u0432, \u043d\u043e \u0441 ssl \u0441\u0442\u043e\u043b\u043a\u043d\u0443\u043b\u0441\u044f \u0432\u043f\u0435\u0440\u0432\u044b\u0435.<br \/>  \u0411\u0435\u0433\u043b\u044b\u0439 \u043e\u0431\u0437\u043e\u0440 \u0438\u043d\u0442\u0435\u0440\u043d\u0435\u0442\u0430 \u043f\u043e\u043a\u0430\u0437\u0430\u043b, \u0447\u0442\u043e \u043b\u0443\u0447\u0448\u0438\u043c \u0440\u0435\u0448\u0435\u043d\u0438\u0435\u043c \u0431\u0443\u0434\u0435\u0442 \u043d\u0435 \u0432\u0435\u043b\u043e\u0441\u0438\u043f\u0435\u0434\u043e\u0441\u0442\u0440\u043e\u0435\u043d\u0438\u0435, \u0430 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 OpenSSL.<br \/>  \u0412 \u044d\u0442\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0435 \u044f \u043d\u0435 \u0445\u043e\u0447\u0443 \u0440\u0430\u0441\u0441\u043c\u0430\u0442\u0440\u0438\u0432\u0430\u0442\u044c \u043f\u0440\u043e\u0446\u0435\u0441\u0441 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438 OpenSSL \u043d\u0430 Linux \u0438 Windows, \u0437\u0430\u043c\u0435\u0447\u0443 \u043b\u0438\u0448\u044c, \u0447\u0442\u043e \u0434\u043b\u044f Windows \u043f\u0440\u043e\u0446\u0435\u0441\u0441 \u044d\u0442\u043e\u0442 \u043e\u043a\u0430\u0437\u0430\u043b\u0441\u044f \u043d\u0435\u0442\u0440\u0438\u0432\u0438\u0430\u043b\u044c\u043d\u044b\u043c. \u0410 \u0440\u0430\u0441\u0441\u043a\u0430\u0437\u0430\u0442\u044c \u044f \u0445\u043e\u0447\u0443 \u043e \u0442\u043e\u043c, \u043a\u0430\u043a \u043c\u043d\u0435 \u0443\u0434\u0430\u043b\u043e\u0441\u044c \u0441\u043a\u043e\u043c\u043f\u0438\u043b\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0432 Visual Studio \u043f\u0440\u0438\u043c\u0435\u0440 \u043f\u0440\u043e\u0441\u0442\u0435\u0439\u0448\u0435\u0433\u043e \u0441\u0435\u0440\u0432\u0435\u0440\u0430, \u0432\u0445\u043e\u0434\u044f\u0449\u0438\u0439 \u0432 \u0441\u043e\u0441\u0442\u0430\u0432 \u0438\u0441\u0445\u043e\u0434\u043d\u0438\u043a\u043e\u0432 OpenSSL.<br \/>  \u041d\u0435\u0438\u0441\u043a\u0443\u0448\u0435\u043d\u043d\u043e\u043c\u0443 \u0447\u0438\u0442\u0430\u0442\u0435\u043b\u044e \u043c\u043e\u0436\u0435\u0442 \u043f\u043e\u043a\u0430\u0437\u0430\u0442\u044c\u0441\u044f: \u00ab\u0447\u0442\u043e \u0442\u0443\u0442 \u043e\u0441\u043e\u0431\u0435\u043d\u043d\u043e\u0433\u043e \u2014 \u0441\u043e\u0437\u0434\u0430\u043b \u043f\u0440\u043e\u0435\u043a\u0442, \u0432\u043a\u043b\u044e\u0447\u0438\u043b \u0432 \u043d\u0435\u0433\u043e \u0433\u043e\u0442\u043e\u0432\u044b\u0439 \u0438\u0441\u0445\u043e\u0434\u043d\u0438\u043a, \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u043b\u00bb\u2026 \u041e\u0434\u043d\u0430\u043a\u043e \u043e\u0431\u043e \u0432\u0441\u0435\u043c \u043f\u043e \u043f\u043e\u0440\u044f\u0434\u043a\u0443.<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-211474","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/211474","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=211474"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/211474\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=211474"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=211474"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=211474"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}