Re: came error from nc

看板FB_questions作者時間14年前 (2011/11/01 02:01), 編輯推噓0(000)
留言0則, 0人參與, 最新討論串2/2 (看更多)
In the last episode (Oct 31), Camal said: > Hi. My name is Jamal. > > I am from Azerbaijan. > > When I tried open local port with "nc" and send to him > "/usr/local/bin/bash" came error. > > nc -l 12345 -e /bin/bash > , Error -> > nc: getaddrinfo: servname not supported for ai_socktype > > in /etc/resolv.conf and /etc/hosts files checked all of was right. > > Why is it so? I can't reproduce your error message, but your command won't do what you want anyway. The nc command that comes with FreeBSD doesn't support the "listen on a socket and run a command" option. Its -e is an ipsec option. If you install /usr/ports/net/netcat and use that command, it should work: netcat -l -p 12345 -e /usr/local/bin/bash -- Dan Nelson dnelson@allantgroup.com _______________________________________________ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "freebsd-questions-unsubscribe@freebsd.org"
文章代碼(AID): #1Ehk9eFK (FB_questions)
文章代碼(AID): #1Ehk9eFK (FB_questions)