Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

How can I telnet from Windows to my server by MAC address?

C:\Users\Asep>telnet D4:CA:6D:46:C9:98 23
Connecting To D4:CA:6D:46:C9:98...Could not open connection to the host, on port 23: Connect failed
share|improve this question
4  
What would make you think you could connect to TCP port via a MAC address? I'd suggest you read up a little on the ISO/OSI or TCP/IP model and where the MAC sublayer and TCP fit in. –  slhck May 20 '13 at 9:09
    
@slhck i have router OS mikrotik i want to macc telnet from windows, i see on OSI no TCP for mac telnet –  Asep Saepuloh May 20 '13 at 9:32
3  
You cannot do that. The TCP port 23 is at a much higher level than the MAC address (which is, simply put, only used to identify a device in your current network). As grawity said you'd first have to find out which IP address the device with the given MAC address has, and then connect to that. –  slhck May 20 '13 at 9:38
    
@slhck he did say "to his server" so it may well often be on his current network. I would note that TCP port is quite a bit higher than IP address too. hostnames are quite a bit higher than ips.. I don't think this higher/lower thing is that useful(or perhaps even that relevant) here. Just that the frame is discarded when/if a packet is routed. –  barlop May 20 '13 at 11:07
add comment

3 Answers

I'm going to take a risk here and say.. Yes you can. In the same sense that you can telnet to a hostname.

Some people are saying you can't 'cos one says "Telnet is a Layer 3 network protocol. " I don't think that's correct, for one thing, telnet is an application layer protocol, that's layer 7. IP or IPX or whatever else, is the layer 3 network layer protocol. But that's not even relevant.

The whole layer concept is not useful here. It's used to identify different headers, and to identify which bunches of headers are stripped off and added(encapsulation).

The "packet" and by that I mean the whole lot(not just the layer 3). But looking at the whole thing all the fields. There's an IP address and a MAC address. You have to know a lot of things to get the packet sent. The application layer protocol(telnet), the TCP port, the IP address. In theory, you can telnet to a host given a MAC address, by getting the IP address. Just as you can telnet to a host given a hostname (you'd take the hostname and get the ip address). And just as you can get an IP from a hostname, one can also(though in a different way) get the IP given a MAC address.

RARP http://en.wikipedia.org/wiki/Reverse_Address_Resolution_Protocol it's apparently allegedly obsolete now(according to the first line of that wikipedia article) though I see the arp command on windows 7 and no doubt ARP is still used. RARP goes MAC->IP (getting IP from a MAC address). As opposed to ARP which goes IP->MAC (getting MAC address from IP). Just as you have DNS and rDNS.. that get you between IP addresses and hostnames. So too ARP and RARP get you between IP addresses and MAC addresses. So just as you can telnet to a hostname, you can with a similar principle, in theory, telnet to a host with a MAC address. Maybe that program you mention (mactelnet) does that.

ADDED I haven't got telnet on this machine but here's an example with a script

C:\blah>mactelnet 01-00-5e-00-00-16
Telnet 224.0.0.22
'Telnet' is not recognized as an internal or external command,
operable program or batch file.

C:\blah>

mactelnet.bat has one line

@for /f "tokens=1-5" %%f  in ('arp -a') do @IF "%%g"=="%1" Echo Telnet %%f & Tel
net %%f & EXIT /B

And as I said to ramhound " there is a 1-1 relationship [between ip and mac address], try the command arp -a The only limitation is it'd only apply locally. ARP or RARP won't tell you the ip address for a MAC address on a different subnetwork. You'd need your own list for that to do the conversion if you want to go beyond the local subnetwork. But locally the command arp -a will tell you in windows"

Also the OP mentioned a program http://tulas-tulis.com/blog/detail/mactelnet-from-linux-to-router-mikrotik

share|improve this answer
    
You say its possible but don't show him how. –  Ramhound May 20 '13 at 10:32
    
@Ramhound well, I suppose one could write a script to go from MAC address to IP address and telnet. But he provided a link of a program that does it, called mactelnet tulas-tulis.com/blog/detail/… and by the way i'm not saying anything that different to what people that said "theoretically and practically no you need an ip address" said. I'm just being more philosophically correct I think, in saying theoretically yes, just as you can telnet to a hostname. i.e. no reason why you can't. e.g. with a script or that app he mentioned himself. –  barlop May 20 '13 at 10:33
2  
@Ramhound there is a 1-1 relationship, try the command arp -a The only limitation is it'd only apply locally. ARP or RARP won't tell you the ip address for a MAC address on a different subnetwork. You'd need your own list for that to do the conversion if you want to go beyond the local subnetwork. But locally the command arp -a will tell you in windows. –  barlop May 20 '13 at 10:38
    
@Ramhound just added a script. –  barlop May 20 '13 at 11:13
add comment

Simply put, you cannot. You will need to find out the IP address for that device.

share|improve this answer
    
Yup thank's All i have reference from the site tulas-tulis.com/blog/detail/…, But mactelnet from linux, Thank's All –  Asep Saepuloh May 20 '13 at 9:47
add comment

You simply can't telnet by mac-address. You need the IP address. Telnet is a Layer 3 network protocol. Mac-addresses are Layer 2.

The tool mentioned on that webpage you linked to in the comment (mactelnet) is not really telnet.

It looks like telnet, but uses a non-standard Layer2 protocol invented by the manufacturer of the router. It only works with those routers and the software supplied by the manufacturer.
It will not work on anything else.

Besides: Are you sure your server will actually accept telnet ?
Telnet is completely depreciated as it will send everything (including passwords) in plain text over the network.
Because of that these days most servers don't do telnet anymore. SSH is the new terminal protocol of choice.

share|improve this answer
    
re your second sentence, actually, telnet is a layer 7 application layer protocol. And any application layer protocol works with some layer 3 network protocol. –  barlop May 20 '13 at 11:11
    
@barlop That is a bit nitpicking isn't it ? I meant to say "telnet uses L3" which in daily parlance is often rendered as "is a L3 protocol". Anyway if you start like that... You are mixing the 7 layer full OSI model and the 4 layer simplified model. In this case telnet should have been classified as a L4 protocol. In the TCP/IP world the 4-layer simplified model more closely resembles the real life implementation than the full 7-layer model and it is therefore preferable to be used. –  Tonny May 20 '13 at 12:17
    
I am not sure if even your current phrase, "telnet uses L3" would be common parlance, for a start any application layer protocol (e.g. Telnet which is layer 7), would work with L3, telnet is no different to any other app layer protocol in that regard, so I can't see anybody saying what you just wrote either, or my more accurate rendition of what you wrote. You write "You are mixing the 7 layer full OSI model and the 4 layer simplified model" Actually not really no and if I was then you'd be too, but i'm not. There is such a thing as using the OSI as a reference model –  barlop May 20 '13 at 20:44
    
Using the OSI -reference model- is distinct from speaking of the OSI architecture(an unused thing). It is common place as you know, to use the OSI reference model, to refer to the TCP/IP architecture. There is no contradiction or confusing or mixing things up in doing that. Use of OSI terminology there is strictly using OSI as a reference model, not as an architecture(which is what you were doing or trying to do, and that's fine). And I wouldn't say as you do that one "model" is "full" and one "simplified", that suggests one came from the other, but that's not so, as you probably know. –  barlop May 20 '13 at 20:49
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.