-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathindex.html
234 lines (224 loc) · 7.27 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
<html>
<head>
<title>
onramp
</title>
<meta name="author" content="eyedeekay" />
<meta name="description" content="onramp.git" />
<meta name="keywords" content="main" />
<link rel="stylesheet" type="text/css" href="style.css" />
<link rel="stylesheet" type="text/css" href="showhider.css" />
</head>
<body>
<div id="navbar">
<a href="#shownav">
Show navigation
</a>
<div id="shownav">
<div id="hidenav">
<ul>
<li>
<a href="..">
Up one level ^
</a>
</li>
<li>
<a href="index.html">
index
</a>
</li>
<li>
<a href="DESC.html">
DESC
</a>
</li>
<li>
<a href="DOCS.html">
DOCS
</a>
</li>
<li>
<a href="EXAMPLE.html">
EXAMPLE
</a>
</li>
</ul>
<br>
<a href="#hidenav">
Hide Navigation
</a>
</div>
</div>
</div>
<h1>
<a href="#onramp" rel="nofollow">
<span></span>
</a>
onramp
</h1>
<p>
High-level, easy-to-use listeners and clients for I2P and onion URL's from Go.
Provides only the most widely-used functions in a basic way. It expects nothing
from the users, an otherwise empty instance of the structs will listen and dial
I2P Streaming and Tor TCP sessions successfully.
</p>
<p>
In all cases, it assumes that keys are "persistent" in that they are managed
maintained between usages of the same application in the same configuration.
This means that hidden services will maintain their identities, and that clients
will always have the same return addresses. If you don't want this behavior,
make sure to delete the "keystore" when your app closes or when your application
needs to cycle keys by calling the
<code>
Garlic.DeleteKeys()
</code>
or
<code>
Onion.DeleteKeys()
</code>
function. For more information, check out the
<a href="http://pkg.go.dev/github.com/eyedeekay/onramp" rel="nofollow">
godoc
</a>
.
</p>
<ul>
<li>
<strong>
<a href="https://github.com/eyedeekay/onramp" rel="nofollow">
Source Code
</a>
</strong>
</li>
</ul>
<p>
STATUS: This project is maintained. I will respond to issues, pull requests, and feature requests within a few days.
</p>
<h2>
<a href="#usage" rel="nofollow">
<span></span>
</a>
Usage
</h2>
<p>
Basic usage is designed to be very simple, import the package and instantiate
a struct and you're ready to go.
</p>
<p>
For more extensive examples, see:
<a href="EXAMPLE.md" rel="nofollow">
EXAMPLE
</a>
</p>
<h3>
<a href="#i2p-garlic-usage" rel="nofollow">
<span></span>
</a>
I2P(Garlic) Usage:
</h3>
<p>
When using it to manage an I2P session, set up an
<code>
onramp.Garlic
</code>
struct.
</p>
<div>
<pre>
<span>package</span> <span>main</span>
<span>import</span> <span>(</span>
<span>"log"</span>
<span>"github.com/eyedeekay/onramp"</span>
<span>)</span>
<span>func</span> <span>main</span><span>(</span><span>)</span> <span>{</span>
<span>garlic</span> <span>:=</span> <span>&</span><span>onramp</span><span>.</span><span>Garlic</span><span>{</span><span>}</span>
<span>defer</span> <span>garlic</span><span>.</span><span>Close</span><span>(</span><span>)</span>
<span>listener</span><span>,</span> <span>err</span> <span>:=</span> <span>garlic</span><span>.</span><span>Listen</span><span>(</span><span>)</span>
<span>if</span> <span>err</span> <span>!=</span> <span>nil</span> <span>{</span>
<span>log</span><span>.</span><span>Fatal</span><span>(</span><span>err</span><span>)</span>
<span>}</span>
<span>defer</span> <span>listener</span><span>.</span><span>Close</span><span>(</span><span>)</span>
<span>}</span>
</pre>
</div>
<h3>
<a href="#tor-onion-usage" rel="nofollow">
<span></span>
</a>
Tor(Onion) Usage:
</h3>
<p>
When using it to manage a Tor session, set up an
<code>
onramp.Onion
</code>
struct.
</p>
<div>
<pre>
<span>package</span> <span>main</span>
<span>import</span> <span>(</span>
<span>"log"</span>
<span>"github.com/eyedeekay/onramp"</span>
<span>)</span>
<span>func</span> <span>main</span><span>(</span><span>)</span> <span>{</span>
<span>onion</span> <span>:=</span> <span>&</span><span>onramp</span><span>.</span><span>Onion</span><span>{</span><span>}</span>
<span>defer</span> <span>garlic</span><span>.</span><span>Close</span><span>(</span><span>)</span>
<span>listener</span><span>,</span> <span>err</span> <span>:=</span> <span>onion</span><span>.</span><span>Listen</span><span>(</span><span>)</span>
<span>if</span> <span>err</span> <span>!=</span> <span>nil</span> <span>{</span>
<span>log</span><span>.</span><span>Fatal</span><span>(</span><span>err</span><span>)</span>
<span>}</span>
<span>defer</span> <span>listener</span><span>.</span><span>Close</span><span>(</span><span>)</span>
<span>}</span>
</pre>
</div>
<div id="sourcecode">
<ul>
<li>
<a href="https://github.com/eyedeekay/onramp.git">
Source Code: (https://github.com/eyedeekay/onramp.git)
</a>
</li>
</ul>
</div>
<div>
<a href="#show">
Show license
</a>
<div id="show">
<div id="hide">
<pre><code>MIT License
Copyright (c) 2022 idk
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
</code></pre>
<a href="#hide">
Hide license
</a>
</div>
</div>
</div>
<div>
<iframe src="https://snowflake.torproject.org/embed.html" width="320" height="240" frameborder="0" scrolling="no"></iframe>
</div>
<div>
<a href="https://geti2p.net/">
<img src="i2plogo.png"></img>
I2P
</a>
</div>
</body>
</html>