Provided by: stone_2.4-1.1_amd64
NAME
stone - Simple TCP/UDP Packet Repeater
SYNOPSYS
stone [-d] [-n] [-u max] [-f n] [-l] [-z SSL] st [-- st]...
OPTIONS
-d ¥Ç¥Ð¥Ã¥°¥ì¥Ù¥ë¤òÁý²Ã¤µ¤»¤Þ¤¹¡£ -z SSL °Å¹æ²½¤Î¥ª¥×¥·¥ç¥ó¤Ç¤¹¡£ -n ¥Û¥¹¥È̾¤ä¥µ¡¼¥Ó¥¹Ì¾¤ÎÂå¤ï¤ê¤Ë IP ¥¢¥É¥ì¥¹¤ä¥µ¡¼¥Ó¥¹ÈÖ¹æ¤òɽ¼¨¤·¤Þ¤¹¡£ -u Ʊ»þ¤Ëµ²±¤Ç¤¤ë UDP ¥Ñ¥±¥Ã¥È¤Îȯ¿®¸µ¤ÎºÇÂç¿ô¤ò»ØÄꤷ¤Þ¤¹¡£ ¥Ç¥Õ¥©¥ë¥È¤Ï 10 ¤Ç¤¹¡£ -f »Ò¥×¥í¥»¥¹¤Î¿ô¤ò»ØÄꤷ¤Þ¤¹¡£¥Ç¥Õ¥©¥ë¥È¤Ï»Ò¥×¥í¥»¥¹Ìµ¤·¤Ç¤¹¡£ -l ¥¨¥é¡¼¥á¥Ã¥»¡¼¥¸Åù¤ò syslog ¤Ø½ÐÎϤ·¤Þ¤¹¡£ st ¼¡¤Î¤¤¤º¤ì¤«¤Ç¤¹¡£st ¤Ï¡Ö--¡×¤Ç¶èÀڤ뤳¤È¤Ë¤è¤ê¡¢ Ê£¿ô¸Ä»ØÄê¤Ç¤¤Þ¤¹¡£ (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...] stone ¤ò¼Â¹Ô¤·¤Æ¤¤¤ë¥Þ¥·¥ó¤Î¥Ý¡¼¥È sport ¤Ø¤ÎÀܳ¤ò¡¢Â¾¤Î¥Þ¥· ¥ó host ¤Î¥Ý¡¼¥È port ¤ØÃæ·Ñ¤·¤Þ¤¹¡£¥¤¥ó¥¿¥Õ¥§¡¼¥¹¤òÊ£¿ô»ý¤Ä ¥Þ¥·¥ó¤Ç¤Ï¡¢(2) ¤Î¤è¤¦¤Ë¥¤¥ó¥¿¥Õ¥§¡¼¥¹¤Î¥¢¥É¥ì¥¹ shost ¤ò»ØÄê ¤¹¤ë¤³¤È¤Ë¤è¤ê¡¢ÆÃÄê¤Î¥¤¥ó¥¿¥Õ¥§¡¼¥¹¤Ø¤ÎÀܳ¤Î¤ß¤òžÁ÷¤¹¤ë¤³¤È¤¬ ¤Ç¤¤Þ¤¹¡£ display [xhost ...] X ¥×¥í¥È¥³¥ëÃæ·Ñ¤Î¤¿¤á¤Î¾ÊάµË¡¤Ç¤¹¡£¥Ç¥£¥¹¥×¥ì¥¤ÈÖ¹æ display ¤Ø¤ÎÀܳ¤ò¡¢´Ä¶ÊÑ¿ô DISPLAY ¤Ç»ØÄꤷ¤¿ X ¥µ¡¼¥Ð¤ØžÁ÷ ¤·¤Þ¤¹¡£ proxy sport [xhost ...] http proxy ¤Ç¤¹¡£WWW ¥Ö¥é¥¦¥¶¤Î http proxy ¤ÎÀßÄê¤Ç¡¢ stone ¤ò¼Â¹Ô¤·¤Æ¤¤¤ë¥Þ¥·¥ó¤ª¤è¤Ó¥Ý¡¼¥È sport ¤ò»ØÄꤷ¤Þ¤¹¡£ host:port/http request [hosts ...] http ¥ê¥¯¥¨¥¹¥È¤Ë¤Î¤»¤Æ¥Ñ¥±¥Ã¥È¤òÃæ·Ñ¤·¤Þ¤¹¡£request ¤Ï HTTP 1.0 ¤Çµ¬Äꤵ¤ì¤ë¥ê¥¯¥¨¥¹¥È¤Ç¤¹¡£ host:port/proxy header [hosts...] http ¥ê¥¯¥¨¥¹¥È¥Ø¥Ã¥À¤ÎÀèƬ¤Ë header ¤òÄɲä·¤ÆÃæ·Ñ¤· ¤Þ¤¹¡£ xhost ¤òÎóµó¤¹¤ë¤³¤È¤Ë¤è¤ê¡¢stone ¤ØÀܳ²Äǽ¤Ê¥Þ¥·¥ó¤òÀ©¸Â¤¹¤ë ¤³¤È¤¬¤Ç¤‐ ¤Þ¤¹¡£¥Þ¥·¥ó̾¡¢¤¢¤ë¤¤¤Ï¤½¤Î IP ¥¢¥É¥ì¥¹¤ò¶õÇò¤Ç¶èÀڤà ¤Æ»ØÄꤹ¤ë¤È¡¢¤½¤Î¥Þ¥·¥ó¤«¤é¤ÎÀܳ¤Î¤ß¤òÃæ·Ñ¤·¤Þ¤¹¡£ xhost ¤Ë¡Ö/mask¡×¤òÉÕ¤±¤ë¤È¡¢ÆÃÄê¤Î¥Í¥Ã¥È¥ï¡¼¥¯¤Î¥Þ¥·¥ó¤«¤é ¤ÎÀܳ¤òµö²Ä¤¹¤ë¤³¤È¤¬¤Ç¤‐ ¤Þ¤¹¡£Î㤨¤Ð¡¢¥¯¥é¥¹ C ¤Î¥Í¥Ã¥È¥ï¡¼¥¯ 192.168.1.0 ¤Î¾ì¹ç¤Ï¡¢¡Ö192.168.1.0/255.255.255.0¡×¤È»ØÄꤷ¤Þ¤¹¡£ sport ¤Ë¡Ö/udp¡×¤òÉÕ¤±¤ë¤È¡¢TCP ¥Ñ¥±¥Ã¥È¤òÃæ·Ñ¤¹¤ëÂå¤ï¤ê¤Ë¡¢ UDP ¥Ñ¥±¥Ã¥È¤òÃæ·Ñ¤·¤Þ¤¹¡£ port ¤Ë¡Ö/ssl¡×¤òÉÕ¤±¤ë¤È¡¢¥Ñ¥±¥Ã¥È¤ò SSL ¤Ç°Å¹æ²½¤·¤ÆÃæ·Ñ¤·¤Þ¤¹¡£ sport ¤Ë¡Ö/ssl¡×¤òÉÕ¤±¤ë¤È¡¢SSL ¤Ç°Å¹æ²½¤µ¤ì¤¿¥Ñ¥±¥Ã¥È¤òÉü¹æ²½ ¤·¤ÆÃæ·Ñ¤·¤Þ¤¹¡£ sport ¤Ë¡Ö/http¡×¤òÉÕ¤±¤ë¤È¡¢http ¥ê¥¯¥¨¥¹¥È¾å¤Î¥Ñ¥±¥Ã¥È¤òÃæ·Ñ ¤·¤Þ¤¹¡£
DESCRIPTION
stone ¤Ï¡¢¥¢¥×¥ê¥±¡¼¥·¥ç¥ó¥ì¥Ù¥ë¤Î TCP & UDP ¥Ñ¥±¥Ã¥È¥ê¥Ô¡¼¥¿¡¼¤Ç¤¹¡£ ¥Õ¥¡¥¤¥¢¥¦¥©¡¼¥ë¤ÎÆ⤫¤é³°¤Ø¡¢¤¢¤ë¤¤¤Ï³°¤«¤éÆâ¤Ø¡¢TCP ¥Ñ¥±¥Ã¥È¤¢¤ë¤¤¤Ï UDP ¥Ñ¥±¥Ã¥È¤òÃæ·Ñ¤·¤Þ¤¹¡£ stone ¤Ë¤Ï°Ê²¼¤Î¤è¤¦¤ÊÆÃħ¤¬¤¢¤ê¤Þ¤¹¡£ 1. Win32 ¤ËÂбþ¤·¤Æ¤¤¤ë °ÊÁ°¤Ï UNIX ¥Þ¥·¥ó¤Ç¹½À®¤µ¤ì¤ë¤³¤È¤¬Â¿¤«¤Ã¤¿¥Õ¥¡¥¤¥¢¥¦¥©¡¼¥ë¤Ç¤¹ ¤¬¡¢ºÇ¶á¤Ï WindowsNT ¤¬»È¤ï¤ì¤ë¥±¡¼¥¹¤¬Áý¤¨¤Æ¤¤Þ¤·¤¿¡£stone ¤Ï WindowsNT ¤¢¤ë¤¤¤Ï Windows95 ¾å¤Ç¼ê·Ú¤Ë¼Â¹Ô¤¹¤ë¤³¤È¤¬¤Ç¤¤Þ¤¹¡£ ¤â¤Á¤í¤ó¡¢Linux, FreeBSD, BSD/OS, SunOS, Solaris, HP-UX ¤Ê¤É¤Î UNIX ¥Þ¥·¥ó¤Ç¤â»È¤¦¤³¤È¤¬¤Ç¤¤Þ¤¹¡£ 2. ñ½ã ¤ï¤º¤« 2000 ¹Ô (C ¸À¸ì) ¤Ç¤¹¤Î¤Ç¡¢¥»¥¥å¥ê¥Æ¥£¥Û¡¼¥ë¤¬À¸¤¸¤ë²Äǽ À¤òºÇ¾®¸Â¤Ë¤Ç¤‐ ¤Þ¤¹¡£ 3. SSLeay Âбþ Eric Young »á¤Î SSLeay ¤ò»È¤¦¤³¤È¤Ë¤è¤ê¡¢°Å¹æ²½/Éü¹æ²½¤·¤Æ¥Ñ¥±¥Ã ¥È¤òÃæ·Ñ¤Ç¤¤Þ¤¹¡£ 4. http proxy ´Ê°×·¿ http proxy ¤È¤·¤Æ¤â»È¤¦¤³¤È¤¬¤Ç¤¤Þ¤¹¡£
EXAMPLE
outer: ¥Õ¥¡¥¤¥¢¥¦¥©¡¼¥ë¤Î³°Â¦¤Ë¤¢¤ë¥Þ¥·¥ó inner: ¥Õ¥¡¥¤¥¢¥¦¥©¡¼¥ë¤ÎÆ⦤ˤ¢¤ë¥Þ¥·¥ó fwall: ¥Õ¥¡¥¤¥¢¥¦¥©¡¼¥ë. ¤³¤Î¥Þ¥·¥ó¾å¤Ç stone ¤ò¼Â¹Ô stone 7 outer DISPLAY ¤Ç»ØÄꤷ¤¿ X server ¤Ø X ¥×¥í¥È¥³¥ë¤òÃæ·Ñ outer ¤Ç DISPLAY=inner:7 ¤ÈÀßÄꤷ¤Æ X ¥¯¥é¥¤¥¢¥ó¥È¤ò¼Â¹Ô stone outer:telnet 10023 outer ¤Ø telnet ¥×¥í¥È¥³¥ë¤òÃæ·Ñ inner ¤Ç telnet fwall 10023 ¤ò¼Â¹Ô stone outer:domain/udp domain/udp DNS Ì䤤¹ç¤ï¤»¤ò outer ¤ØÃæ·Ñ inner ¤Ç nslookup - fwall ¤ò¼Â¹Ô stone outer:ntp/udp ntp/udp outer ¤Ø NTP ¤òÃæ·Ñ inner ¤Ç ntpdate fwall ¤ò¼Â¹Ô stone localhost:http 443/ssl WWW ¥µ¡¼¥Ð¤ò https Âбþ¤Ë¤¹¤ë WWW ¥Ö¥é¥¦¥¶¤Ç https://fwall/ ¤ò¥¢¥¯¥»¥¹ stone localhost:telnet 10023/ssl telnet ¤ò SSL ²½ inner ¤Ç SSLtelnet -z ssl fwall 10023 ¤ò¼Â¹Ô stone proxy 8080 http proxy fwall ¤¬ http proxy (port 8080) ¤Ç¤¢¤ë»þ: stone fwall:8080/http 10023 'POST http://outer:8023 HTTP/1.0' stone localhost:telnet 8023/http inner ¤È outer ¤Ç¤½¤ì¤¾¤ì stone ¤ò¼Â¹Ô http ¾å¤Ç¥Ñ¥±¥Ã¥È¤òÃæ·Ñ stone fwall:8080/proxy 9080 ´Proxy-Authorization: Basic c2VuZ29rdTpoaXJvYWtp´ proxy ǧ¾Ú¤ËÂбþ¤·¤Æ¤¤¤Ê¤¤¥Ö¥é¥¦¥¶ÍÑ
COPYRIGHT
¤³¤Î stone ¤Ë´Ø¤¹¤ëÁ´¤Æ¤ÎÃøºî¸¢¤Ï¡¢¸¶Ãøºî¼Ô¤Ç¤¢¤ëÀçÀйÀÌÀ¤¬½êÍ ¤·¤Þ¤¹¡£¤³¤Î stone ¤Ï¡¢GNU General Public License (GPL) ¤Ë½à¤º¤ë ¥Õ¥ê¡¼¥½¥Õ¥È¥¦¥§¥¢¤Ç¤¹¡£¸Ä¿ÍŪ¤Ë»ÈÍѤ¹¤ë¾ì¹ç¤Ï¡¢²þÊÑ¡¦Ê£À½¤ËÀ©¸Â ¤Ï¤¢¤ê¤Þ¤»¤ó¡£ÇÛÉÛ¤¹¤ë¾ì¹ç¤Ï GPL ¤Ë½¾¤Ã¤Æ²¼¤µ¤¤¡£
DISCLAIMER
¤³¤Î stone ¤Ï̵ÊݾڤǤ¹¡£¤³¤Î stone ¤ò»È¤Ã¤ÆÀ¸¤¸¤¿¤¤¤«¤Ê¤ë»³²¤Ë ÂФ·¤Æ¤â¡¢¸¶Ãøºî¼Ô¤ÏÀÕǤ¤òÉ餤¤Þ¤»¤ó¡£¾Ü¤·¤¯¤Ï GPL ¤ò»²¾È¤·¤Æ²¼ ¤µ¤¤¡£
AUTHOR
ÀçÀÐ ¹ÀÌÀ sengoku@gcd.org http://www.gcd.org/sengoku/ Version 2.0 stone(1)