@@ -14,9 +14,13 @@ a lot of damage you can do with the IPX protocol nowadays but there's still the
14
14
possibility that if you use this on a public server, you might be exposing
15
15
something on your network that you don't intend to.
16
16
17
- There are two ways to set things up: ` ipxbox ` can either create a TAP device
18
- (use ` --enable_tap ` ) or use ` libpcap ` to connect to a real Ethernet device.
19
- If you don't know what this means, you'll want to use the ` libpcap ` approach.
17
+ There are two ways to set things up: ` ipxbox ` can either create a
18
+ [ TAP device] ( https://en.wikipedia.org/wiki/TUN/TAP ) or use
19
+ [ ` libpcap ` ] ( https://en.wikipedia.org/wiki/Pcap )
20
+ to connect to a real Ethernet device. If you don't know what this means,
21
+ you'll want to use the ` libpcap ` approach.
22
+
23
+ ## Bridging with libpcap
20
24
21
25
Find out which Ethernet interface (network card) you want to use by using the
22
26
Linux ` ifconfig ` command. Usually the interface will be named something like
@@ -29,9 +33,9 @@ sudo setcap cap_net_raw,cap_net_admin=eip ./ipxbox
29
33
```
30
34
On other systems (BSD, etc.) only the ` root ` user can access raw sockets.
31
35
32
- Next run ` ipxbox ` with the ` --pcap_device ` argument, eg.
36
+ Next run ` ipxbox ` with the ` --bridge ` argument, eg.
33
37
```
34
- ./ipxbox --port=10000 --pcap_device= eth0
38
+ ./ipxbox --port=10000 --bridge=pcap: eth0
35
39
```
36
40
If working correctly, clients connecting to the server will now be bridged to
37
41
` eth0 ` . You can test this using ` tcpdump ` to listen for IPX packets and
@@ -47,6 +51,39 @@ listening on eth0, link-type EN10MB (Ethernet), capture size 262144 bytes
47
51
05:08:48.888311 IPX 00000000.02:cf:0d:86:54:e5.0002 > 00000000.02:ff:ff:ff:00:00.0002: ipx-#2 0
48
52
```
49
53
54
+ ## Using a TAP device
55
+
56
+ To use TAP instead of pcap, specify ` --bridge=tap ` instead. For example:
57
+ ```
58
+ ./ipxbox --bridge=tap
59
+ ```
60
+ creates a new network device while the server is running:
61
+ ```
62
+ $ ifconfig -a
63
+ tap0: flags=4098<BROADCAST,MULTICAST> mtu 1500
64
+ ether 9e:db:a8:4b:d2:19 txqueuelen 1000 (Ethernet)
65
+ RX packets 0 bytes 0 (0.0 B)
66
+ RX errors 0 dropped 0 overruns 0 frame 0
67
+ TX packets 0 bytes 0 (0.0 B)
68
+ TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
69
+ ```
70
+ Note that the TAP device will be down by default and you will need to bring
71
+ it up yourself with ` ifconfig tap0 up ` .
72
+
73
+ You can also specify the name; for example:
74
+ ```
75
+ ./ipxbox --bridge=tap:blerg
76
+ ```
77
+ produces:
78
+ ```
79
+ $ ifconfig -a
80
+ blerg: flags=4098<BROADCAST,MULTICAST> mtu 1500
81
+ ether 16:91:8d:c6:d1:4c txqueuelen 1000 (Ethernet)
82
+ RX packets 0 bytes 0 (0.0 B)
83
+ RX errors 0 dropped 0 overruns 0 frame 0
84
+ TX packets 0 bytes 0 (0.0 B)
85
+ TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
86
+ ```
50
87
## Configuring frame type
51
88
52
89
After following the above instructions you might find problems getting a
@@ -69,7 +106,7 @@ the first thing to check.
69
106
format can be changed by using the ` --ethernet_framing ` command line flag.
70
107
For example:
71
108
```
72
- ./ipxbox --port=10000 --pcap_device= eth0 --ethernet_framing=eth-ii
109
+ ./ipxbox --port=10000 --bridge=pcap: eth0 --ethernet_framing=eth-ii
73
110
```
74
111
75
112
| ` --ethernet_framing ` value | Description | Notes |
@@ -151,37 +188,45 @@ problems you can disable autodetection and manually specify it.
151
188
| ` snap ` | Ethernet 802.2 SNAP | 802.3 with 802.2 LLC and SNAP headers |
152
189
| ` eth-ii ` | Ethernet II | Ethernet II |
153
190
154
- ## Advanced topic: TCP/IP over IPX
191
+ ## Advanced topic: TCP/IP over IPX (ipxpkt)
155
192
156
193
Much DOS software that communicates over the network (particularly using the
157
194
TCP/IP protocol stack used on the Internet) uses the
158
195
[ packet driver] ( https://en.wikipedia.org/wiki/PC/TCP_Packet_Driver ) interface.
159
196
There are packet drivers available for most network cards, providing a
160
197
standard interface for sending and receiving data over the network.
161
-
162
198
Some forks of DOSbox can emulate the Novell NE2000 card, allowing such
163
199
software to be used. However, vanilla DOSbox at the time of writing does not
164
200
include this feature. Furthermore, it typically requires granting DOSbox
165
201
special permission to be able to send and receive raw network packets.
166
- The [ ` ipxpkt.com ` ] ( ipxpkt/driver/ ) driver is a packet driver that tunnels an
167
- Ethernet link over IPX packets, and ipxbox includes support for its protocol.
168
- This allows DOSbox users to use packet driver-based software.
202
+
203
+ The [ ` ipxpkt.com ` ] ( module/ipxpkt/driver/ ) driver is a packet driver that
204
+ tunnels an Ethernet link over IPX packets, and ipxbox includes support for its
205
+ protocol. This allows you to use packet driver-based software from within
206
+ vanilla DOSbox; you can [ see a demo video
207
+ here] ( https://www.youtube.com/watch?v=5VeVaFbORhI ) .
169
208
170
209
** First, a word of warning** : the DOSBox IPX protocol is completely insecure.
171
210
There's no encryption or authentication supported, and enabling this feature
172
- gives a potential backdoor into the network where the ipxbox server is running.
173
- If you don't understand the implications of this, don't enable this feature
174
- on a public-facing ipxbox server.
211
+ gives a backdoor into the network where the ipxbox server is running. If you
212
+ don't understand the implications of this, don't enable this feature on a
213
+ public-facing ipxbox server.
175
214
176
215
To use this feature:
177
216
178
- 1 . First set up an IPX bridge by following the instructions from the previous
179
- section.
217
+ 1 . Install the [ ` libslirp-helper ` ] ( https://packages.debian.org/sid/libslirp-helper )
218
+ package (on Debian; it is available on other Linux distros too).
219
+
220
+ - libslirp provides a connection to a simulated network without
221
+ requiring any special permissions. Alternatively, you can bridge the
222
+ ipxpkt packets to a real, physical network. Follow the instructions
223
+ from the previous section about setting up an IPX bridge, but use the
224
+ `--ipxpkt_bridge` flag instead of `--bridge`.
180
225
181
226
2 . Read the warning in the paragraph above this list. Then add
182
227
` --enable_ipxpkt ` to the ipxbox command line. For example:
183
228
```
184
- ./ipxbox --port=10000 --pcap_device=eth0 -- enable_ipxpkt
229
+ ./ipxbox --port=10000 --enable_ipxpkt
185
230
```
186
231
3 . Start a DOSbox client and connect to the server as normal. Make sure to
187
232
mount a directory containing the [ ` ipxpkt.com ` ] ( ipxpkt/driver/ ) driver.
@@ -204,8 +249,9 @@ My Ethernet address is 02:57:04:31:68:FA
204
249
C:\>
205
250
```
206
251
5 . Test the connection is working correctly by trying some software that uses
207
- the packet driver interface. The [ mTCP stack] ( http://www.brutman.com/mTCP/ )
208
- makes for a good first step. For example:
252
+ the packet driver interface (but don't use ` ping ` because it won't work in
253
+ Slirp). The [ mTCP stack] ( http://www.brutman.com/mTCP/ ) makes for a good first
254
+ step. For example:
209
255
```
210
256
C:\>set mtcpcfg=c:\mtcp\mtcp.cfg
211
257
C:\>dhcp
@@ -220,26 +266,40 @@ DHCP request sent, attempt 1: Offer received, Acknowledged
220
266
221
267
Good news everyone!
222
268
223
- IPADDR 192.168.128.45
224
- NETMASK 255.255.0 .0
225
- GATEWAY 192.168.60.1
226
- NAMESERVER 8.8.8.8
269
+ IPADDR 10.0.2.15
270
+ NETMASK 255.255.255 .0
271
+ GATEWAY 10.0.2.2
272
+ NAMESERVER 10.0.2.3
227
273
LEASE_TIME 86400 seconds
228
274
229
275
Settings written to 'c:\mtcp\mtcp.cfg'
230
276
231
- C:\>ping 8.8.8.8
277
+ C:\>ftp ftp.freebsd.org
232
278
233
- mTCP Ping by M Brutman ([email protected] ) (C)opyright 2009-2020
234
- Version: Mar 7 2020
279
+ mTCP FTP by M Brutman ([email protected] ) (C)opyright 2008-2025
280
+ Version: Jan 10 2025
281
+
282
+ FTP server resolved in 0.00 seconds
283
+
284
+ Opening control connection to 96.47.72.116:21 with local port 1914
285
+ Connected
235
286
236
- ICMP Packet payload is 32 bytes.
287
+ 220 This is ftp0.nyi.freebsd.org - hosted at NYI.net.
288
+ Userid: anonymous
289
+ 331 Please specify the password.
290
+ Password:
291
+ 230-
292
+ 230-This is ftp0.nyi.FreeBSD.org, graciously hosted by
293
+ 230-365 Data Centers - 365DataCenters.com
294
+ 230-
295
+ 230-FreeBSD files can be found in the /pub/FreeBSD directory.
296
+ 230-
297
+ 230 Login successful.
237
298
238
- Packet sequence number 0 received in 45.90 ms, ttl=114
239
- Packet sequence number 1 received in 44.20 ms, ttl=114
240
- Packet sequence number 2 received in 41.65 ms, ttl=114
241
- Packet sequence number 3 received in 54.40 ms, ttl=114
299
+ Setting the server file transfer mode to BIN
300
+ 200 Switching to Binary mode.
301
+ File transfer mode set to BIN.
242
302
243
- Packets sent: 4, Replies received: 4, Replies lost: 0
244
- Average time for a reply: 46.53 ms (not counting lost packets)
303
+ --> quit
304
+ 221 Goodbye.
245
305
```
0 commit comments