summaryrefslogtreecommitdiff
path: root/informationals/teso-i0017.txt
diff options
context:
space:
mode:
Diffstat (limited to 'informationals/teso-i0017.txt')
-rw-r--r--informationals/teso-i0017.txt195
1 files changed, 195 insertions, 0 deletions
diff --git a/informationals/teso-i0017.txt b/informationals/teso-i0017.txt
new file mode 100644
index 0000000..40c621a
--- /dev/null
+++ b/informationals/teso-i0017.txt
@@ -0,0 +1,195 @@
10017 2000/02/25 Information on how to exploit Lancity cablemodems
2
3==== TESO Informational =======================================================
4This piece of information is to be kept confidential.
5===============================================================================
6
7Description ..........: Cablemodems from Lancity are funny.
8Date .................: 2000/02/25 00:00
9Author ...............: zap
10Publicity level ......: unknown
11Affected .............: LCPet10, probably the whole product-family
12Type of entity .......:
13Type of discovery ....:
14Severity/Importance ..: medium, since not usable by script-kiddies
15Found by .............: zap
16
17Prelude =======================================================================
18
19Lancity Cablemodems are very popular amongst cablenet-providers.
20At least in Austria they are used almost everywhere.
21
22When I started investigating the ugly thing under my desk I found it very hard
23to gain ANY information about these modems, nowadays sold by Nortel Networks.
24
25I've been in my town's cablenet for about a year which is operated by not very
26competent persons, so this information might not be of any or limited use
27in professionally administrated environments.
28
29Basics ========================================================================
30
31The modem uses the very primitive "Internet Boot Protocol" (RFC951, bootpd(8))
32for gaining basic network information like IP-address, netmask, bootserver and
33so on.
34
35From the bootserver it downloads it's configuration-file (RFC1533) via TFTP
36(RFC783, tftp(1), tftpd(8)) which contains a MD5-digest generated from a
3764-byte key. It might also download a upgrade-file after that.
38
39This generally happens on power-up, although I have found my pet reconfiguring
40itself after a while occasionally.
41
42The configuration-file contains information about Tx/Rx-frequencies, bandwidth,
43SNMP-manager-IP's, client-IP's/MAC's, SNMP-community-names and so on.
44
45After the modem is up & running it accepts SNMP-commands from IP's listed as
46managers.
47
48Let's party ...
49
501. SNMP-managing your modem ===================================================
51
52Since the SNMP used doesn't use another authentication than the IP-address and
53the SNMP-community-name (which is often something like 'private'), it's easy
54to modify and read some interesting values, where most of them are related to
55filters. Some networks allow IP only so it's not possible to use other
56protocols such as IPX (lots of games) - this behaviour can be changed.
57
58Note that it's generally a good idea to disconnect the modem from the rest of
59the net while doing this because the manager is very often a Windows-box which
60are known to start crying upon a IP-conflict - causing a perceived IP-conflict
61would be like calling your provider and telling him that you're having fun with
62your modem.
63
64However if you're sure nothing will happen you can also change the settings
65of other modems.
66
67Finding a manager-IP is quite easy (at least in my case, I'm not sure if it's
68the same everywhere), just watch the network-traffic: If there is some host
69which is periodically pinging modems it is a manager.
70Use it's IP (and eventually MAC) to SN-manage your modem.
71
72IMHO this should work in most of the cases, let's get to something
73really interesting:
74
752. Configuring your modem from ground-up ======================================
76
77As I said, the configuration-files contains a MD5-digest.
78I have found some providers using the default-key that comes with the lc-modems
79(including my provider), so I assume that this is a fact (let me know if I'm
80wrong). I have tried to change my modem's key once and I didn't succeed -
81maybe it ain't possible at all? (not likely)
82
83If you're able to produce a valid config-file for your modem you can do magic
84things like expanding your modem's bandwidth to 10mbit, increasing your net-
85work priority and so on.
86
87Let's assume you've got your modems "secret" key for now.
88
89You'll need a config-file (no matter if cleartext or binary, since you can
90decode the binaries) used in your network.
91
92Attempt to tftp to the manager and request files like 1.cfg, 1.md5, test.md5
93and so on; Be creative.
94The file-naming depends on your provider, but they most likely use some
95file-name which is somehow related to your ip, your name, your modem's ip or
96something. You don't actually need _your_ configuration, any would do.
97Some also run quite braindead TFTP-daemons, try to request ../autoexec.bat
98for example - if this works you might be able to retrieve other useful
99information (as for example the non-standard key!).
100
101Another way would be to try sniffing TFTP-requests from your or other modems
102to find out filenames, try unplugging the network-side while your modem is
103booting (check the leds) and see if it sends the request to your side.
104
105If your modem requests a file like '212.md5' chances are big that you'll be
106able to request '212.cfg' from the manager's tftpd (although you don't
107necessarily need the cleartext-file).
108
109Once you got the needed information, download the modem's update-file from the
110manager (if mentioned in the cfg) via TFTP, build a valid config-file, encode it
111and try to feed it to your modem:
112
113Configure a bootpd-server (see bootpd(8)), edit your bootptab (see bootptab(5)),
114set up your tftpd and copy the needed files there.
115
116The bootptab-entry for my modem looked like this:
117
118mypet:ht=ether:ha=0000CA066166:bf=mypet.md5:ip=10.10.0.15:sm=255.0.0.0:to=3600:sa=10.0.0.58
119
120ha: ethernet-address, you'll get this by watching the network-traffic
121bf: md5-encoded bootfile
122ip: your modem's ip (use the ip your provider gave your modem!!)
123sm: subnet-mask
124to: timeout
125sa: tftp-server to be used (your box!)
126
127I noticed that my modem always prepended the bootfile-name with a '/', so the
128tftpd-server didn't serve the file the modem wanted, however a small hack to
129tftpd made this work.
130
131Once you get this running (watch the LEDs) you've won. You can modify the
132modem's behaviour to your wishes.
133
134Once again, DON'T CHANGE your modem's or your ip-address. Even if you've got
135dumb administrators they will catch you someday (I can tell from experience).
136Another good idea is NOT to open your modem (=breaking the seal) cause even
137if they get suspicious and want the modem back they won't be able to prove that
138you've manipulated the modem.
139
140Pretty wild, but let's push it a little further...
141
1423. Making your modem half-promicious ==========================================
143
144This one is quite tricky.
145It's very important that your modem forwards any data with any MAC&IP-address
146from your side to the network - this can be easily done by reconfiguring your
147modem (set MaxNodes > 1, ClientEnetAddr & ClientIpAddr to all 0's).
148I might have used a special sniff-configuration where the gateway and my box
149were the only allowed clients - I can't clearly remember this, you'll have to
150try both variations.
151
152Ok, this is how it's done:
153
154- Power-off the modem
155
156- Start sending some data (I think I used ICMP-pings) with the *SAME* MAC
157 and IP as the gateway (or the host you want to sniff) has
158
159- Power-on the modem
160
161- Configure it as described in 2.
162
163- Stop sending data after a while
164
165I remember that the timing was very vital to perform this correctly! If it
166works you'll immediately see LOTS of network-traffic.
167
168My theory on how this works:
169The modem communicates with a so-called Head-End-Controller (read the Lancity-
170docs) and it tells the controller which IP and MAC (I think the MAC is
171essential) it's client(s) has. The controller routes all the stuff for this MAC
172to your segment, where your modem will again route it thankfully to you.
173
174This is why I call it "half-promicious" - you'll only get the stuff that other
175clients send to the gateway, not the other direction.
176However one way of the traffic is enough to sniff. Simply patch tcpdump a
177little to log anything you've ever wanted to know about your neighbours.
178
179In a earlier state of investigation I found out that sending faked ARP-queries
180(you, with the same MAC & IP as the gateway, want to know the MAC of some dummy
181host) made the modem route stuff on the cable destinating to the gateway
182to you. The disadvantage is that you'll only get stuff which is on your segment
183only and this might be very little interesting data.
184
185Appendix ======================================================================
186
187This document might be slightly inaccurate, but it all worked for me.
188I'm very curious about feedback, corrections and clarifications.
189The needed files (cfg-file-en/decoder, snmp-vars-documentation, general lcpet-
190documentation, patched tftpd, default-key, sample-cfg's etc.) should be
191available as teso-lancity-x.x.tar.gz in teso's internal file-area.
192
193Have fun.
194
195===============================================================================