텔넷을 두개의 포트로 동시서비스 하는방법..??

ㅡ,.ㅡ;;의 이미지

텔넷을 두개의 포트로 동시에 서비스하도록 하려하는데..

방법좀알려주세요...

그러니까.. 23번포트로도 텔넷접속이되고.. 2300포트로도 접속이 되도록
설정하고 싶습니다..

kukuman의 이미지

그냥 telnet daemon을 2300 port로 하나 더 띄우면 될 것 같은데요~

Be at a right place at a right time...

ㅡ,.ㅡ;;의 이미지

죄송한데요..

하나더 띄운다는말씀이.. services 파일에 2Line 을 추가하라는건가요??

아니면.. xinetd 에또무슨 설정이 필요한건가요?? 아니면..

그냥명령어로 때리라는건가요? 명령어로 한다면...
어떻게 주면되나요?

더구나.. 저는 설정파일에 등록하여 띄우고 싶은데...


----------------------------------------------------------------------------

ㅡ,.ㅡ;;의 이미지

설정방법 아시는분 좀알려주세요...


----------------------------------------------------------------------------

nohmad의 이미지

xinetd라면 설정파일이 /etc/xinetd.d/telnet인데,
1. 같은 디렉토리에 telnet2 정도로 복사하고 파일 내용 중에 telnet을 telnet2로 변경.
2. /etc/services 안에서 telnet 라인을 복사한 다음 telnet2로, 번호를 원하는 포트 번호로 변경.
3. /etc/init.d/xinetd restart

isinji의 이미지

xinetd가 기동할 때 자신이 서비스해야할 internet 서비스와 그에 해당하는 포트들을 모두 bind, listen 하면서 해당 포트로의 connection 요청이 올 경우 fork & exec하는 걸로 알고 있습니다.

따라서 기존의 telnet binary 파일 하나만 가지고도 여러개의 포트로 telnet 서비스가 가능합니다.

아마 services, xinetd 설정 파일에 telnet이 2300번 포트와도 mapping 될 수 있도록 추가한 후 xinetd를 재기동 시키면 될 겁니다.

batmi의 이미지

nohmad wrote:
xinetd라면 설정파일이 /etc/xinetd.d/telnet인데,
1. 같은 디렉토리에 telnet2 정도로 복사하고 파일 내용 중에 telnet을 telnet2로 변경.
2. /etc/services 안에서 telnet 라인을 복사한 다음 telnet2로, 번호를 원하는 포트 번호로 변경.
3. /etc/init.d/xinetd restart

service 파일에 xtelnet 이라는 이름으로 포트는 10023 으로
/etc/xinetd.d/telnet 파일은 xtelnet 으로 복사..
/etc/init.d/xinetd restart .....

위처럼 했는데 안되더라구요..ㅠ_ㅠ

[root@aaa etc]# telnet localhost 10023
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
Connection closed by foreign host.

또 다른 설정이 있을까요??참고로 iptables 는 꺼논 상태입니다.

.
마음을 가꾸는 방법은??

정태영의 이미지

aqua@Macintosh aqua $ cat /etc/xinetd.d/telnet 
service telnet
{
        disable         = yes
        socket_type     = stream
        wait            = no
        user            = root
        server          = /usr/libexec/telnetd
        groups          = yes
        flags           = REUSE
}

service telnet 라인부분을 고치시는게 추가로 필요하죠 ;)

오랫동안 꿈을 그리는 사람은 그 꿈을 닮아간다...

http://mytears.org ~(~_~)~
나 한줄기 바람처럼..

batmi의 이미지

service xtelnet 으로 고쳤는데도 안되더라구요..ㅠ_ㅠ
결국 리붓했더니 되더라구요..ㅠ_ㅠ
/etc/rc.d/init.d/xinetd restart 로는 왜 안됐는지 궁금하네요.^^;;
그럼 좋은하루 되세요~!!

.
마음을 가꾸는 방법은??

^_^의 이미지

/etc/services

telnet 23/tcp
telnet 23/udp
telnet2 33/tcp #추가
telnet2 33/udp #추가

cp /etc/xinetd.d/telnet /etc/xinetd.d/telnet2

vi /etc/xinetd.d/telnet2

# default: on
# description: The telnet server serves telnet sessions; it uses \
# unencrypted username/password pairs for authentication.
service telnet2 #/etc/services 동일한 이름으로 해줘야 된다
{
disable = no # yes -> no 로 해야 작동된다
flags = REUSE
socket_type = stream
wait = no
user = root
server = /usr/sbin/in.telnetd
log_on_failure += USERID
}

service xinetd restart

telnet localhost 33

# telnet localhost 33
Trying 127.0.0.1...
Connected to vmware (127.0.0.1).
Escape character is '^]'.
Red Hat Enterprise Linux AS release 3 (Taroon Update 4)
Kernel 2.4.21-32.0.1.EL on an i686
login:

두둥

----------------------------------------------------------------------
웃는 얼굴 헤죽 헤죽

댓글 달기

Filtered HTML

  • 텍스트에 BBCode 태그를 사용할 수 있습니다. URL은 자동으로 링크 됩니다.
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param><hr>
  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.

BBCode

  • 텍스트에 BBCode 태그를 사용할 수 있습니다. URL은 자동으로 링크 됩니다.
  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param>
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.

Textile

  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • You can use Textile markup to format text.
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param><hr>

Markdown

  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • Quick Tips:
    • Two or more spaces at a line's end = Line break
    • Double returns = Paragraph
    • *Single asterisks* or _single underscores_ = Emphasis
    • **Double** or __double__ = Strong
    • This is [a link](http://the.link.example.com "The optional title text")
    For complete details on the Markdown syntax, see the Markdown documentation and Markdown Extra documentation for tables, footnotes, and more.
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param><hr>

Plain text

  • HTML 태그를 사용할 수 없습니다.
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.
  • 줄과 단락은 자동으로 분리됩니다.
댓글 첨부 파일
이 댓글에 이미지나 파일을 업로드 합니다.
파일 크기는 8 MB보다 작아야 합니다.
허용할 파일 형식: txt pdf doc xls gif jpg jpeg mp3 png rar zip.
CAPTCHA
이것은 자동으로 스팸을 올리는 것을 막기 위해서 제공됩니다.