stone(1)
π stone(1) π
okay bestie, we're in section 1 of the General Commands Manual and the girl of the hour is stone. she's a tiny, adorable packet repeater and she has ZERO chill. (also psst β the original page is written in Japanese, so this is the translated-into-girlfriend-voice edition. same facts, better energy. π
)
πΈ NAME πΈ
stone β Simple TCP/UDP Packet Repeater. that's the whole name. short, sweet, slays. β¨
β¨ SYNOPSYS β¨
(yes it's spelled SYNOPSYS in the original and honestly? iconic. we do not correct her. π)
stone [-d] [-n] [-u max] [-f n] [-l] [-z SSL] st [-- st]...
π OPTIONS π
-dβ cranks up the debug level. π more debug, more... debug.-zβ the SSL encryption option. that's her entire personality. π-nβ instead of host names and service names, she shows you the IP addresses and service numbers. lowkey the raw unfiltered truth. π’-uβ sets the maximum number of sources of UDP packets she'll handle at the same time. the default is10. π«§-fβ sets the number of child processes. the default is no child processes at all β she is an only child, periodt. πΆ-lβ sends error messages and friends out tosyslog. πstβ the main character!! she's one of the following, and ngl you can pass multiplests by separating them with--. π«
(1) host:port sport [xhost ...]
(2) host:port shost:sport [xhost ...]
(3) display [xhost ...]
(4) proxy sport [xhost ...]
(5) host:port/http request [hosts ...]
(6) host:port/proxy header [hosts...]
so the tea is this: stone takes connections coming in to port sport on the machine she's running on, and relays them to port port on another machine host. and on machines with multiple interfaces, you do it like form (2) β specify the interface address shost β and then only connections to that one specific interface get forwarded. she's picky like that, we respect it. π«Ά
display [xhost ...]β the shorthand notation for X protocol relaying. she forwards connections to display numberdisplayover to the X server that you named in theDISPLAYenvironment variable. β¨proxy sport [xhost ...]β it's an http proxy. in your WWW browser's http proxy settings you just put in the machinestoneis running on, plus portsport. done. π§host:port/http request [hosts ...]β relays packets by carrying them on an http request.requestis a request as defined by HTTP 1.0. π¨host:port/proxy header [hosts...]β addsheaderto the very front of the http request header and then relays. π
now, if you list out xhosts, you can restrict which machines are allowed to connect to stone. give her machine names, or their IP addresses, separated by whitespace, and she'll relay connections only from those machines. gatekeeping, but make it networking. πͺ
and if you stick a /mask on an xhost, she'll allow connections from machines on a specific network. for example, for the class C network 192.168.1.0, you'd write 192.168.1.0/255.255.255.0. π
- put
/udponsportβ instead of relaying TCP packets, she relays UDP packets. πΈ - put
/sslonportβ packets get relayed encrypted with SSL. π - put
/sslonsportβ packets that are encrypted with SSL get decrypted and then relayed. π - put
/httponsportβ she relays packets carried on an http request. π
π¦ DESCRIPTION π¦
stone is an application-level TCP & UDP packet repeater. she relays TCP packets or UDP packets from inside a firewall to the outside, or from the outside to the inside. both directions, no drama. π«§
here's what makes her special:
- Win32 support β firewalls used to mostly be built out of UNIX machines, but lately WindowsNT is getting used more and more.
stonecan be run easily on WindowsNT or Windows95. and obviously she works on UNIX machines too β Linux, FreeBSD, BSD/OS, SunOS, Solaris, HP-UX, the whole roster. π - Simplicity β she's only about 2000 lines (C language), which keeps the possibility of security holes to an absolute minimum. small girl, huge brain. π§
- SSLeay support β by using Eric Young's SSLeay, she can encrypt/decrypt packets while relaying them. π
- http proxy β she can also be used as a simple http proxy. multitasking queen. π
π EXAMPLE π
outer: the machine outside the firewall
inner: the machine inside the firewall
fwall: the firewall. run stone on this machine
(the original labels these in Japanese β outer is the machine outside the firewall, inner is the machine inside it, and fwall is the firewall itself, the box you actually run stone on. π§±)
relay X protocol to the X server named in DISPLAY:
stone 7 outer
then on outer, set DISPLAY=inner:7 and run your X client. π₯οΈ
relay telnet protocol to outer:
stone outer:telnet 10023
then on inner, run telnet fwall 10023. π
relay DNS queries to outer:
stone outer:domain/udp domain/udp
then on inner, run nslookup - fwall. π
relay NTP to outer:
stone outer:ntp/udp ntp/udp
then on inner, run ntpdate fwall. β°
make a WWW server https-capable:
stone localhost:http 443/ssl
then hit https://fwall/ in your WWW browser. π
SSL-ify telnet:
stone localhost:telnet 10023/ssl
then on inner, run SSLtelnet -z ssl fwall 10023. π
http proxy:
stone proxy 8080
when fwall is an http proxy (port 8080):
stone fwall:8080/http 10023 'POST http://outer:8023 HTTP/1.0'
stone localhost:telnet 8023/http
run stone on inner and on outer respectively, and packets get relayed over http. π
stone fwall:8080/proxy 9080 'Proxy-Authorization: Basic c2VuZ29rdTpoaXJvYWtp'
this one is for browsers that don't support proxy authentication. π
π COPYRIGHT π
all copyright relating to this stone belongs to the original author, δ»η³ζ΅©ζ (Sengoku Hiroaki). this stone is free software that follows the GNU General Public License (GPL). if you're using it personally, there are no restrictions on modifying or duplicating it. if you're going to distribute it, please follow the GPL. π«Ά
π DISCLAIMER π
this stone comes with no warranty. the original author takes no responsibility for any damages that arise from using this stone. read the GPL for the full details, bestie. no cap. β οΈ
π¦ AUTHOR π¦
δ»η³ ζ΅©ζ (Sengoku Hiroaki) sengoku@gcd.org http://www.gcd.org/sengoku/
and that's the whole page!! this was Version 2.0, straight from the source, and she ate, no crumbs. go relay something responsibly. mwah πππ¦
π¦ where this page comes from
- debian trixie: stone 2.4-1.2 Β· GPL-2.0-or-later WITH OpenSSL exception
- ubuntu questing: stone 2.4-1.2
- ubuntu resolute: stone 2.4-1.2build1 Β· GPL-2.0-or-later WITH OpenSSL exception
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms