mirror of
https://github.com/XRPLF/rippled.git
synced 2026-01-09 01:05:26 +00:00
326 lines
60 KiB
HTML
326 lines
60 KiB
HTML
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
|
<head>
|
|
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
|
|
<meta name="generator" content="Doxygen 1.8.17"/>
|
|
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
|
<title>rippled: InboundHandoff.cpp Source File</title>
|
|
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
|
<script type="text/javascript" src="jquery.js"></script>
|
|
<script type="text/javascript" src="dynsections.js"></script>
|
|
<link href="search/search.css" rel="stylesheet" type="text/css"/>
|
|
<script type="text/javascript" src="search/searchdata.js"></script>
|
|
<script type="text/javascript" src="search/search.js"></script>
|
|
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
|
</head>
|
|
<body>
|
|
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
|
|
<div id="titlearea">
|
|
<table cellspacing="0" cellpadding="0">
|
|
<tbody>
|
|
<tr style="height: 56px;">
|
|
<td id="projectalign" style="padding-left: 0.5em;">
|
|
<div id="projectname">rippled
|
|
</div>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
<!-- end header part -->
|
|
<!-- Generated by Doxygen 1.8.17 -->
|
|
<script type="text/javascript">
|
|
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
var searchBox = new SearchBox("searchBox", "search",false,'Search');
|
|
/* @license-end */
|
|
</script>
|
|
<script type="text/javascript" src="menudata.js"></script>
|
|
<script type="text/javascript" src="menu.js"></script>
|
|
<script type="text/javascript">
|
|
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
$(function() {
|
|
initMenu('',true,false,'search.php','Search');
|
|
$(document).ready(function() { init_search(); });
|
|
});
|
|
/* @license-end */</script>
|
|
<div id="main-nav"></div>
|
|
<!-- window showing the filter options -->
|
|
<div id="MSearchSelectWindow"
|
|
onmouseover="return searchBox.OnSearchSelectShow()"
|
|
onmouseout="return searchBox.OnSearchSelectHide()"
|
|
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
|
</div>
|
|
|
|
<!-- iframe showing the search results (closed by default) -->
|
|
<div id="MSearchResultsWindow">
|
|
<iframe src="javascript:void(0)" frameborder="0"
|
|
name="MSearchResults" id="MSearchResults">
|
|
</iframe>
|
|
</div>
|
|
|
|
<div id="nav-path" class="navpath">
|
|
<ul>
|
|
<li class="navelem"><a class="el" href="dir_df9c78dcf3f59a33b12284f95992a64b.html">ripple</a></li><li class="navelem"><a class="el" href="dir_b003f5a72efe503c7552f86021e0c4d2.html">overlay</a></li><li class="navelem"><a class="el" href="dir_3d31096116cb07f2d03f31d101bf2478.html">impl</a></li> </ul>
|
|
</div>
|
|
</div><!-- top -->
|
|
<div class="header">
|
|
<div class="headertitle">
|
|
<div class="title">InboundHandoff.cpp</div> </div>
|
|
</div><!--header-->
|
|
<div class="contents">
|
|
<div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno"> 1</span> <span class="comment">//------------------------------------------------------------------------------</span></div>
|
|
<div class="line"><a name="l00002"></a><span class="lineno"> 2</span> <span class="comment">/*</span></div>
|
|
<div class="line"><a name="l00003"></a><span class="lineno"> 3</span> <span class="comment"> This file is part of rippled: https://github.com/ripple/rippled</span></div>
|
|
<div class="line"><a name="l00004"></a><span class="lineno"> 4</span> <span class="comment"> Copyright (c) 2012-2021 Ripple Labs Inc.</span></div>
|
|
<div class="line"><a name="l00005"></a><span class="lineno"> 5</span> <span class="comment"></span> </div>
|
|
<div class="line"><a name="l00006"></a><span class="lineno"> 6</span> <span class="comment"> Permission to use, copy, modify, and/or distribute this software for any</span></div>
|
|
<div class="line"><a name="l00007"></a><span class="lineno"> 7</span> <span class="comment"> purpose with or without fee is hereby granted, provided that the above</span></div>
|
|
<div class="line"><a name="l00008"></a><span class="lineno"> 8</span> <span class="comment"> copyright notice and this permission notice appear in all copies.</span></div>
|
|
<div class="line"><a name="l00009"></a><span class="lineno"> 9</span> <span class="comment"></span> </div>
|
|
<div class="line"><a name="l00010"></a><span class="lineno"> 10</span> <span class="comment"> THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES</span></div>
|
|
<div class="line"><a name="l00011"></a><span class="lineno"> 11</span> <span class="comment"> WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF</span></div>
|
|
<div class="line"><a name="l00012"></a><span class="lineno"> 12</span> <span class="comment"> MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR</span></div>
|
|
<div class="line"><a name="l00013"></a><span class="lineno"> 13</span> <span class="comment"> ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES</span></div>
|
|
<div class="line"><a name="l00014"></a><span class="lineno"> 14</span> <span class="comment"> WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN</span></div>
|
|
<div class="line"><a name="l00015"></a><span class="lineno"> 15</span> <span class="comment"> ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF</span></div>
|
|
<div class="line"><a name="l00016"></a><span class="lineno"> 16</span> <span class="comment"> OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.</span></div>
|
|
<div class="line"><a name="l00017"></a><span class="lineno"> 17</span> <span class="comment">*/</span></div>
|
|
<div class="line"><a name="l00018"></a><span class="lineno"> 18</span> <span class="comment">//==============================================================================</span></div>
|
|
<div class="line"><a name="l00019"></a><span class="lineno"> 19</span>  </div>
|
|
<div class="line"><a name="l00020"></a><span class="lineno"> 20</span> <span class="preprocessor">#include <ripple/overlay/Cluster.h></span></div>
|
|
<div class="line"><a name="l00021"></a><span class="lineno"> 21</span> <span class="preprocessor">#include <ripple/overlay/impl/InboundHandoff.h></span></div>
|
|
<div class="line"><a name="l00022"></a><span class="lineno"> 22</span> <span class="preprocessor">#include <ripple/overlay/impl/PeerImp.h></span></div>
|
|
<div class="line"><a name="l00023"></a><span class="lineno"> 23</span>  </div>
|
|
<div class="line"><a name="l00024"></a><span class="lineno"> 24</span> <span class="preprocessor">#include <boost/beast/core/ostream.hpp></span></div>
|
|
<div class="line"><a name="l00025"></a><span class="lineno"> 25</span>  </div>
|
|
<div class="line"><a name="l00026"></a><span class="lineno"> 26</span> <span class="keyword">namespace </span><a class="code" href="namespaceripple.html">ripple</a> {</div>
|
|
<div class="line"><a name="l00027"></a><span class="lineno"> 27</span>  </div>
|
|
<div class="line"><a name="l00028"></a><span class="lineno"><a class="line" href="classripple_1_1InboundHandoff.html#af05ac16ad93e49c8333d3b3bce1df38b"> 28</a></span> <a class="code" href="classripple_1_1InboundHandoff.html#af05ac16ad93e49c8333d3b3bce1df38b">InboundHandoff::InboundHandoff</a>(</div>
|
|
<div class="line"><a name="l00029"></a><span class="lineno"> 29</span>  <a class="code" href="classripple_1_1Application.html">Application</a>& app,</div>
|
|
<div class="line"><a name="l00030"></a><span class="lineno"> 30</span>  <a class="codeRef" href="http://en.cppreference.com/w/cpp/types/integer.html">id_t</a> <span class="keywordtype">id</span>,</div>
|
|
<div class="line"><a name="l00031"></a><span class="lineno"> 31</span>  <a class="codeRef" href="http://en.cppreference.com/w/cpp/memory/shared_ptr.html">std::shared_ptr<PeerFinder::Slot></a> <span class="keyword">const</span>& slot,</div>
|
|
<div class="line"><a name="l00032"></a><span class="lineno"> 32</span>  <a class="code" href="namespaceripple.html#aa265217edeb8282e636c78b50049f4c0">http_request_type</a>&& request,</div>
|
|
<div class="line"><a name="l00033"></a><span class="lineno"> 33</span>  <a class="code" href="classripple_1_1PublicKey.html">PublicKey</a> <span class="keyword">const</span>& publicKey,</div>
|
|
<div class="line"><a name="l00034"></a><span class="lineno"> 34</span>  <a class="codeRef" href="http://en.cppreference.com/w/cpp/utility/pair.html">ProtocolVersion</a> <a class="code" href="namespaceprotocol.html">protocol</a>,</div>
|
|
<div class="line"><a name="l00035"></a><span class="lineno"> 35</span>  <a class="code" href="classripple_1_1Resource_1_1Consumer.html">Resource::Consumer</a> consumer,</div>
|
|
<div class="line"><a name="l00036"></a><span class="lineno"> 36</span>  <a class="codeRef" href="http://en.cppreference.com/w/cpp/memory/unique_ptr.html">std::unique_ptr<stream_type></a>&& stream_ptr,</div>
|
|
<div class="line"><a name="l00037"></a><span class="lineno"> 37</span>  <a class="code" href="classripple_1_1OverlayImpl.html">OverlayImpl</a>& overlay)</div>
|
|
<div class="line"><a name="l00038"></a><span class="lineno"> 38</span>  : <a class="code" href="classripple_1_1OverlayImpl.html">OverlayImpl</a>::Child(overlay)</div>
|
|
<div class="line"><a name="l00039"></a><span class="lineno"> 39</span>  , app_(app)</div>
|
|
<div class="line"><a name="l00040"></a><span class="lineno"> 40</span>  , id_(id)</div>
|
|
<div class="line"><a name="l00041"></a><span class="lineno"> 41</span>  , sink_(</div>
|
|
<div class="line"><a name="l00042"></a><span class="lineno"> 42</span>  app_.journal(<span class="stringliteral">"Peer"</span>),</div>
|
|
<div class="line"><a name="l00043"></a><span class="lineno"> 43</span>  [id]() {</div>
|
|
<div class="line"><a name="l00044"></a><span class="lineno"> 44</span>  <a class="codeRef" href="http://en.cppreference.com/w/cpp/io/basic_stringstream.html">std::stringstream</a> ss;</div>
|
|
<div class="line"><a name="l00045"></a><span class="lineno"> 45</span>  ss << <span class="stringliteral">"["</span> << <a class="codeRef" href="http://en.cppreference.com/w/cpp/io/manip/setfill.html">std::setfill</a>(<span class="charliteral">'0'</span>) << <a class="codeRef" href="http://en.cppreference.com/w/cpp/io/manip/setw.html">std::setw</a>(3) << <span class="keywordtype">id</span> << <span class="stringliteral">"] "</span>;</div>
|
|
<div class="line"><a name="l00046"></a><span class="lineno"> 46</span>  <span class="keywordflow">return</span> ss.<a class="codeRef" href="http://en.cppreference.com/w/cpp/io/basic_stringstream/str.html">str</a>();</div>
|
|
<div class="line"><a name="l00047"></a><span class="lineno"> 47</span>  }())</div>
|
|
<div class="line"><a name="l00048"></a><span class="lineno"> 48</span>  , journal_(sink_)</div>
|
|
<div class="line"><a name="l00049"></a><span class="lineno"> 49</span>  , stream_ptr_(std::move(stream_ptr))</div>
|
|
<div class="line"><a name="l00050"></a><span class="lineno"> 50</span>  , strand_(stream_ptr_->next_layer().socket().get_executor())</div>
|
|
<div class="line"><a name="l00051"></a><span class="lineno"> 51</span>  , remote_address_(slot->remote_endpoint())</div>
|
|
<div class="line"><a name="l00052"></a><span class="lineno"> 52</span>  , protocol_(<a class="code" href="namespaceprotocol.html">protocol</a>)</div>
|
|
<div class="line"><a name="l00053"></a><span class="lineno"> 53</span>  , publicKey_(publicKey)</div>
|
|
<div class="line"><a name="l00054"></a><span class="lineno"> 54</span>  , usage_(consumer)</div>
|
|
<div class="line"><a name="l00055"></a><span class="lineno"> 55</span>  , slot_(slot)</div>
|
|
<div class="line"><a name="l00056"></a><span class="lineno"> 56</span>  , request_(std::move(request))</div>
|
|
<div class="line"><a name="l00057"></a><span class="lineno"> 57</span> {</div>
|
|
<div class="line"><a name="l00058"></a><span class="lineno"> 58</span> }</div>
|
|
<div class="line"><a name="l00059"></a><span class="lineno"> 59</span>  </div>
|
|
<div class="line"><a name="l00060"></a><span class="lineno"> 60</span> <span class="keywordtype">void</span></div>
|
|
<div class="line"><a name="l00061"></a><span class="lineno"><a class="line" href="classripple_1_1InboundHandoff.html#a04fda047eeb6627c396ad77ab180846f"> 61</a></span> <a class="code" href="classripple_1_1InboundHandoff.html#a04fda047eeb6627c396ad77ab180846f">InboundHandoff::run</a>()</div>
|
|
<div class="line"><a name="l00062"></a><span class="lineno"> 62</span> {</div>
|
|
<div class="line"><a name="l00063"></a><span class="lineno"> 63</span>  <span class="keywordflow">if</span> (!<a class="code" href="classripple_1_1InboundHandoff.html#a032a30416289de654b7397f055c907b8">strand_</a>.running_in_this_thread())</div>
|
|
<div class="line"><a name="l00064"></a><span class="lineno"> 64</span>  <span class="keywordflow">return</span> post(</div>
|
|
<div class="line"><a name="l00065"></a><span class="lineno"> 65</span>  <a class="code" href="classripple_1_1InboundHandoff.html#a032a30416289de654b7397f055c907b8">strand_</a>, <a class="codeRef" href="http://en.cppreference.com/w/cpp/utility/functional/bind.html">std::bind</a>(&<a class="code" href="classripple_1_1InboundHandoff.html#a04fda047eeb6627c396ad77ab180846f">InboundHandoff::run</a>, <a class="codeRef" href="http://en.cppreference.com/w/cpp/memory/enable_shared_from_this/shared_from_this.html">shared_from_this</a>()));</div>
|
|
<div class="line"><a name="l00066"></a><span class="lineno"> 66</span>  <a class="code" href="classripple_1_1InboundHandoff.html#aff4d57307082663fd45b1208bf3df33d">sendResponse</a>();</div>
|
|
<div class="line"><a name="l00067"></a><span class="lineno"> 67</span> }</div>
|
|
<div class="line"><a name="l00068"></a><span class="lineno"> 68</span>  </div>
|
|
<div class="line"><a name="l00069"></a><span class="lineno"> 69</span> <span class="keywordtype">void</span></div>
|
|
<div class="line"><a name="l00070"></a><span class="lineno"><a class="line" href="classripple_1_1InboundHandoff.html#a36e56c6447cf4f81a1213c5febd805cd"> 70</a></span> <a class="code" href="classripple_1_1InboundHandoff.html#a36e56c6447cf4f81a1213c5febd805cd">InboundHandoff::stop</a>()</div>
|
|
<div class="line"><a name="l00071"></a><span class="lineno"> 71</span> {</div>
|
|
<div class="line"><a name="l00072"></a><span class="lineno"> 72</span>  <span class="keywordflow">if</span> (!<a class="code" href="classripple_1_1InboundHandoff.html#a032a30416289de654b7397f055c907b8">strand_</a>.running_in_this_thread())</div>
|
|
<div class="line"><a name="l00073"></a><span class="lineno"> 73</span>  <span class="keywordflow">return</span> post(</div>
|
|
<div class="line"><a name="l00074"></a><span class="lineno"> 74</span>  <a class="code" href="classripple_1_1InboundHandoff.html#a032a30416289de654b7397f055c907b8">strand_</a>, <a class="codeRef" href="http://en.cppreference.com/w/cpp/utility/functional/bind.html">std::bind</a>(&<a class="code" href="classripple_1_1InboundHandoff.html#a36e56c6447cf4f81a1213c5febd805cd">InboundHandoff::stop</a>, <a class="codeRef" href="http://en.cppreference.com/w/cpp/memory/enable_shared_from_this/shared_from_this.html">shared_from_this</a>()));</div>
|
|
<div class="line"><a name="l00075"></a><span class="lineno"> 75</span>  <span class="keywordflow">if</span> (<a class="code" href="classripple_1_1InboundHandoff.html#a8d945de6a9f007235f2b34df227e1197">stream_ptr_</a>->next_layer().socket().is_open())</div>
|
|
<div class="line"><a name="l00076"></a><span class="lineno"> 76</span>  {</div>
|
|
<div class="line"><a name="l00077"></a><span class="lineno"> 77</span>  JLOG(<a class="code" href="classripple_1_1InboundHandoff.html#ae99f1d3369b5fdff937cb595d7b26248">journal_</a>.<a class="code" href="classbeast_1_1Journal.html#a556228cb60bcf405c225d3f64b7b01ae">debug</a>()) << <span class="stringliteral">"Stop"</span>;</div>
|
|
<div class="line"><a name="l00078"></a><span class="lineno"> 78</span>  }</div>
|
|
<div class="line"><a name="l00079"></a><span class="lineno"> 79</span>  <a class="code" href="classripple_1_1InboundHandoff.html#ac2bdbcd06ae6ca4756ec6c17b79330d2">close</a>();</div>
|
|
<div class="line"><a name="l00080"></a><span class="lineno"> 80</span> }</div>
|
|
<div class="line"><a name="l00081"></a><span class="lineno"> 81</span>  </div>
|
|
<div class="line"><a name="l00082"></a><span class="lineno"> 82</span> <span class="keywordtype">void</span></div>
|
|
<div class="line"><a name="l00083"></a><span class="lineno"><a class="line" href="classripple_1_1InboundHandoff.html#aff4d57307082663fd45b1208bf3df33d"> 83</a></span> <a class="code" href="classripple_1_1InboundHandoff.html#aff4d57307082663fd45b1208bf3df33d">InboundHandoff::sendResponse</a>()</div>
|
|
<div class="line"><a name="l00084"></a><span class="lineno"> 84</span> {</div>
|
|
<div class="line"><a name="l00085"></a><span class="lineno"> 85</span>  <span class="keyword">auto</span> <span class="keyword">const</span> sharedValue = <a class="code" href="namespaceripple.html#a7241d07322a0d8fa2e2effedd739a90f">makeSharedValue</a>(*<a class="code" href="classripple_1_1InboundHandoff.html#a8d945de6a9f007235f2b34df227e1197">stream_ptr_</a>, <a class="code" href="classripple_1_1InboundHandoff.html#ae99f1d3369b5fdff937cb595d7b26248">journal_</a>);</div>
|
|
<div class="line"><a name="l00086"></a><span class="lineno"> 86</span>  <span class="comment">// This shouldn't fail since we already computed</span></div>
|
|
<div class="line"><a name="l00087"></a><span class="lineno"> 87</span>  <span class="comment">// the shared value successfully in OverlayImpl</span></div>
|
|
<div class="line"><a name="l00088"></a><span class="lineno"> 88</span>  <span class="keywordflow">if</span> (!sharedValue)</div>
|
|
<div class="line"><a name="l00089"></a><span class="lineno"> 89</span>  <span class="keywordflow">return</span> <a class="code" href="classripple_1_1InboundHandoff.html#a4b7af86bdc8596c82cc1e1e3b4287adb">fail</a>(<span class="stringliteral">"makeSharedValue: Unexpected failure"</span>);</div>
|
|
<div class="line"><a name="l00090"></a><span class="lineno"> 90</span>  </div>
|
|
<div class="line"><a name="l00091"></a><span class="lineno"> 91</span>  JLOG(<a class="code" href="classripple_1_1InboundHandoff.html#ae99f1d3369b5fdff937cb595d7b26248">journal_</a>.<a class="code" href="classbeast_1_1Journal.html#a87d6bd59020d94110027dcab3d9e3357">info</a>()) << <span class="stringliteral">"Protocol: "</span> << <a class="code" href="namespaceripple.html#af9776f187d3686a7fba4c2d2fbeebdf4">to_string</a>(<a class="code" href="classripple_1_1InboundHandoff.html#af13b1a1108fb0a0c7afe3f6761af3a6a">protocol_</a>);</div>
|
|
<div class="line"><a name="l00092"></a><span class="lineno"> 92</span>  JLOG(<a class="code" href="classripple_1_1InboundHandoff.html#ae99f1d3369b5fdff937cb595d7b26248">journal_</a>.<a class="code" href="classbeast_1_1Journal.html#a87d6bd59020d94110027dcab3d9e3357">info</a>()) << <span class="stringliteral">"Public Key: "</span></div>
|
|
<div class="line"><a name="l00093"></a><span class="lineno"> 93</span>  << <a class="code" href="namespaceripple.html#a08a13b62b18272366f788632359e8793">toBase58</a>(<a class="code" href="namespaceripple.html#a1bf8df553d36589191c8057c136cce03ac3fe5edb1f8a81a8e585f6a27c120be6">TokenType::NodePublic</a>, <a class="code" href="classripple_1_1InboundHandoff.html#adee668c2d899437959e072a0b6d0b702">publicKey_</a>);</div>
|
|
<div class="line"><a name="l00094"></a><span class="lineno"> 94</span>  </div>
|
|
<div class="line"><a name="l00095"></a><span class="lineno"> 95</span>  <span class="keyword">auto</span> write_buffer = std::make_shared<boost::beast::multi_buffer>();</div>
|
|
<div class="line"><a name="l00096"></a><span class="lineno"> 96</span>  </div>
|
|
<div class="line"><a name="l00097"></a><span class="lineno"> 97</span>  boost::beast::ostream(*write_buffer) << <a class="code" href="namespaceripple.html#a5590ae6006b178275628bde91fa03129">makeResponse</a>(</div>
|
|
<div class="line"><a name="l00098"></a><span class="lineno"> 98</span>  !<a class="code" href="classripple_1_1OverlayImpl_1_1Child.html#ac48a68b0e553ec566f03e3f7d538beec">overlay_</a>.<a class="code" href="classripple_1_1OverlayImpl.html#af79b454c807a1a1ed55ddfb56ba9cf09">peerFinder</a>().<a class="code" href="classripple_1_1PeerFinder_1_1Manager.html#a7b106eb8bb9983a45b86a3685875d5ca">config</a>().<a class="code" href="structripple_1_1PeerFinder_1_1Config.html#af9b3a48e05361caa57d3e0c09e37a166">peerPrivate</a>,</div>
|
|
<div class="line"><a name="l00099"></a><span class="lineno"> 99</span>  <a class="code" href="classripple_1_1InboundHandoff.html#ad10d9fda32f4a5b890d98832d04b3985">request_</a>,</div>
|
|
<div class="line"><a name="l00100"></a><span class="lineno"> 100</span>  <a class="code" href="classripple_1_1OverlayImpl_1_1Child.html#ac48a68b0e553ec566f03e3f7d538beec">overlay_</a>.<a class="code" href="classripple_1_1OverlayImpl.html#a55c2ef9cc5b0abfbd143b1feea4f3c4b">setup</a>().public_ip,</div>
|
|
<div class="line"><a name="l00101"></a><span class="lineno"> 101</span>  <a class="code" href="classripple_1_1InboundHandoff.html#af983687f55a7a71dbc108bfa0ff2067c">remote_address_</a>.<a class="code" href="classbeast_1_1IP_1_1Endpoint.html#a63fa66c4eb0d68359a0ff642891493c5">address</a>(),</div>
|
|
<div class="line"><a name="l00102"></a><span class="lineno"> 102</span>  *sharedValue,</div>
|
|
<div class="line"><a name="l00103"></a><span class="lineno"> 103</span>  <a class="code" href="classripple_1_1OverlayImpl_1_1Child.html#ac48a68b0e553ec566f03e3f7d538beec">overlay_</a>.<a class="code" href="classripple_1_1OverlayImpl.html#a55c2ef9cc5b0abfbd143b1feea4f3c4b">setup</a>().networkID,</div>
|
|
<div class="line"><a name="l00104"></a><span class="lineno"> 104</span>  <a class="code" href="classripple_1_1InboundHandoff.html#af13b1a1108fb0a0c7afe3f6761af3a6a">protocol_</a>,</div>
|
|
<div class="line"><a name="l00105"></a><span class="lineno"> 105</span>  <a class="code" href="classripple_1_1InboundHandoff.html#a83c180bd8d3162807bd97d458f1b3ea2">app_</a>);</div>
|
|
<div class="line"><a name="l00106"></a><span class="lineno"> 106</span>  </div>
|
|
<div class="line"><a name="l00107"></a><span class="lineno"> 107</span>  <span class="comment">// Write the whole buffer and only start protocol when that's done.</span></div>
|
|
<div class="line"><a name="l00108"></a><span class="lineno"> 108</span>  boost::asio::async_write(</div>
|
|
<div class="line"><a name="l00109"></a><span class="lineno"> 109</span>  *<a class="code" href="classripple_1_1InboundHandoff.html#a8d945de6a9f007235f2b34df227e1197">stream_ptr_</a>,</div>
|
|
<div class="line"><a name="l00110"></a><span class="lineno"> 110</span>  write_buffer->data(),</div>
|
|
<div class="line"><a name="l00111"></a><span class="lineno"> 111</span>  boost::asio::transfer_all(),</div>
|
|
<div class="line"><a name="l00112"></a><span class="lineno"> 112</span>  bind_executor(</div>
|
|
<div class="line"><a name="l00113"></a><span class="lineno"> 113</span>  <a class="code" href="classripple_1_1InboundHandoff.html#a032a30416289de654b7397f055c907b8">strand_</a>,</div>
|
|
<div class="line"><a name="l00114"></a><span class="lineno"> 114</span>  [<span class="keyword">this</span>, write_buffer, <span class="keyword">self</span> = <a class="codeRef" href="http://en.cppreference.com/w/cpp/memory/enable_shared_from_this/shared_from_this.html">shared_from_this</a>()](</div>
|
|
<div class="line"><a name="l00115"></a><span class="lineno"> 115</span>  <a class="code" href="classripple_1_1InboundHandoff.html#a848d68ac2f49700c6865ec93fafcf093">error_code</a> ec, <a class="codeRef" href="http://en.cppreference.com/w/cpp/types/size_t.html">std::size_t</a> bytes_transferred) {</div>
|
|
<div class="line"><a name="l00116"></a><span class="lineno"> 116</span>  <span class="keywordflow">if</span> (!<a class="code" href="classripple_1_1InboundHandoff.html#a8d945de6a9f007235f2b34df227e1197">stream_ptr_</a>->next_layer().socket().is_open())</div>
|
|
<div class="line"><a name="l00117"></a><span class="lineno"> 117</span>  <span class="keywordflow">return</span>;</div>
|
|
<div class="line"><a name="l00118"></a><span class="lineno"> 118</span>  if (ec == boost::asio::error::operation_aborted)</div>
|
|
<div class="line"><a name="l00119"></a><span class="lineno"> 119</span>  <span class="keywordflow">return</span>;</div>
|
|
<div class="line"><a name="l00120"></a><span class="lineno"> 120</span>  <span class="keywordflow">if</span> (ec)</div>
|
|
<div class="line"><a name="l00121"></a><span class="lineno"> 121</span>  <span class="keywordflow">return</span> <a class="code" href="classripple_1_1InboundHandoff.html#a4b7af86bdc8596c82cc1e1e3b4287adb">fail</a>(<span class="stringliteral">"onWriteResponse"</span>, ec);</div>
|
|
<div class="line"><a name="l00122"></a><span class="lineno"> 122</span>  <span class="keywordflow">if</span> (write_buffer->size() == bytes_transferred)</div>
|
|
<div class="line"><a name="l00123"></a><span class="lineno"> 123</span>  <span class="keywordflow">return</span> <a class="code" href="classripple_1_1InboundHandoff.html#a8d77c3bcda69bb5b52d43a984279e5e5">createPeer</a>();</div>
|
|
<div class="line"><a name="l00124"></a><span class="lineno"> 124</span>  <span class="keywordflow">return</span> <a class="code" href="classripple_1_1InboundHandoff.html#a4b7af86bdc8596c82cc1e1e3b4287adb">fail</a>(<span class="stringliteral">"Failed to write header"</span>);</div>
|
|
<div class="line"><a name="l00125"></a><span class="lineno"> 125</span>  }));</div>
|
|
<div class="line"><a name="l00126"></a><span class="lineno"> 126</span> }</div>
|
|
<div class="line"><a name="l00127"></a><span class="lineno"> 127</span>  </div>
|
|
<div class="line"><a name="l00128"></a><span class="lineno"> 128</span> <span class="keywordtype">void</span></div>
|
|
<div class="line"><a name="l00129"></a><span class="lineno"><a class="line" href="classripple_1_1InboundHandoff.html#a4b7af86bdc8596c82cc1e1e3b4287adb"> 129</a></span> <a class="code" href="classripple_1_1InboundHandoff.html#a4b7af86bdc8596c82cc1e1e3b4287adb">InboundHandoff::fail</a>(<a class="codeRef" href="http://en.cppreference.com/w/cpp/string/basic_string.html">std::string</a> <span class="keyword">const</span>& name, <a class="code" href="classripple_1_1InboundHandoff.html#a848d68ac2f49700c6865ec93fafcf093">error_code</a> <span class="keyword">const</span>& ec)</div>
|
|
<div class="line"><a name="l00130"></a><span class="lineno"> 130</span> {</div>
|
|
<div class="line"><a name="l00131"></a><span class="lineno"> 131</span>  <span class="keywordflow">if</span> (<a class="code" href="classripple_1_1InboundHandoff.html#a2908a03ab47269d428605b011365ee7b">socket</a>().is_open())</div>
|
|
<div class="line"><a name="l00132"></a><span class="lineno"> 132</span>  {</div>
|
|
<div class="line"><a name="l00133"></a><span class="lineno"> 133</span>  JLOG(<a class="code" href="classripple_1_1InboundHandoff.html#ae99f1d3369b5fdff937cb595d7b26248">journal_</a>.<a class="code" href="classbeast_1_1Journal.html#ad8fefe3e8ad583e1ed1bf02094ac3d8f">warn</a>())</div>
|
|
<div class="line"><a name="l00134"></a><span class="lineno"> 134</span>  << name << <span class="stringliteral">" from "</span> << <a class="code" href="namespaceripple.html#a08a13b62b18272366f788632359e8793">toBase58</a>(<a class="code" href="namespaceripple.html#a1bf8df553d36589191c8057c136cce03ac3fe5edb1f8a81a8e585f6a27c120be6">TokenType::NodePublic</a>, <a class="code" href="classripple_1_1InboundHandoff.html#adee668c2d899437959e072a0b6d0b702">publicKey_</a>)</div>
|
|
<div class="line"><a name="l00135"></a><span class="lineno"> 135</span>  << <span class="stringliteral">" at "</span> << <a class="code" href="classripple_1_1InboundHandoff.html#af983687f55a7a71dbc108bfa0ff2067c">remote_address_</a>.<a class="code" href="classbeast_1_1IP_1_1Endpoint.html#adcbd20a3d8d1d3f7c6a3ae541f519fb4">to_string</a>() << <span class="stringliteral">": "</span> << ec.message();</div>
|
|
<div class="line"><a name="l00136"></a><span class="lineno"> 136</span>  }</div>
|
|
<div class="line"><a name="l00137"></a><span class="lineno"> 137</span>  <a class="code" href="classripple_1_1InboundHandoff.html#ac2bdbcd06ae6ca4756ec6c17b79330d2">close</a>();</div>
|
|
<div class="line"><a name="l00138"></a><span class="lineno"> 138</span> }</div>
|
|
<div class="line"><a name="l00139"></a><span class="lineno"> 139</span>  </div>
|
|
<div class="line"><a name="l00140"></a><span class="lineno"> 140</span> <span class="keywordtype">void</span></div>
|
|
<div class="line"><a name="l00141"></a><span class="lineno"><a class="line" href="classripple_1_1InboundHandoff.html#a2e01a0a7706f56abc994747360fe95e8"> 141</a></span> <a class="code" href="classripple_1_1InboundHandoff.html#a4b7af86bdc8596c82cc1e1e3b4287adb">InboundHandoff::fail</a>(<a class="codeRef" href="http://en.cppreference.com/w/cpp/string/basic_string.html">std::string</a> <span class="keyword">const</span>& reason)</div>
|
|
<div class="line"><a name="l00142"></a><span class="lineno"> 142</span> {</div>
|
|
<div class="line"><a name="l00143"></a><span class="lineno"> 143</span>  <span class="keywordflow">if</span> (<a class="code" href="classripple_1_1InboundHandoff.html#ae99f1d3369b5fdff937cb595d7b26248">journal_</a>.<a class="code" href="classbeast_1_1Journal.html#a5929f5a6c995e2c2c5aada222ee470c4">active</a>(<a class="code" href="namespacebeast_1_1severities.html#a069a8a312b9123b77f6aa31733ca73beab6ef7006e42e82dcc97478e4e362f883">beast::severities::kWarning</a>) && <a class="code" href="classripple_1_1InboundHandoff.html#a2908a03ab47269d428605b011365ee7b">socket</a>().is_open())</div>
|
|
<div class="line"><a name="l00144"></a><span class="lineno"> 144</span>  {</div>
|
|
<div class="line"><a name="l00145"></a><span class="lineno"> 145</span>  <span class="keyword">auto</span> <span class="keyword">const</span> n = <a class="code" href="classripple_1_1InboundHandoff.html#a83c180bd8d3162807bd97d458f1b3ea2">app_</a>.<a class="code" href="classripple_1_1Application.html#a296fbab181bda48bf599996518228bf9">cluster</a>().<a class="code" href="classripple_1_1Cluster.html#adffcdc10e28e4fa6f3e9b9c5f4bb3afa">member</a>(<a class="code" href="classripple_1_1InboundHandoff.html#adee668c2d899437959e072a0b6d0b702">publicKey_</a>);</div>
|
|
<div class="line"><a name="l00146"></a><span class="lineno"> 146</span>  JLOG(<a class="code" href="classripple_1_1InboundHandoff.html#ae99f1d3369b5fdff937cb595d7b26248">journal_</a>.<a class="code" href="classbeast_1_1Journal.html#ad8fefe3e8ad583e1ed1bf02094ac3d8f">warn</a>())</div>
|
|
<div class="line"><a name="l00147"></a><span class="lineno"> 147</span>  << (n ? <a class="code" href="classripple_1_1InboundHandoff.html#af983687f55a7a71dbc108bfa0ff2067c">remote_address_</a>.<a class="code" href="classbeast_1_1IP_1_1Endpoint.html#adcbd20a3d8d1d3f7c6a3ae541f519fb4">to_string</a>() : *n) << <span class="stringliteral">" failed: "</span> << reason;</div>
|
|
<div class="line"><a name="l00148"></a><span class="lineno"> 148</span>  }</div>
|
|
<div class="line"><a name="l00149"></a><span class="lineno"> 149</span>  <a class="code" href="classripple_1_1InboundHandoff.html#ac2bdbcd06ae6ca4756ec6c17b79330d2">close</a>();</div>
|
|
<div class="line"><a name="l00150"></a><span class="lineno"> 150</span> }</div>
|
|
<div class="line"><a name="l00151"></a><span class="lineno"> 151</span>  </div>
|
|
<div class="line"><a name="l00152"></a><span class="lineno"> 152</span> <span class="keywordtype">void</span></div>
|
|
<div class="line"><a name="l00153"></a><span class="lineno"><a class="line" href="classripple_1_1InboundHandoff.html#ac2bdbcd06ae6ca4756ec6c17b79330d2"> 153</a></span> <a class="code" href="classripple_1_1InboundHandoff.html#ac2bdbcd06ae6ca4756ec6c17b79330d2">InboundHandoff::close</a>()</div>
|
|
<div class="line"><a name="l00154"></a><span class="lineno"> 154</span> {</div>
|
|
<div class="line"><a name="l00155"></a><span class="lineno"> 155</span>  <span class="keywordflow">if</span> (<a class="code" href="classripple_1_1InboundHandoff.html#a2908a03ab47269d428605b011365ee7b">socket</a>().is_open())</div>
|
|
<div class="line"><a name="l00156"></a><span class="lineno"> 156</span>  {</div>
|
|
<div class="line"><a name="l00157"></a><span class="lineno"> 157</span>  <a class="code" href="classripple_1_1InboundHandoff.html#a2908a03ab47269d428605b011365ee7b">socket</a>().close();</div>
|
|
<div class="line"><a name="l00158"></a><span class="lineno"> 158</span>  JLOG(<a class="code" href="classripple_1_1InboundHandoff.html#ae99f1d3369b5fdff937cb595d7b26248">journal_</a>.<a class="code" href="classbeast_1_1Journal.html#a556228cb60bcf405c225d3f64b7b01ae">debug</a>()) << <span class="stringliteral">"Closed"</span>;</div>
|
|
<div class="line"><a name="l00159"></a><span class="lineno"> 159</span>  }</div>
|
|
<div class="line"><a name="l00160"></a><span class="lineno"> 160</span> }</div>
|
|
<div class="line"><a name="l00161"></a><span class="lineno"> 161</span>  </div>
|
|
<div class="line"><a name="l00162"></a><span class="lineno"> 162</span> <span class="keywordtype">void</span></div>
|
|
<div class="line"><a name="l00163"></a><span class="lineno"><a class="line" href="classripple_1_1InboundHandoff.html#a8d77c3bcda69bb5b52d43a984279e5e5"> 163</a></span> <a class="code" href="classripple_1_1InboundHandoff.html#a8d77c3bcda69bb5b52d43a984279e5e5">InboundHandoff::createPeer</a>()</div>
|
|
<div class="line"><a name="l00164"></a><span class="lineno"> 164</span> {</div>
|
|
<div class="line"><a name="l00165"></a><span class="lineno"> 165</span>  <span class="keyword">auto</span> peer = std::make_shared<PeerImp>(</div>
|
|
<div class="line"><a name="l00166"></a><span class="lineno"> 166</span>  <a class="code" href="classripple_1_1InboundHandoff.html#a83c180bd8d3162807bd97d458f1b3ea2">app_</a>,</div>
|
|
<div class="line"><a name="l00167"></a><span class="lineno"> 167</span>  <a class="code" href="classripple_1_1InboundHandoff.html#a1f163af097c54cced5622ba99c65ca67">id_</a>,</div>
|
|
<div class="line"><a name="l00168"></a><span class="lineno"> 168</span>  <a class="code" href="classripple_1_1InboundHandoff.html#ab353a0ba6b750304097b287758fd6bb7">slot_</a>,</div>
|
|
<div class="line"><a name="l00169"></a><span class="lineno"> 169</span>  std::move(<a class="code" href="classripple_1_1InboundHandoff.html#ad10d9fda32f4a5b890d98832d04b3985">request_</a>),</div>
|
|
<div class="line"><a name="l00170"></a><span class="lineno"> 170</span>  <a class="code" href="classripple_1_1InboundHandoff.html#adee668c2d899437959e072a0b6d0b702">publicKey_</a>,</div>
|
|
<div class="line"><a name="l00171"></a><span class="lineno"> 171</span>  <a class="code" href="classripple_1_1InboundHandoff.html#af13b1a1108fb0a0c7afe3f6761af3a6a">protocol_</a>,</div>
|
|
<div class="line"><a name="l00172"></a><span class="lineno"> 172</span>  <a class="code" href="classripple_1_1InboundHandoff.html#a53e99bf53d7fbb71831eec77141811c7">usage_</a>,</div>
|
|
<div class="line"><a name="l00173"></a><span class="lineno"> 173</span>  std::move(<a class="code" href="classripple_1_1InboundHandoff.html#a8d945de6a9f007235f2b34df227e1197">stream_ptr_</a>),</div>
|
|
<div class="line"><a name="l00174"></a><span class="lineno"> 174</span>  <a class="code" href="classripple_1_1OverlayImpl_1_1Child.html#ac48a68b0e553ec566f03e3f7d538beec">overlay_</a>);</div>
|
|
<div class="line"><a name="l00175"></a><span class="lineno"> 175</span>  </div>
|
|
<div class="line"><a name="l00176"></a><span class="lineno"> 176</span>  <a class="code" href="classripple_1_1OverlayImpl_1_1Child.html#ac48a68b0e553ec566f03e3f7d538beec">overlay_</a>.<a class="code" href="classripple_1_1OverlayImpl.html#a340bd55af73ab8800735f6c3ac538817">add_active</a>(peer);</div>
|
|
<div class="line"><a name="l00177"></a><span class="lineno"> 177</span> }</div>
|
|
<div class="line"><a name="l00178"></a><span class="lineno"> 178</span>  </div>
|
|
<div class="line"><a name="l00179"></a><span class="lineno"> 179</span> <a class="code" href="classripple_1_1InboundHandoff.html#a7c0307634f587e8116ed70d5d11f454b">InboundHandoff::socket_type</a>&</div>
|
|
<div class="line"><a name="l00180"></a><span class="lineno"><a class="line" href="classripple_1_1InboundHandoff.html#a2908a03ab47269d428605b011365ee7b"> 180</a></span> <a class="code" href="classripple_1_1InboundHandoff.html#a2908a03ab47269d428605b011365ee7b">InboundHandoff::socket</a>()<span class="keyword"> const</span></div>
|
|
<div class="line"><a name="l00181"></a><span class="lineno"> 181</span> <span class="keyword"></span>{</div>
|
|
<div class="line"><a name="l00182"></a><span class="lineno"> 182</span>  <span class="keywordflow">return</span> <a class="code" href="classripple_1_1InboundHandoff.html#a8d945de6a9f007235f2b34df227e1197">stream_ptr_</a>->next_layer().socket();</div>
|
|
<div class="line"><a name="l00183"></a><span class="lineno"> 183</span> }</div>
|
|
<div class="line"><a name="l00184"></a><span class="lineno"> 184</span>  </div>
|
|
<div class="line"><a name="l00185"></a><span class="lineno"> 185</span> } <span class="comment">// namespace ripple</span></div>
|
|
</div><!-- fragment --></div><!-- contents -->
|
|
<div class="ttc" id="aclassripple_1_1Application_html"><div class="ttname"><a href="classripple_1_1Application.html">ripple::Application</a></div><div class="ttdef"><b>Definition:</b> <a href="Application_8h_source.html#l00116">Application.h:116</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1InboundHandoff_html_ab353a0ba6b750304097b287758fd6bb7"><div class="ttname"><a href="classripple_1_1InboundHandoff.html#ab353a0ba6b750304097b287758fd6bb7">ripple::InboundHandoff::slot_</a></div><div class="ttdeci">const std::shared_ptr< PeerFinder::Slot > slot_</div><div class="ttdef"><b>Definition:</b> <a href="InboundHandoff_8h_source.html#l00050">InboundHandoff.h:50</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1Application_html_a296fbab181bda48bf599996518228bf9"><div class="ttname"><a href="classripple_1_1Application.html#a296fbab181bda48bf599996518228bf9">ripple::Application::cluster</a></div><div class="ttdeci">virtual Cluster & cluster()=0</div></div>
|
|
<div class="ttc" id="abind_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/utility/functional/bind.html">std::bind</a></div><div class="ttdeci">T bind(T... args)</div></div>
|
|
<div class="ttc" id="abasic_string_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/string/basic_string.html">std::string</a></div><div class="ttdoc">STL class.</div></div>
|
|
<div class="ttc" id="ashared_ptr_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/memory/shared_ptr.html">std::shared_ptr</a></div><div class="ttdoc">STL class.</div></div>
|
|
<div class="ttc" id="aclassripple_1_1OverlayImpl_1_1Child_html_ac48a68b0e553ec566f03e3f7d538beec"><div class="ttname"><a href="classripple_1_1OverlayImpl_1_1Child.html#ac48a68b0e553ec566f03e3f7d538beec">ripple::OverlayImpl::Child::overlay_</a></div><div class="ttdeci">OverlayImpl & overlay_</div><div class="ttdef"><b>Definition:</b> <a href="OverlayImpl_8h_source.html#l00064">OverlayImpl.h:64</a></div></div>
|
|
<div class="ttc" id="aclassbeast_1_1IP_1_1Endpoint_html_adcbd20a3d8d1d3f7c6a3ae541f519fb4"><div class="ttname"><a href="classbeast_1_1IP_1_1Endpoint.html#adcbd20a3d8d1d3f7c6a3ae541f519fb4">beast::IP::Endpoint::to_string</a></div><div class="ttdeci">std::string to_string() const</div><div class="ttdoc">Returns a string representing the endpoint.</div><div class="ttdef"><b>Definition:</b> <a href="IPEndpoint_8cpp_source.html#l00057">IPEndpoint.cpp:57</a></div></div>
|
|
<div class="ttc" id="apair_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/utility/pair.html">std::pair</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1InboundHandoff_html_ac2bdbcd06ae6ca4756ec6c17b79330d2"><div class="ttname"><a href="classripple_1_1InboundHandoff.html#ac2bdbcd06ae6ca4756ec6c17b79330d2">ripple::InboundHandoff::close</a></div><div class="ttdeci">void close()</div><div class="ttdoc">Close connection.</div><div class="ttdef"><b>Definition:</b> <a href="InboundHandoff_8cpp_source.html#l00153">InboundHandoff.cpp:153</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1InboundHandoff_html_a8d77c3bcda69bb5b52d43a984279e5e5"><div class="ttname"><a href="classripple_1_1InboundHandoff.html#a8d77c3bcda69bb5b52d43a984279e5e5">ripple::InboundHandoff::createPeer</a></div><div class="ttdeci">void createPeer()</div><div class="ttdoc">Instantiate and run the overlay peer.</div><div class="ttdef"><b>Definition:</b> <a href="InboundHandoff_8cpp_source.html#l00163">InboundHandoff.cpp:163</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1InboundHandoff_html_a53e99bf53d7fbb71831eec77141811c7"><div class="ttname"><a href="classripple_1_1InboundHandoff.html#a53e99bf53d7fbb71831eec77141811c7">ripple::InboundHandoff::usage_</a></div><div class="ttdeci">Resource::Consumer usage_</div><div class="ttdef"><b>Definition:</b> <a href="InboundHandoff_8h_source.html#l00049">InboundHandoff.h:49</a></div></div>
|
|
<div class="ttc" id="anamespaceripple_html_a08a13b62b18272366f788632359e8793"><div class="ttname"><a href="namespaceripple.html#a08a13b62b18272366f788632359e8793">ripple::toBase58</a></div><div class="ttdeci">std::string toBase58(AccountID const &v)</div><div class="ttdoc">Convert AccountID to base58 checked string.</div><div class="ttdef"><b>Definition:</b> <a href="AccountID_8cpp_source.html#l00104">AccountID.cpp:104</a></div></div>
|
|
<div class="ttc" id="aclassbeast_1_1IP_1_1Endpoint_html_a63fa66c4eb0d68359a0ff642891493c5"><div class="ttname"><a href="classbeast_1_1IP_1_1Endpoint.html#a63fa66c4eb0d68359a0ff642891493c5">beast::IP::Endpoint::address</a></div><div class="ttdeci">Address const & address() const</div><div class="ttdoc">Returns the address portion of this endpoint.</div><div class="ttdef"><b>Definition:</b> <a href="IPEndpoint_8h_source.html#l00076">IPEndpoint.h:76</a></div></div>
|
|
<div class="ttc" id="abasic_stringstream_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/io/basic_stringstream.html">std::stringstream</a></div><div class="ttdoc">STL class.</div></div>
|
|
<div class="ttc" id="aclassbeast_1_1Journal_html_ad8fefe3e8ad583e1ed1bf02094ac3d8f"><div class="ttname"><a href="classbeast_1_1Journal.html#ad8fefe3e8ad583e1ed1bf02094ac3d8f">beast::Journal::warn</a></div><div class="ttdeci">Stream warn() const</div><div class="ttdef"><b>Definition:</b> <a href="Journal_8h_source.html#l00326">Journal.h:326</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1InboundHandoff_html_a032a30416289de654b7397f055c907b8"><div class="ttname"><a href="classripple_1_1InboundHandoff.html#a032a30416289de654b7397f055c907b8">ripple::InboundHandoff::strand_</a></div><div class="ttdeci">boost::asio::strand< boost::asio::executor > strand_</div><div class="ttdef"><b>Definition:</b> <a href="InboundHandoff_8h_source.html#l00045">InboundHandoff.h:45</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1InboundHandoff_html_a83c180bd8d3162807bd97d458f1b3ea2"><div class="ttname"><a href="classripple_1_1InboundHandoff.html#a83c180bd8d3162807bd97d458f1b3ea2">ripple::InboundHandoff::app_</a></div><div class="ttdeci">Application & app_</div><div class="ttdef"><b>Definition:</b> <a href="InboundHandoff_8h_source.html#l00040">InboundHandoff.h:40</a></div></div>
|
|
<div class="ttc" id="anamespaceripple_html_a7241d07322a0d8fa2e2effedd739a90f"><div class="ttname"><a href="namespaceripple.html#a7241d07322a0d8fa2e2effedd739a90f">ripple::makeSharedValue</a></div><div class="ttdeci">std::optional< uint256 > makeSharedValue(stream_type &ssl, beast::Journal journal)</div><div class="ttdoc">Computes a shared value based on the SSL connection state.</div><div class="ttdef"><b>Definition:</b> <a href="Handshake_8cpp_source.html#l00147">Handshake.cpp:147</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1Cluster_html_adffcdc10e28e4fa6f3e9b9c5f4bb3afa"><div class="ttname"><a href="classripple_1_1Cluster.html#adffcdc10e28e4fa6f3e9b9c5f4bb3afa">ripple::Cluster::member</a></div><div class="ttdeci">std::optional< std::string > member(PublicKey const &node) const</div><div class="ttdoc">Determines whether a node belongs in the cluster.</div><div class="ttdef"><b>Definition:</b> <a href="Cluster_8cpp_source.html#l00039">Cluster.cpp:39</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1InboundHandoff_html_a8d945de6a9f007235f2b34df227e1197"><div class="ttname"><a href="classripple_1_1InboundHandoff.html#a8d945de6a9f007235f2b34df227e1197">ripple::InboundHandoff::stream_ptr_</a></div><div class="ttdeci">std::unique_ptr< stream_type > stream_ptr_</div><div class="ttdef"><b>Definition:</b> <a href="InboundHandoff_8h_source.html#l00044">InboundHandoff.h:44</a></div></div>
|
|
<div class="ttc" id="asetfill_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/io/manip/setfill.html">std::setfill</a></div><div class="ttdeci">T setfill(T... args)</div></div>
|
|
<div class="ttc" id="aclassripple_1_1OverlayImpl_html_a55c2ef9cc5b0abfbd143b1feea4f3c4b"><div class="ttname"><a href="classripple_1_1OverlayImpl.html#a55c2ef9cc5b0abfbd143b1feea4f3c4b">ripple::OverlayImpl::setup</a></div><div class="ttdeci">Setup const & setup() const</div><div class="ttdef"><b>Definition:</b> <a href="OverlayImpl_8h_source.html#l00176">OverlayImpl.h:176</a></div></div>
|
|
<div class="ttc" id="astructripple_1_1PeerFinder_1_1Config_html_af9b3a48e05361caa57d3e0c09e37a166"><div class="ttname"><a href="structripple_1_1PeerFinder_1_1Config.html#af9b3a48e05361caa57d3e0c09e37a166">ripple::PeerFinder::Config::peerPrivate</a></div><div class="ttdeci">bool peerPrivate</div><div class="ttdoc">true if we want our IP address kept private.</div><div class="ttdef"><b>Definition:</b> <a href="PeerfinderManager_8h_source.html#l00061">PeerfinderManager.h:61</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1InboundHandoff_html_af05ac16ad93e49c8333d3b3bce1df38b"><div class="ttname"><a href="classripple_1_1InboundHandoff.html#af05ac16ad93e49c8333d3b3bce1df38b">ripple::InboundHandoff::InboundHandoff</a></div><div class="ttdeci">InboundHandoff(Application &app, id_t id, std::shared_ptr< PeerFinder::Slot > const &slot, http_request_type &&request, PublicKey const &publicKey, ProtocolVersion protocol, Resource::Consumer consumer, std::unique_ptr< stream_type > &&stream_ptr, OverlayImpl &overlay)</div><div class="ttdef"><b>Definition:</b> <a href="InboundHandoff_8cpp_source.html#l00028">InboundHandoff.cpp:28</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1OverlayImpl_html_af79b454c807a1a1ed55ddfb56ba9cf09"><div class="ttname"><a href="classripple_1_1OverlayImpl.html#af79b454c807a1a1ed55ddfb56ba9cf09">ripple::OverlayImpl::peerFinder</a></div><div class="ttdeci">PeerFinder::Manager & peerFinder()</div><div class="ttdef"><b>Definition:</b> <a href="OverlayImpl_8h_source.html#l00164">OverlayImpl.h:164</a></div></div>
|
|
<div class="ttc" id="ashared_from_this_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/memory/enable_shared_from_this/shared_from_this.html">std::enable_shared_from_this< InboundHandoff >::shared_from_this</a></div><div class="ttdeci">T shared_from_this(T... args)</div></div>
|
|
<div class="ttc" id="aclassripple_1_1PublicKey_html"><div class="ttname"><a href="classripple_1_1PublicKey.html">ripple::PublicKey</a></div><div class="ttdoc">A public key.</div><div class="ttdef"><b>Definition:</b> <a href="PublicKey_8h_source.html#l00061">PublicKey.h:61</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1InboundHandoff_html_a36e56c6447cf4f81a1213c5febd805cd"><div class="ttname"><a href="classripple_1_1InboundHandoff.html#a36e56c6447cf4f81a1213c5febd805cd">ripple::InboundHandoff::stop</a></div><div class="ttdeci">void stop() override</div><div class="ttdoc">Stop the child.</div><div class="ttdef"><b>Definition:</b> <a href="InboundHandoff_8cpp_source.html#l00070">InboundHandoff.cpp:70</a></div></div>
|
|
<div class="ttc" id="aclassbeast_1_1Journal_html_a5929f5a6c995e2c2c5aada222ee470c4"><div class="ttname"><a href="classbeast_1_1Journal.html#a5929f5a6c995e2c2c5aada222ee470c4">beast::Journal::active</a></div><div class="ttdeci">bool active(Severity level) const</div><div class="ttdoc">Returns true if any message would be logged at this severity level.</div><div class="ttdef"><b>Definition:</b> <a href="Journal_8h_source.html#l00300">Journal.h:300</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1InboundHandoff_html_aff4d57307082663fd45b1208bf3df33d"><div class="ttname"><a href="classripple_1_1InboundHandoff.html#aff4d57307082663fd45b1208bf3df33d">ripple::InboundHandoff::sendResponse</a></div><div class="ttdeci">void sendResponse()</div><div class="ttdoc">Send upgrade response to the client.</div><div class="ttdef"><b>Definition:</b> <a href="InboundHandoff_8cpp_source.html#l00083">InboundHandoff.cpp:83</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1InboundHandoff_html_af13b1a1108fb0a0c7afe3f6761af3a6a"><div class="ttname"><a href="classripple_1_1InboundHandoff.html#af13b1a1108fb0a0c7afe3f6761af3a6a">ripple::InboundHandoff::protocol_</a></div><div class="ttdeci">ProtocolVersion protocol_</div><div class="ttdef"><b>Definition:</b> <a href="InboundHandoff_8h_source.html#l00047">InboundHandoff.h:47</a></div></div>
|
|
<div class="ttc" id="aclassbeast_1_1Journal_html_a87d6bd59020d94110027dcab3d9e3357"><div class="ttname"><a href="classbeast_1_1Journal.html#a87d6bd59020d94110027dcab3d9e3357">beast::Journal::info</a></div><div class="ttdeci">Stream info() const</div><div class="ttdef"><b>Definition:</b> <a href="Journal_8h_source.html#l00320">Journal.h:320</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1InboundHandoff_html_ad10d9fda32f4a5b890d98832d04b3985"><div class="ttname"><a href="classripple_1_1InboundHandoff.html#ad10d9fda32f4a5b890d98832d04b3985">ripple::InboundHandoff::request_</a></div><div class="ttdeci">http_request_type request_</div><div class="ttdef"><b>Definition:</b> <a href="InboundHandoff_8h_source.html#l00051">InboundHandoff.h:51</a></div></div>
|
|
<div class="ttc" id="ainteger_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/types/integer.html">std::uint32_t</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1InboundHandoff_html_a4b7af86bdc8596c82cc1e1e3b4287adb"><div class="ttname"><a href="classripple_1_1InboundHandoff.html#a4b7af86bdc8596c82cc1e1e3b4287adb">ripple::InboundHandoff::fail</a></div><div class="ttdeci">void fail(std::string const &name, error_code const &ec)</div><div class="ttdoc">Log and close.</div><div class="ttdef"><b>Definition:</b> <a href="InboundHandoff_8cpp_source.html#l00129">InboundHandoff.cpp:129</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1InboundHandoff_html_a7c0307634f587e8116ed70d5d11f454b"><div class="ttname"><a href="classripple_1_1InboundHandoff.html#a7c0307634f587e8116ed70d5d11f454b">ripple::InboundHandoff::socket_type</a></div><div class="ttdeci">boost::asio::ip::tcp::socket socket_type</div><div class="ttdef"><b>Definition:</b> <a href="InboundHandoff_8h_source.html#l00036">InboundHandoff.h:36</a></div></div>
|
|
<div class="ttc" id="anamespaceripple_html"><div class="ttname"><a href="namespaceripple.html">ripple</a></div><div class="ttdoc">Use hash_* containers for keys that do not need a cryptographically secure hashing algorithm.</div><div class="ttdef"><b>Definition:</b> <a href="RCLCensorshipDetector_8h_source.html#l00029">RCLCensorshipDetector.h:29</a></div></div>
|
|
<div class="ttc" id="anamespaceprotocol_html"><div class="ttname"><a href="namespaceprotocol.html">protocol</a></div><div class="ttdef"><b>Definition:</b> <a href="ValidatorList_8h_source.html#l00038">ValidatorList.h:38</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1InboundHandoff_html_ae99f1d3369b5fdff937cb595d7b26248"><div class="ttname"><a href="classripple_1_1InboundHandoff.html#ae99f1d3369b5fdff937cb595d7b26248">ripple::InboundHandoff::journal_</a></div><div class="ttdeci">const beast::Journal journal_</div><div class="ttdef"><b>Definition:</b> <a href="InboundHandoff_8h_source.html#l00043">InboundHandoff.h:43</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1PeerFinder_1_1Manager_html_a7b106eb8bb9983a45b86a3685875d5ca"><div class="ttname"><a href="classripple_1_1PeerFinder_1_1Manager.html#a7b106eb8bb9983a45b86a3685875d5ca">ripple::PeerFinder::Manager::config</a></div><div class="ttdeci">virtual Config config()=0</div><div class="ttdoc">Returns the configuration for the manager.</div></div>
|
|
<div class="ttc" id="anamespacebeast_1_1severities_html_a069a8a312b9123b77f6aa31733ca73beab6ef7006e42e82dcc97478e4e362f883"><div class="ttname"><a href="namespacebeast_1_1severities.html#a069a8a312b9123b77f6aa31733ca73beab6ef7006e42e82dcc97478e4e362f883">beast::severities::kWarning</a></div><div class="ttdeci">@ kWarning</div><div class="ttdef"><b>Definition:</b> <a href="Journal_8h_source.html#l00037">Journal.h:37</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1Resource_1_1Consumer_html"><div class="ttname"><a href="classripple_1_1Resource_1_1Consumer.html">ripple::Resource::Consumer</a></div><div class="ttdoc">An endpoint that consumes resources.</div><div class="ttdef"><b>Definition:</b> <a href="Consumer_8h_source.html#l00034">Consumer.h:34</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1InboundHandoff_html_a848d68ac2f49700c6865ec93fafcf093"><div class="ttname"><a href="classripple_1_1InboundHandoff.html#a848d68ac2f49700c6865ec93fafcf093">ripple::InboundHandoff::error_code</a></div><div class="ttdeci">boost::system::error_code error_code</div><div class="ttdef"><b>Definition:</b> <a href="InboundHandoff_8h_source.html#l00035">InboundHandoff.h:35</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1InboundHandoff_html_af983687f55a7a71dbc108bfa0ff2067c"><div class="ttname"><a href="classripple_1_1InboundHandoff.html#af983687f55a7a71dbc108bfa0ff2067c">ripple::InboundHandoff::remote_address_</a></div><div class="ttdeci">const beast::IP::Endpoint remote_address_</div><div class="ttdef"><b>Definition:</b> <a href="InboundHandoff_8h_source.html#l00046">InboundHandoff.h:46</a></div></div>
|
|
<div class="ttc" id="anamespaceripple_html_a1bf8df553d36589191c8057c136cce03ac3fe5edb1f8a81a8e585f6a27c120be6"><div class="ttname"><a href="namespaceripple.html#a1bf8df553d36589191c8057c136cce03ac3fe5edb1f8a81a8e585f6a27c120be6">ripple::TokenType::NodePublic</a></div><div class="ttdeci">@ NodePublic</div></div>
|
|
<div class="ttc" id="astr_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/io/basic_stringstream/str.html">std::stringstream::str</a></div><div class="ttdeci">T str(T... args)</div></div>
|
|
<div class="ttc" id="aclassbeast_1_1Journal_html_a556228cb60bcf405c225d3f64b7b01ae"><div class="ttname"><a href="classbeast_1_1Journal.html#a556228cb60bcf405c225d3f64b7b01ae">beast::Journal::debug</a></div><div class="ttdeci">Stream debug() const</div><div class="ttdef"><b>Definition:</b> <a href="Journal_8h_source.html#l00314">Journal.h:314</a></div></div>
|
|
<div class="ttc" id="asize_t_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/types/size_t.html">std::size_t</a></div></div>
|
|
<div class="ttc" id="anamespaceripple_html_af9776f187d3686a7fba4c2d2fbeebdf4"><div class="ttname"><a href="namespaceripple.html#af9776f187d3686a7fba4c2d2fbeebdf4">ripple::to_string</a></div><div class="ttdeci">std::string to_string(Manifest const &m)</div><div class="ttdoc">Format the specified manifest to a string for debugging purposes.</div><div class="ttdef"><b>Definition:</b> <a href="app_2misc_2impl_2Manifest_8cpp_source.html#l00041">app/misc/impl/Manifest.cpp:41</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1InboundHandoff_html_a04fda047eeb6627c396ad77ab180846f"><div class="ttname"><a href="classripple_1_1InboundHandoff.html#a04fda047eeb6627c396ad77ab180846f">ripple::InboundHandoff::run</a></div><div class="ttdeci">void run()</div><div class="ttdoc">Start the handshake.</div><div class="ttdef"><b>Definition:</b> <a href="InboundHandoff_8cpp_source.html#l00061">InboundHandoff.cpp:61</a></div></div>
|
|
<div class="ttc" id="asetw_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/io/manip/setw.html">std::setw</a></div><div class="ttdeci">T setw(T... args)</div></div>
|
|
<div class="ttc" id="aclassripple_1_1OverlayImpl_html"><div class="ttname"><a href="classripple_1_1OverlayImpl.html">ripple::OverlayImpl</a></div><div class="ttdef"><b>Definition:</b> <a href="OverlayImpl_8h_source.html#l00058">OverlayImpl.h:58</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1InboundHandoff_html_a2908a03ab47269d428605b011365ee7b"><div class="ttname"><a href="classripple_1_1InboundHandoff.html#a2908a03ab47269d428605b011365ee7b">ripple::InboundHandoff::socket</a></div><div class="ttdeci">socket_type & socket() const</div><div class="ttdoc">Get underlying socket.</div><div class="ttdef"><b>Definition:</b> <a href="InboundHandoff_8cpp_source.html#l00180">InboundHandoff.cpp:180</a></div></div>
|
|
<div class="ttc" id="anamespaceripple_html_a5590ae6006b178275628bde91fa03129"><div class="ttname"><a href="namespaceripple.html#a5590ae6006b178275628bde91fa03129">ripple::makeResponse</a></div><div class="ttdeci">http_response_type makeResponse(bool crawlPublic, http_request_type const &req, beast::IP::Address public_ip, beast::IP::Address remote_ip, uint256 const &sharedValue, std::optional< std::uint32_t > networkID, ProtocolVersion protocol, Application &app)</div><div class="ttdoc">Make http response.</div><div class="ttdef"><b>Definition:</b> <a href="Handshake_8cpp_source.html#l00394">Handshake.cpp:394</a></div></div>
|
|
<div class="ttc" id="anamespaceripple_html_aa265217edeb8282e636c78b50049f4c0"><div class="ttname"><a href="namespaceripple.html#aa265217edeb8282e636c78b50049f4c0">ripple::http_request_type</a></div><div class="ttdeci">boost::beast::http::request< boost::beast::http::dynamic_body > http_request_type</div><div class="ttdef"><b>Definition:</b> <a href="Handshake_8h_source.html#l00047">Handshake.h:47</a></div></div>
|
|
<div class="ttc" id="aunique_ptr_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/memory/unique_ptr.html">std::unique_ptr< stream_type ></a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1OverlayImpl_html_a340bd55af73ab8800735f6c3ac538817"><div class="ttname"><a href="classripple_1_1OverlayImpl.html#a340bd55af73ab8800735f6c3ac538817">ripple::OverlayImpl::add_active</a></div><div class="ttdeci">void add_active(std::shared_ptr< PeerImp > const &peer)</div><div class="ttdef"><b>Definition:</b> <a href="OverlayImpl_8cpp_source.html#l00421">OverlayImpl.cpp:421</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1InboundHandoff_html_a1f163af097c54cced5622ba99c65ca67"><div class="ttname"><a href="classripple_1_1InboundHandoff.html#a1f163af097c54cced5622ba99c65ca67">ripple::InboundHandoff::id_</a></div><div class="ttdeci">const id_t id_</div><div class="ttdef"><b>Definition:</b> <a href="InboundHandoff_8h_source.html#l00041">InboundHandoff.h:41</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1InboundHandoff_html_adee668c2d899437959e072a0b6d0b702"><div class="ttname"><a href="classripple_1_1InboundHandoff.html#adee668c2d899437959e072a0b6d0b702">ripple::InboundHandoff::publicKey_</a></div><div class="ttdeci">const PublicKey publicKey_</div><div class="ttdef"><b>Definition:</b> <a href="InboundHandoff_8h_source.html#l00048">InboundHandoff.h:48</a></div></div>
|
|
<!-- start footer part -->
|
|
<hr class="footer"/><address class="footer"><small>
|
|
Generated by  <a href="http://www.doxygen.org/index.html">
|
|
<img class="footer" src="doxygen.png" alt="doxygen"/>
|
|
</a> 1.8.17
|
|
</small></address>
|
|
</body>
|
|
</html>
|