Debian Codegraph @

CHANGES

raw
1 
2 ####################### V 1.8.1.1:
3
4 Corrections:
5 Socat with options -v or -x showed incorrect timestamps (microseconds
6 in decimal position of nanoseconds).
7 There was a related commit in 1.8.1.0, but it did not contain the fix.
8 Thanks to David Šmíd for fixing this issue.
9
10 Fixed issue with POSIXMQ in unidirectional context.
11
12 Fixed a few buffer read overruns detected on CheriBSD.
13
14 Porting:
15 glibc-2.43: strchr with const
16 Thanks to Khem Raj, Holger Hoffstätte and others for providing patches.
17
18 Avoid 'int' vs. 'void *' compilation issue in xio-netlink.c caused by
19 explicit padding on Musl libc.
20 Thanks to Hongxu Jia and others for reporting this issue.
21
22 ####################### V 1.8.1.0:
23
24 Features:
25 Implemented new address STALL that never sends data or EOF, and never
26 gets ready to write data.
27 Tests: STALL_RD STALL_WR
28
29 Added option termios-setflags (setflags) to set the termios tcflags.
30
31 Added address TEXT that takes a string from command line as input data;
32 output is sent to STDOUT.
33 Test: TEXT_STDOUT
34
35 Added option ipv6-multicast-loop (ipv6-mcloop, mcloop6).
36
37 Added option interface-mtu (if-mtu) to set the MTU of TUN and INTERFACE
38 addresses.
39 Test: TUN_MTU
40 Feature proposed by Baldur Gislason
41
42 Address SHELL now can be used without argument to provide an
43 interactive shell.
44 Test: INTERACTIVE_SHELL
45
46 Added SOCKS5 client user,password authentication with (old socks4)
47 option socksuser and new option sockspass
48 Test: SOCKS5_USER_PASS
49
50 Added option ipv6-mtu-discover.
51 Thanks to Ondřej Martinek for sending the patch.
52
53 New option tiocswinsz (winsz) (pre)sets size of pseudo terminal (PTY).
54 Test: TIOCSWINSZ
55
56 Filan queries and prints terminal size (window size) using
57 ioctl(TIOCGWINSZ).
58
59 Filan: new option -W keeps it running and makes it print the FD infos
60 on SIGWINCH, useful for watching changes of terminal size (window
61 size).
62
63 Filan tries to show more info on dynamic file descriptor states
64 (FIONREAD etc.)
65
66 Program invocation (EXEC, SHELL, SYSTEM) with option pty now support
67 option symbolic-link (link).
68 Feature proposed by Dmitry Koterov.
69
70 Corrections:
71 Fixed possible SIGSEGV after failed getprotobynumber_r() .
72
73 Fixed minor issues with child process counter.
74
75 Address EXEC had a realloc() based heap overflow when the sub command
76 had 8 components and had length 48..63 bytes. On some versions of
77 FreeBSD, NetBSD and MacOSX this could produce a failure:
78 E execvp("", "", "arg1", "arg2", ...): No such file or directory
79 Test: EXEC_REALLOC
80
81 Socat crashed with addresses like IP-RECV:17 because some routine
82 assumed existance of a bind address as with UDP.
83 Test: IP_RECV_17
84
85 PTY generated per /dev/ptmx (or /dev/ptc) instead of openpty() might
86 not have gotten all address options (esp.AIX).
87
88 In version 1.8.0.3 SOCKS4 and SOCKS4a without option sockdport failed
89 with something like:
90 E getaddrinfo(...): Servname not supported for ai_socktype
91
92 SOCKS4 addresses could SIGSEGV when peer sent TCP-RST during initial
93 dialog.
94 Test: SOCKS4_SIGSEGV
95
96 Option posixmq-priority had been implemented as boolean and thus only
97 the values 0 or 1 were applied.
98
99 Address POSIXMQ now refuses bidirectional mode to prevent unwanted
100 flushing of queue; use POSIXMQ-BIDIRECTIONAL when needed.
101
102 Deactivated explicit printing of newline on empty READLINE input line.
103
104 When CREATE is used in read-only context it now refuses to truncate or
105 create file.
106
107 Fixed bind option with VSOCK: do not try to resolve vsock id
108 (regression after 1.8.0.0).
109
110 EXEC with leading space tried to invoke program with empty name.
111 Now it skips leading space.
112
113 Socat with options -v or -x showed incorrect timestamps (microseconds
114 in decimal position of nanoseconds).
115 Thanks to David Šmíd for reporting and fixing this issue.
116
117 Address GOPEN per default applies the O_APPEND flag; however, the
118 option o-append=0 had no effect.
119 Test: GOPEN_NO_APPEND
120
121 Options min-proto-version and max-proto-version were documented but
122 available only as openssl-min-proto-version etc.
123 Now bother forms are documented and available.
124 Thanks to Matt Panaro and Stefan Rieche for reporting this issue.
125
126 Porting:
127 Changed Ioctl() request from int to unsigned long to prevent ioctl
128 sign-extension console warnings on 32bit BSD systems.
129 And see htps://bugzilla.kernel.org/show_bug.cgi?id=42705 for discussion.
130
131 PTYs on Solaris require use of STREAMs.
132 Test: SOLARIS_PTY
133
134 Modifications for: gcc -std=c99 --pedantic
135
136 Documentation:
137 Improved documentation of POSIXMQ options.
138
139 Testing:
140 A few tests required to be run in tty/pty.
141
142 test.sh: New option -Z, tests only up to this number.
143
144 test.sh: Many corrections.
145
146 Made test.sh work on Solaris with bad PATH
147
148 test.sh: AIX grep understands [[:blank:]] but not \< \>
149
150 Fixed some testing issues for MacOSX
151
152 Improved test.sh for systems without ping, without /etc/services, with
153 empty $USER .
154 Proposed by Maxim Cournoyer for GNU Guix
155
156 More minor corrections of test.sh
157
158 A few tests fail when performed by almighty root, rate this as "cant".
159
160 Options -N and -Z may now be combined to select a range
161 New option -X <num> to exclude a test
162
163 ####################### V 1.8.0.3:
164
165 Security:
166 readline.sh has new option -lf <logfile> for stderr. If this option is
167 not given it logs to a file in . (cwd) only when . is not writable by
168 other users.
169
170 Corrections:
171 Flixed display of option phases in help output.
172
173 filan -s displayed "(stream)" instead of "tcp" with addresses
174 (regression).
175
176 Fixed a bug that made ignoreeof fail in 1.8.0.0 and 1.8.0.1;
177 corrected test IGNOREEOF.
178 Thanks to Rusty Bird for the precise problem report.
179
180 Fixed the regression introduced with version 1.8.0.1 that in socks5
181 addresses the explicit socksport (2nd address parameter) was ignored.
182 Thanks to Jakub Fišer for reporting this bug.
183
184 Do not log simple successful write with NOTICE level.
185
186 On partial write do not poll with sleep() but use select()/poll().
187
188 Partial write situations respect total inactivity timeout when
189 nonblocking.
190
191 Fixed a bug that could lead to error "xiopoll(...): Bad file descriptor"
192 or to undefined behaviour before terminating Socat with addresses EXEC,
193 SYSTEM, or SHELL.
194
195 Option ip-add-source-membership did not work.
196 Thanks to Duncan Sands and others for reporting this issue and sending
197 the fix.
198
199 Option ip-add-membership with only two parameters crashed or failed
200 when malloc() does not initialize memory with zeros.
201 Thanks to Nicolas Cavallari for reporting and fixing this bug.
202
203 The readline() library function does not output the newline of empty
204 input lines. Changed Socat to explicitly print the newline in this
205 case.
206
207 Fixed implementation of options o-creat, o-excl, and o-cloexec with
208 POSIXMQ-* addresses.
209 POSIXMQ addresses are no longer experimental.
210
211 With version 1.8.0.0, and with 1.8.0.1 and option -0, the following
212 command failed:
213 socat UDP-LISTEN:1234,fork,reuseaddr,bind=127.0.0.1 -
214 Message: "E xioopen_ipdgram_listen(): unknown address family 0":
215 Thanks to Brian Woo for reporting this issue.
216 Test: UDP_LISTEN_BIND4
217
218 Protected SSL_connect() from SIGCHLD,SIGUSR1.
219
220 Nanosleep() trace output now in decimal form.
221
222 UNIX-LISTEN with bind option terminated with INTERNAL error, this is
223 now handled properly.
224 Test: UNIX_L_BIND
225
226 Removed unused bytes variable from gettimestamp(), corrected #elsif,
227 and socks4 record length.
228 Thanks to clang-18 and gcc-13.
229
230 Address TCP-CONNECT, when target address resolves to both IPv4 and
231 IPv6, now tries to take into account bind address for protocol
232 selection.
233
234 Reworked and harmonized ipapp client addresses.
235 Tests: TCP_CONNECT_RETRY SCTP_CONNECT_RETRY DCCP_CONNECT_RETRY
236 OPENSSL_CONNECT_RETRY SOCKS4_RETRY SOCKS5_CONNECT_RETRY
237 PROXY_CONNECT_RETRY
238
239 Socks and proxy clients now also support option max-children.
240 Tests: TCP_CONNECT_MAXCHILDREN SCTP_CONNECT_MAXCHILDREN
241 DCCP_CONNECT_MAXCHILDREN OPENSSL_CONNECT_MAXCHILDREN
242 SOCKS4_MAXCHILDREN SOCKS5_CONNECT_MAXCHILDREN PROXY_CONNECT_MAXCHILDREN
243
244 On failure of getpwuid() (used in options su and su-d) now consider
245 errno.
246
247 When IP4 was completed deconfigured, UDP6-RECVFROM with range option
248 failed.
249
250 Fixed preprocessor directives in macro invocation.
251 Thanks to Mario de Weerd for reporting this issue.
252
253 CONNECT addresses could use a wrong IPPROTO when getaddrinfo() does not
254 support the selected one (at least on Debian-4 with SCTP).
255
256 socat -h (help) did not show option groups POSIXMQ, SCTP, DCCP, and
257 UDPLITE of addresses.
258
259 Features:
260 POSIXMQ-RECV now takes option o-nonblock; this, in combination with -T,
261 makes it possible to terminate Socat in case the queue is empty.
262
263 New option posixmq-flush (mq-flush) for POSIXMQ addresses empties the
264 queue before starting to transfer data.
265 Test: LINUX_POSIXMQ_FLUSH
266
267 New options posixmq-maxmsg, posixmq-msgsize.
268 Tests: POSIXMQ_MAXMSG POSIXMQ_MSGSIZE
269
270 POSIXMQ is now an alias for POSIXMQ-BIDIRECTIONAL. It can also be used
271 in unidirectional context.
272
273 Procan uses getresuid() and getresgid() when available, to determine
274 the saved set-user-ID.
275
276 Procan prints more C-defines, esp.O_*, AI_*, EAI_*; __GLIBC__;
277 prints some C-defines in oct and hex;
278 added option -V
279
280 Procan tells if char is signed or unsigned
281
282 Socat now prints an info message when implicitly setting SO_REUSEADDR.
283 Thanks to Michael Renner for this suggestion.
284
285 Added generic options setsockopt-socket and setsockopt-connected that
286 are applied after socket() or when connected.
287
288 POSIXMQ addresses now print a warning when options posixmq-maxmsg or
289 posixmq-msgsize were not applied.
290
291 New address POSIXMQ-WRITE does the same as POSIXMQ-SEND, as counterpart
292 of POSIXMQ-READ.
293
294 Building:
295 Disabling certain features during configure could break build process.
296
297 Again fixes a few disable problems.
298
299 Porting:
300 Fix for old FreeBSD.
301
302 Fixes for old Debian
303
304 Fixes for old Scientific/RHEL
305
306 Socat failed to build on platforms without flock() function (AIX,
307 Solaris) due to a missing guard.
308
309 Newer Linux distributions do not provide libwrap: do not leave unused
310 variable.
311
312 Newer Linux distributions deprecate usleep, replace it.
313
314 OpenSSL-3 loudly deprecates some functions or macros, replace a first
315 bunch of them.
316
317 Fixes for FreeBSD-15 (DCCP)
318
319 Fix for compiling on Solaris-11
320
321 Testing:
322 test.sh produces file results.txt with columns of test numbers, names,
323 and results.
324
325 Fixed a few testing issues.
326
327 Added test script sock5server-echo.sh for SOCKS5-CONNECT and
328 SOCKS5-LISTEN, and appropriate tests.
329 SOCKS5 addresses are no longer experimental.
330 Tests: SOCKS5CONNECT_TCP4 SOCKS5LISTEN_TCP4
331
332 Added a developer test that overwrites malloc'ed memory with non-zeros.
333
334 Newer Linux distributions now deprecate usleep; replaced it in test.sh
335
336 UDPLITE4STREAM was trice, changed one of them to UDPLITE6STREAM.
337
338 Catch problems caused by ISPs that filter *.dest-unreach.net records.
339
340 Documentation:
341 Removed obsolete CHANGES.ISO-8859-1 file.
342
343 Corrected lots of misspelling and typos.
344 Thanks to Mario de Weerd for reporting these issues.
345
346 Improved README file.
347
348 Better explained benefit of UDP-DATAGRAM address type.
349
350 ####################### V 1.8.0.2:
351
352 Security:
353 Socat security advisory 9
354 CVE-2024-54661: Arbitrary file overwrite
355 Socat 1.6.0.0 through 1.8.0.1 and version 2 distributions contain a
356 wrapper script "readline.sh" that uses a predictable temporary
357 directory, allowing unprivileged users to overwrite arbitrary files
358 belonging to the scripts caller.
359 This is fixed in Version 1.8.0.2
360 Mitigating factors: readline.sh is usually neither installed in a bin
361 directory nor is it documented. Major Linux distributions install it in
362 examples/ or doc/; however it is invoked by test.sh script.
363 Thanks to Wolfgang Frisch from SuSE for finding and reporting this
364 issue.
365 Test: READLINE_SH_OVERWRITE
366
367 ####################### V 1.8.0.1:
368
369 Corrections:
370 When no IP version was preferred by environment, option -4/-6, or
371 address option pf, Socat version 1.8.0.0 address TCP-LISTEN did not
372 accept TCP4 connections under BSD family operating systems, but only
373 TCP6. To regain previous behaviour, preferring IP version 4 is now the
374 default. This also fixes some other issues with bind and range options.
375 Thanks to Mike Andrews for reporting this issue.
376 Tests: LISTEN_4 LISTEN_6 V1800_*_RANGE V1800_*_BIND
377
378 Added Socat option -0 to allow version 1.8.0.0 behaviour (no preferred
379 IP version).
380
381 UDP-SENDTO, UDPLITE-SENDTO, and IP-SENDTO addresses now select an IPv4
382 address in case the server name resolves to both IPv4 and IPv6
383 addresses.
384 Tests: V1800_*_SENDTO_RESOLV_6_4
385
386 Guard applyopts_termios_value() with WITH_TERMIOS.
387 Thanks to Kush Upadhyay from Amazon Bottlerocket team for providing the
388 patch.
389
390 In some situations xioclose() was called nested what could cause hanging
391 of OpenSSL in pthread_rwlock_wrlock()
392
393 socat 1.8.0.0 with addresses of type RECVFROM and option fork, where
394 the second address failed to connect/open in the child process, entered
395 a fork loop that was only stopped by FD exhaustion caused by FD leak.
396 Test: RECVFROM_FORK_LOOP
397
398 socat 1.8.0.0 had an FD leak with addresses of type RECVFROM with fork.
399 Test: RECVFROM_FORK_LEAK
400
401 With version 1.8.0.0, options ipv6-join-group and ipv6-join-source-group
402 did not work.
403 Thanks to Linus Luessing for reporting this bug.
404
405 IP-SENDTO and option pf (protocol-family) with protocol name (vs.numeric
406 argument) failed with message:
407 E retropts_int(): trailing garbage in numerical arg of option "protocol-family"
408 Test: IP_SENDTO_PF
409
410 Fixed a possible buffer overrun with long log lines. In fact it does
411 not write beyond end of buffer but lets pass excessive data to the
412 write() function.
413 Thanks to Heinrich Schuchardt from Canonical for reporting and sending
414 a patch.
415
416 Reworked domain name resolution, centralized IPv4/IPv6 sorting.
417
418 Print warning about not checking CRLs in OpenSSL only in the first
419 child process.
420
421 Fixed preprocessor directives in macro invocation.
422 Thanks to Mario de Weerd for reporting this issue.
423
424 Features:
425 Total inactivity timeout option -T 0 now means 0.0 seconds; up to
426 version 1.8.0.0 it meant no total inactivity timeout.
427
428 Changed socat-chain.sh, socat-mux.sh, and socat-broker.sh to work with
429 older Socat versions.
430
431 socat-mux.sh and socat-broker.sh, when run as root, now internally use
432 low (512..1023) UDP ports to increase security.
433
434 Added option ai-all (sets AI_ALL flag of getaddrinfo() resolver)
435
436 Socks5 now also allows syntax without socks port, and supports option
437 socksport.
438
439 Porting:
440 Changes for building and testing on NetBSD
441
442 New Linux distributions dislike egrep, fgrep
443
444 When NETDB_INTERNAL is not available it should be set to -1.
445 Thanks to Baruch Siach for sending a patch.
446
447 On OpenSolaris/Illumos, isastream() is declared only in stropts.h, not
448 in sys/stropts.h
449 Thanks to Andy Fiddaman for sending a patch.
450
451 On latest Illumos, compilation failed due to new unexpected SO_PROTOCOL
452 implementation.
453 Thanks to Andy Fiddaman for sending a patch.
454
455 Building:
456 Makefile.in: procan.o build requires srcdir prefix for explicit source
457 file.
458 Thanks to Hongxu Jia and Andrew Schoolman for providing patches.
459
460 Makefile.in: the CC define for procan.o build failed when CC had more
461 than one word.
462 Thanks to Hongxu Jia for providing an inital patch.
463
464 Testing:
465 Added the optional DEVTESTS feature for developer tests with controlled
466 name resolution to both IPv4 and IPV6 addresses: configure Socat with
467 --enable-devtests, this provides internal resolution of domain
468 dest-unreach.net with host names: localhost-4, localhost-6,
469 localhost-4-6, and localhost-6-4
470
471 test.sh: lots of corrections and improvements
472
473 test.sh: many hardcoded sleep values were replaced by much shorter
474 values tuned to performance of the platform.
475
476 test.sh -D for output of platform/system specific defines (variables)
477
478 test.sh: fixed ss determination; more DEFS
479
480 Documentation:
481 Fixed a lot of typos.
482 Thanks to Solomon Victorino for sending the patch.
483
484 ####################### V 1.8.0.0:
485
486 Security:
487 Socats OpenSSL addresses do not (and never did) check certificate
488 revocation lists (CRLs). Socat now prints a warning about this.
489
490 Features:
491 Added the --experimental option that enables use of features that might
492 change in the future.
493
494 Now warning messages are printed by default. If you want to see only
495 errors and fatals as in previous versions, use option -d0;
496 option -d4 is equivalent to -dddd and to -d -d -d -d
497 The number of warnings has been reduced, e.g.removing a non existing
498 file does in most cases no longer log a warning.
499
500 Added address type internal SOCKETPAIR. This is similar to the unnamed
501 PIPE address (only for internal echoing) but it provides datagram mode
502 (the default) and thus keeps packet boundaries.
503 Tests: SOCKETPAIR_STREAM SOCKETPAIR_DATAGRAM SOCKETPAIR_SEQPACKET
504 SOCKETPAIR_BOUNDARIES
505
506 New option -S <mask> controls catching and logging of signals that are
507 not internally used by Socat.
508 Tests: SIGTERM_NOLOG SIG31_LOG
509
510 Added option ipv6-join-source-group.
511 Thanks to Martin Buck and David Schweizer for sending patches.
512
513 Added option http-version to PROXY-CONNECT address to support servers
514 that are not able to handle HTTP version 1.0
515 Test: PROXY_HTTPVERSION
516 Feature inspired by Robin Palotai.
517
518 New options openssl-maxfraglen and openssl-maxsendfrag for
519 functions/macros SSL_CTX_set_tlsext_max_fragment_length() and
520 SSL_CTX_set_max_send_fragment().
521 Thanks to James Tavares for his contribution.
522
523 Added Info log of resulting OpenSSL max fragment length.
524
525 Implemented options rcvtimeo and sndtimeo, the first of which may be
526 useful to prevent endlessly hanging DTLS connection etablishment.
527 Test: RCVTIMEO_DTLS
528 Feature proposed by Vladimir Nikishkin.
529
530 The file names with -r and -R now may contain environment variable
531 references.
532 Test: VARS_IN_SNIFFPATH
533
534 Socat option --statistics logs final byte and packet counter values
535 before exit. Signal USR1 logs actual values.
536 Tests: OPTION_STATISTICS SIGUSR1_STATISTICS
537
538 Added option sitout-eio to specify a timerange in which EIO on the pty
539 of a sub process is tolerated.
540 Red Hat issue 1853102 related.
541 Thanks to Jonathan Casiot for sending an initial patch.
542
543 Socat now installs as socat1 and is referenced by symbolic link socat,
544 same with man page (socat1.1 by socat.1)
545
546 New option children-shutup[=1|2...] decreases severity of log
547 messages in LISTEN and CONNECT type sub processes.
548 Test: CHILDREN_SHUTUP
549
550 New option retrieve-vlan for supporting VLANs in INTERFACE addresses:
551 Linux normally keeps VLAN tags in outgoing raw packets, but appears to
552 strip them from incoming packets and makes them available in
553 PACKET_AUXDATA ancillary messages only.
554 Up do version 1.7.4.5 Socat did not handle this situation, so the VLAN
555 tags where effectively stripped off incoming packets.
556 With this option Socat restores the VLAN tag.
557 Feature inspired by Zhao Dong.
558
559 Socket option SO_REUSEADDR is now automatically applied to TCP LISTEN
560 addresses. reuseaddr= restores the old behaviour.
561 Tests: TCP4_REUSEADDR OPENSSL_6_REUSEADDR REUSEADDR_NULL
562
563 TCP based client addresses now try all results of name resolution until
564 a connection attempt succeeded.
565 Tests: TRY_ADDRS_4 TRY_ADDRS_4_6
566 Feature recommended by Anand Buddhdev.
567
568 configure option --enable-default-ipv allows to specify at build time if
569 IPv4, IPv6, or none of these is the preferred default; this is related
570 to environment variables SOCAT_PREFERRED_RESOLVE_IP and
571 SOCAT_DEFAULT_LISTEN_IP, and to Socat option -4, -6.
572 Furthermore, mechanism of IPv4 vs.IPv6 selection has been reworked.
573 When no IP version is preferred by these mechanism, passive Socat
574 addresses (LISTEN, RECV, RECVFROM) default to IPv6 because it might
575 support both versions (but checkout option ipv6-v6only).
576 For client addresses, when one of these mechanisms applies and name
577 resolution gives addresses of both IP versions, the addresses of the
578 preferred versions are tried first.
579
580 New option ai-addrconfig sets or unsets the AI_ADDRCONFIG flag of the
581 resolver to prevent name resolution to address families that are not
582 available in the network configuration. Default value is 1 in case the
583 resolver does not get an address family hint.
584
585 Flag AI_PASSIVE is now automatically applied for LISTEN, RECV, and
586 RECVFROM type addresses, and with bind option. In addition to its
587 application to the getaddrinfo() function, when this flag is set while
588 no IP version is preferred by build, environment, option, or address
589 type, Socat chooses IPv6 because this might activate both versions (but
590 check option ipv6-v6only).
591 Added option ai-passive to control this flag explicitly.
592
593 New option ai-v4mapped (v4mapped) sets or unsets the AI_V4MAPPED flag
594 of the resolver. For Socat addresses requiring IPv6 addresses, this
595 resolves IPv4 addresses to the appropriate IPv6 address [::ffff:*:*].
596
597 DNS resolver Options (res-*) are now set for the complete open phase of
598 the address, not per getaddrinfo() invocation.
599
600 Added the netns option that tries to open an address in the given
601 network namespace.
602 Tests: NETNS NETNS_EXEC
603
604 New address ACCEPT-FD (ACCEPT) expects a listening file descriptor
605 passed from parent, and accepts one or more connections for data
606 transfer. This can be used with "inetd mode" of systemd.
607 Test: ACCEPT_FD
608
609 Added experimental socks5 TCP client support (connect,bind); syntax:
610 SOCKS5-CONNECT:<socks-server>:<socks-port>:<target-host>:<target-port>
611 SOCKS5-LISTEN:<socks-server>:<socks-port>:<listen-host>:<listen-port>
612 Thanks to Charlie Svensson and others for contributions.
613
614 New address types POSIXMQ-RECEIVE, POSIXMQ-READ, POSIXMQ-SEND, and
615 POSIXMQ-BIDIRECTIONAL (Linux only, experimental), and option
616 posixmq-priority
617 Tests: LINUX_POSIXMQ_READ_PRIO LINUX_POSIXMQ_RECV_FORK
618 LINUX_POSIXMQ_RECV_MAXCHILDREN LINUX_POSIXMQ_SEND_MAXCHILDREN
619
620 New address SHELL invokes a shell but without the overhead of SYSTEM
621
622 Added options res-retrans and res-retry that make use of undocumented
623 resolver variables to set the retransmission time interval resp.the
624 number of times to retransmit.
625 Disable them and the old res-* opts with: ./configure --disable-resolve
626
627 Added option res-nsaddr that overrides /etc/resolv.conf nameserver
628 address based on an undocumented resolver feature.
629
630 New option chdir changes the working directory of the address to the
631 given path, only during the open stage.
632 Tests: CHDIR_ON_CREATE CHDIR_ON_SYSTEM
633
634 Option umask now applies only during opening of its very address, not
635 for the lifetime of the process; the original umask is restored
636 afterwards.
637 Tests: UMASK_ON_CREATE UMASK_ON_SYSTEM
638
639 Added option unix-bind-tempname (bind-tempname) to allow UNIX (and
640 ABSTRACT) client addresses to bind to unique addresses even when
641 invoked in forked off sub processes.
642 Tests: UNIX_LISTEN_CONNECT_BIND_TEMPNAME UNIX_LISTEN_CLIENT_BIND_TEMPNAME
643 UNIX_RECVFROM_CLIENT_BIND_TEMPNAME UNIX_RECVFROM_SENDTO_BIND_TEMPNAME
644 ABSTRACT_LISTEN_CONNECT_BIND_TEMPNAME ABSTRACT_LISTEN_CLIENT_BIND_TEMPNAME
645 ABSTRACT_RECVFROM_CLIENT_BIND_TEMPNAME ABSTRACT_RECVFROM_SENDTO_BIND_TEMPNAME
646 Thanks to Kai Lüke for sending an initial patch.
647
648 New option f-setpipe-sz (pipesz) sets the pipe size on systems that
649 provide ioctl F_SETIPE_SZ.
650 Filan prints the current value.
651 Tests: STDIN_F_SETPIPE_SZ EXEC_F_SETPIPE_SZ
652
653 Bidirectional PIPE addresses may block on writing a data chunk larger
654 than pipe buffer. Socat now tries to detect if transfer block size is
655 large enough and issues a warning.
656
657 Added direct support of DCCP protocol, new addresses:
658 DCCP-CONNECT (DCCP)
659 DCCP-LISTEN (DCCP-L)
660 DCCP4-CONNECT (DCCP4)
661 DCCP4-LISTEN (DCCP4-L)
662 DCCP6-CONNECT (DCCP6)
663 DCCP6-LISTEN (DCCP6-L)
664 New option: dccp-set-ccid (ccid)
665
666 Support for UDP-Lite protocol, new addresses:
667 UDPLITE-CONNECT
668 UDPLITE-LISTEN
669 UDPLITE-DATAGRAM
670 UDPLITE-RECV
671 UDPLITE-RECVFROM
672 UDPLITE-SENDTO
673 All these are also available in UDPLITE4-* and UDPLITE6-* form;
674 options udplite-recv-cscov and udplite-send-cscov.
675
676 Procan now prints info about CC and __STDC_VERSION__, about FD_SETSIZE,
677 value of SO_PROTOCOL/SO_PROTOTYPE and some other defines, definitions
678 of many C types, and the actual umask.
679
680 Procan tries to find the name of the controlling terminal, on Linux it
681 reads info from /proc/self/stat and searches for a device with matching
682 major and minor numbers.
683
684 Added socat-chain.sh that makes it possible to stack protocols, e.g. to
685 drive socks through TLS, or to use TLS over a serial line.
686 Tests: SOCAT_CHAIN_SOCKS4 SOCAT_CHAIN_SSL_PTY
687
688 Added script socat-mux.sh that performs n-to-1 / 1-to-n communications
689 using two Socat instances with multicasting.
690 Tests: SOCAT_MUX
691
692 Corrections:
693 When a sub process (EXEC, SYSTEM) terminated with exit code other than
694 0, its last sent data might have been lost depending on timing of read/
695 write and SIGCHLD in Socat.
696 Now the SIGCHLD handler does not simply terminate Socat in this case,
697 but remembers the failure and allows further processing.
698 Thanks to Luke Jones for reporting this issue.
699
700 Now catching the case of empty SNI host to prevent OpenSSL error.
701 This is related to Red Hat issue 2081414.
702
703 Better formatted help output; address keywords in help output are now
704 printed in uppercase.
705
706 In previous Socat versions errors EPIPE and ECONNRESET on read() were
707 handled at warning level, thus not automatically leading to termination
708 with exit code 1. Beginning with this release these conditions are
709 handled as errors with termination and exit code 1 to not pretend
710 success on possible data loss.
711 Problem reported by Scott Burkett.
712
713 In previous Socat versions errors on shutdown() were ignored (info
714 level).
715 Now Socat handles EPIPE and ECONNRESET as errors to indicate possible
716 failure of data transfer.
717
718 INTERFACE addresses did not accept options of INTERFACE group (for
719 historical reasons they were only available with TUN addresses).
720
721 Opening addresses did not check if they support all directions expected
722 by Socat. Now an error is printed when, e.g,, a read-only type address
723 is opened for writing.
724
725 A lot of minor corrections, e.g., catch readline() errors in filan,
726 detect byte order in procan
727 Test: EXEC_SIGINT
728
729 OpenSSL cipherlist option did not override global openssl.cnf settings.
730 Now SSL_CTX_set_cipher_list() is called before
731 SSL_CTX_use_certificate_chain_file().
732 Thanks to Hiroshi Sakurai for reporting the problem and suggesting this
733 solution.
734
735 Fixed option sourceport with UDP6-DATAGRAM.
736
737 Some client addresses (e.g. TCP-CONNECT) take the fork option for
738 automatically spawning new connections, however the max-children option
739 was not applied.
740
741 Fixed the end-close option, it just did not work.
742
743 In configure.ac was a direct call to gcc instead of $CC which broke
744 cross compiling.
745 Thanks to Fergus Dall for sending a patch.
746
747 Coding:
748 Introduced groups_t instead of uint32_t, for more flexibility.
749
750 Rearranged option group bits to only require 32 bits on older systems.
751
752 Make gcc happy, replace strncat with "manual" copying
753
754 On addresses like UDP-RECVFROM with fork option every packet causes a
755 new child process which then reads the packet. The parent process must
756 wait until the packet has been read before checking again. The former
757 synchronization mechanism using SIGUSR1 is now replaced by a
758 socketpair. SIGUSR1 is no longer used for internal synchronization.
759 Tests: UDP4_FORK UDP6_FORK UNIX_FORK
760
761 Renamed xioopts_t to xioparms_t to avoid confusion with xioopts module.
762
763 Moved multicast related code from xioopts.c to xio-ip.c and xio-ip6.c
764
765 Pointers of type struct single are now always called sfd.
766
767 Porting:
768 Removed Config/ because its contents have not been maintained for many
769 years.
770
771 Try to not receive outgoing packets on raw (PF_PACKET) sockets - use
772 PACKET_IGNORE_OUTGOING socket options when available.
773 Test: INTERFACE_IGNOREOUTGOING
774
775 Renewed port to OpenBSD:
776 Guard OPENSSL_INIT_SETTINGS; and minor changes.
777
778 Thanks to Paul Hunt for sending a fix of the configure
779 --enable-openssl-base processing.
780
781 Enable direct largefile support on "smaller" systems per
782 _FILE_OFFSET_BITS and _LARGE_FILES.
783 Thanks to Fergus Dall for sending a patch.
784
785 Some corrections for better 32bit systems support.
786
787 Testing:
788 Removed obsolete parts from test.sh
789
790 test.sh: Introduced function checkcond
791
792 Renamed test.sh option -foreign to -internet
793
794 Documentation:
795 Removed obsolete file doc/xio.help
796
797 Added doc for option ipv6-join-group (ipv6-add-membership)
798 Thanks to Martin Buck for sending the patch.
799
800 Renamed xiogetpacketsrc() to xiogetancillary()
801
802 On bad parameter number now print syntax.
803
804 ####################### V 1.7.4.5 (not released):
805
806 Corrections:
807 On connect() failure and in some other situations Socat tries to get
808 detailed information about the error with recvmsg(). Error return of
809 this function is now logged as Info instead of Warn.
810
811 Tests of the correction of the "IP_ADD_SOURCE_MEMBERSHIP but not struct
812 ip_mreq_source" issue left an #undef in xiosysincludes.h that disabled
813 the ip-add-source-membership option.
814 Thanks to Benjamin Poirier for sending a patch.
815
816 Fixed a bug in dalan module that caused SIGSEGV in, e.g.,
817 SOCKET-LISTEN:1:1:'"/tmp/sock"'
818 Test: DALAN_NO_SIGSEGV
819
820 The retry option with some address types (TCP) did not close() the
821 sockets after failed attempts, resulting in an FD leak.
822
823 Filan: Corrected some syntax error messages
824
825 Filan: Fixed a bug introduced in 1.7.4.4 that broke displaying
826 TCP/UDP on options -s, -S
827 Test: FILAN_SHORT_TCP
828
829 Filan: If IP protocol type cannot be retrieved, display at least the
830 socket type
831
832 Filan: Fixed diag_set() call in filan_main.c, bug popped up with C23.
833 Thanks to Cristian Rodríguez from openSUSE for reporting this issue.
834
835 Querying the vsock Context Identifier (CID) requires an FD from opening
836 /dev/vsock.
837 Thanks to Volker Simonis for sending a patch.
838
839 Fixed an internal FD leak in the EXEC,SYSTEM addresses.
840
841 The FDs of the socketpair that queues messages from signal handlers
842 lacked FD_CLOEXEC and thus leaked into EXEC and SYSTEM child processes.
843
844 Option stderr on addresses EXEC and SYSTEM uses a temporary FD. It
845 lacked the FD_CLOEXEC setting and thus leakt into child processes.
846
847 Restoring of STDIO tty settings failed on Solaris type operating
848 systems.
849 Thanks to Gordon W.Ross for reporting and fixing this issue.
850 Test: RESTORE_TTY
851
852 The OpenSSL client SNI parameter, when not explicitly specified, is
853 derived from option commonname or rom target server name. This is not
854 useful with IP addresses, which Socat now checks and avoids.
855
856 Socat options -L and -W create lock files using mkstemp(), so they had
857 permissions 600. There does not seem to be a good reason for this
858 restrictive mode. Furthermore Silla Rizzoli experienced that Minicom
859 ignores lock files with mode 600, so it is set to 644 now.
860
861 Procan tries to find out VSOCK CID only when running as root
862
863 The mechanism for deferring logs from signal handlers had an issue that
864 caused lots of unwanted recvfrom() calls.
865
866 Do not try to remove abstract UNIX socket entries after use.
867
868 Features:
869 VSOCK, VSOCK-L support options pf, socktype, prototype (currently
870 useless)
871
872 Coding:
873 New Environment variable SOCAT_TRANSFER_WAIT that Socat sleep before
874 starting the data transfer loop. Useful, e.g., to accumulate multiple
875 packets in a receiving datagram socket before starting to process them.
876
877 "//" comments were used for disabling experimental code. These lines
878 have now been removed or disabled in other ways to make Socat compile
879 with C89/C90 standard again.
880
881 fcntl() trace prints flags now in hexadecimal.
882
883 Stream dump options -r and -R now open their paths with CLOEXEC to
884 prevent leaking into sub processes.
885 Test: EXEC_SNIFF
886
887 Stream dump write now warn on write errors and partial writes (but
888 still do not recover).
889
890 Removed trailing white space from *.h and *.c files.
891
892 Porting:
893 Small correction in configure.ac makes Socat C99 able.
894 Thanks to Florian Weimer from Red Hat for providing a patch.
895
896 Documentation:
897 Syntax and semantics of some options (esp.unlink-close) were not clear.
898 Thanks to Anthony Chavez for reporting this and making suggestions.
899
900 socat-tun.html described TCP as tunnel medium but this does not keep
901 packet boundaries. Changed to UDP.
902
903 Added examples for DCCP client and server.
904
905 Complex Socat examples are now displayed in two or three lines for
906 better overview.
907 dest-unreach.css stylesheet has been improved to support this.
908
909 Testing:
910 Idea: EXEC,SYSTEM addresses can keep packet boundaries when option
911 socktype=<val-of-SOCK_DGRAM>
912 Tests: EXECSOCKETPAIRPACKETS SYSTEMSOCKETPAIRPACKETS
913
914 Cosmetic corrections of EXEC,SYSTEM tests.
915
916 test.sh: Added option --expect-fail to specify comma separated list of
917 test numbers whose failure shall not cause a failure of the whole
918 script.
919
920 test.sh: Added help text
921
922 Speeded up wait loops; more addresses in upper case; more tests with
923 command printing ($VERBOSE)
924
925 test.sh: Check if ports are free before using them for tests
926
927 Test EXEC_FDS checks with Filan if EXEC address only passes stdio FDs.
928
929 Improved template; prepared namesFAIL, -d (DEBUG)
930
931 ####################### V 1.7.4.4:
932
933 Corrections:
934 In error.c msg2() there was a stack overflow on long messages: The
935 terminating \0 Byte was written behind the last position.
936 Thanks to Martin Liška for sending the address sanitizer report.
937
938 UDP-RECVFROM with fork sometimes terminated when multiple packets
939 arrived. This issue was introduced with a bug fix in version 1.7.4.0.
940 Reason was not handling EAGAIN on recvmsg().
941 Thanks to Jamie McQuillan for reporting this issue.
942
943 Address TCP with options connect-timeout and retry terminated
944 immediately when a connection attempt failed on network error or
945 connection refused.
946 Test: TCP_TIMEOUT_RETRY
947 Thanks to Kamil Holubicki for reporting this issue.
948
949 There were a couple of weaknesses and errors when accessing invalid or
950 incompatible file system entries with UNIX domain, file, and generic
951 addresses.
952 For example, UNIX-CONNECT, when using a non matching socktype, failed
953 with -1 and did not print an error message, instead of printing an
954 error message and exiting with rc=1.
955 Thanks to Paul Wise for reporting and analyzing the case of accessing
956 a left over socket entry with GOPEN.
957
958 The rawer option failed because it tried to clear CREAD.
959 Test: RAWER
960
961 UDP-SEND and UPD-SENDTO with option lowport always bound to port 1
962 instead of a free port in range 640..1023
963 Test: UDP_LOWPORT
964
965 Fixed bad parser error message on "socat /tmp/x\"x/x -"
966
967 Tightened syntax checks to detect numerical arguments that are missing
968 or have trailing garbage.
969 Test: INTEGER_GARBAGE
970
971 ctype(3) functions need there arguments to be unsigned char.
972 Thanks to Taylor R Campbell for sending a patch.
973
974 Filan library uses Socats diag/error message system and therefore had
975 always the signal handler messages socket pair open. This fix avoids
976 this socketpair in standalone Filan.
977
978 Corrected printf format for type socklen_t in two places.
979
980 Porting:
981 OpenSSL, at least 1.1 on Ubuntu, crashed with SIGSEGV under certain
982 conditions: client connection to server with certificate with empty
983 subject, and pressing ^C after successful connect.
984 This crash is now prevented by setting OPENSSL_INIT_NO_ATEXIT.
985 Thanks to Martin Dorey for reporting and analyzing this issue, and for
986 providing an environment for reproduction.
987
988 Socat failed to compile on platforms that have
989 IP_ADD_SOURCE_MEMBERSHIP but not struct ip_mreq_source
990 Thanks to Justin Yackoski for sending a patch.
991
992 configure.ac's detection of getprotobynumber_r() variant did not
993 recognize if this function does not exist, e.g. on Musl libc.
994 Thanks to Alexander Kanavin and Baruch Siach for sending patches.
995
996 Corrected message format when no strftime() is available; improved
997 handling of very long host or program names
998
999 Solaris requires that termios options are always applied to the slave
1000 side of PTY.
1001
1002 Fixed ancillary messages on Solaris.
1003
1004 Filan: Solaris has the open file path infos in /proc/<pid>/path/
1005 Thanks to Andy Fiddaman for directing me to the patch.
1006
1007 Filan now recognizes and prints Solaris doors and event ports.
1008
1009 Solaris derivatives no longer need librt for clock_gettime()
1010 Thanks to Andy Fiddaman for directing me to the patch.
1011
1012 LibreSSL does not have OPENSSL_INIT_new(). This function is now
1013 guarded. Socat might build with LibreSSL.
1014 Thanks to Orbea for reporting and helping.
1015
1016 Building:
1017 Failure during building documentation, e.g. due to missing Yodl
1018 packages, now does not let the build process fail.
1019 Feature requested by Seyhun.
1020
1021 Features:
1022 Filan prints target of symlink when appropriate
1023 Test: FILANSYMLINK
1024
1025 VSOCK-LISTEN now generates environment variables SOCAT_PEERADDR,
1026 SOCAT_PEERPORT, SOCAT_SOCKADDR, SOCAT_SOCKPORT
1027 New address aliases VSOCK, VSOCK-L
1028
1029 Documentation:
1030 Fixed typo in doc/socat-tun.html and link in README.
1031 Thanks to William Suthers for reporting.
1032
1033 Fixed hard coded path in docu examples.
1034 Thanks to Jakub Wilk for sending a patch.
1035
1036 Updated doc/socat-openssltunnel.html: 2048 bits, commonname
1037
1038 Testing:
1039 Unset SOCAT_MAIN_WAIT on informational Socat calls
1040
1041 SOCAT=socat used ./socat instead of the version derived by $PATH
1042
1043 Do not try VSOCK_ECHO test when feature is not compiled in.
1044
1045 Fixed logging of test 220 TUNINTERFACE
1046
1047 Musl libc refuses to execve() shell scripts, 2 tests needed to be
1048 adapted.
1049
1050 Musl libc has FOPEN_MAX=1000 which made bash dumping core on test
1051 EXCEED_FOPEN_MAX.
1052
1053 Added tests for failures of UNIX socket and GOPEN accesses to non
1054 matching file system entries.
1055 Tests:
1056 CONNECT_TO_MISSING CONNECT_TO_DENIED CONNECT_TO_DIRECTORY
1057 CONNECT_TO_ORPHANED CONNECT_TO_FILE CONNECT_TO_DGRAM
1058 CONNECT_TO_SEQPACKET SEND_TO_MISSING SEND_TO_DENIED SEND_TO_DIRECTORY
1059 SEND_TO_ORPHANED SEND_TO_FILE SEND_TO_STREAM SEND_TO_SEQPACKET
1060 SENDTO_TO_MISSING SENDTO_TO_DENIED SENDTO_TO_DIRECTORY
1061 SENDTO_TO_ORPHANED SENDTO_TO_FILE SENDTO_TO_STREAM SENDTO_TO_SEQPACKET
1062 SEQPACKET_TO_MISSING SEQPACKET_TO_DENIED SEQPACKET_TO_DIRECTORY
1063 SEQPACKET_TO_ORPHANED SEQPACKET_TO_FILE SEQPACKET_TO_STREAM
1064 SEQPACKET_TO_DGRAM UNIX_TO_MISSING UNIX_TO_DENIED UNIX_TO_DIRECTORY
1065 UNIX_TO_FILE UNIX_TO_ORPHANED GOPEN_TO_DENIED GOPEN_TO_DIRECTORY
1066 GOPEN_TO_ORPHANED
1067
1068 On RHEL-9 SCTP support requires installation of package
1069 kernel-modules-extra. test.sh now detects when SCTP is missing in
1070 kernel and reacts with warnings instead of errors.
1071
1072 VSOCK loopback still does not seem to work even in kernel 5.13, so just
1073 issue warning on "No such device".
1074
1075 ####################### V 1.7.4.3:
1076
1077 Corrections:
1078 Socat crashed with SIGSEGV when peer presented a certificate without
1079 (or empty?) subject.
1080 Thanks to Martin Dorey for reporting this issue and sending a patch.
1081
1082 Socat 1.7.4.2 did not compile on OmniOS (and probably other OpenSolaris
1083 distributions)
1084 Thanks to Andy Fiddaman for sending a patch.
1085
1086 Socat since 1.7.4.0 did not compile on Solaris and its derivatives
1087 because the getprotobynumber_r() function prototype differ from the
1088 Linux version.
1089 configure now checks for the variant.
1090 Thanks to Robert Zybeck for reporting this issue.
1091
1092 The variable for the no-sni option was not initialized and could thus
1093 break OpenSSL certificate verification. E.g., test OPENSSL_SNI on some
1094 platform succeeded with -g but failed with -O compiler option.
1095 Thanks to valgrind for quickly finding the cause.
1096
1097 Porting:
1098 Again porting Socat to AIX (7.1) - Fixed configure and compile issues:
1099 Adapted include requirements for IPv6
1100 Guarded MSG_DONTWAIT
1101
1102 Continued porting Socat to AIX-7.1 - Fixed some runtime errors:
1103 UNIX domain sockets of type SEQPACKET are not available.
1104 Connecting to UNIX datagram socket fails with EPROTONOSUPPORT (vs.
1105 EPROTOTYPE on most other OSes).
1106 Streams: Must not push ldterm when it is already active (hangs).
1107
1108 Building:
1109 Socats build date and time may now be set externally with environment
1110 variable SOURCE_DATE_EPOCH.
1111 Thanks to Viktor Kleinik for sending a patch.
1112
1113 Building Socat in a sub directory failed.
1114 Now the following works even for the docu parts:
1115 mkdir -p myos; cd myos; ../configure && make; cd ..
1116 Thanks to Jon Ringle for sending a patch.
1117
1118 Testing:
1119 test.sh: many corrections for AIX's older shell utilities, e.g.sleep(1)
1120 does not allow fractions of seconds, grep does not understand '\<';
1121 OpenIndiana/SunOS netstat format;
1122 many more functional and cosmetic code corrections.
1123
1124 Documentation:
1125 The socktype option was documented unspecifically as type option.
1126 Thanks to Jonas Metzger for the hint.
1127
1128 ####################### V 1.7.4.2:
1129
1130 Corrections:
1131 The per address parameters for OpenSSL overlapped in memory with socket
1132 parameters. Magically this did not seem to cause problems except on
1133 MacOS Catalina that reported errors like:
1134 socat[3458] E Select(7, &0x80, NULL, NULL, {140392884396544.000000}):
1135 Invalid argument
1136 Test: OPENSSL_PARA_OVERLAP
1137 Thanks to Ryo Ota for reporting this bug.
1138
1139 Fixed a few minor coding issues
1140
1141 A VSOCK warning message was generated with all listening addresses
1142 instead of only with VSOCK-LISTEN
1143
1144 When an OPENSSL-CONNECT client presented a certificate with IPv6
1145 subject alternate name and the OPENSSL-LISTEN server had no commonname
1146 option, the server crashed with SIGSEGV in xioip6_pton().
1147 Test: OPENSSL_CLIENT_IP6_CN
1148 Red Hat bug 1981308
1149 Thanks to Vlad Slepukhin for reporting this issue and providing a patch
1150
1151 Corrected a typo in configure.ac that broke option --enable-openssl-base
1152 Thanks to john1doe for reporting this issue.
1153
1154 Socat looped endlessly, not responding to SIGTERM, when a service name
1155 (for port) could not be resolved.
1156 Test: BAD_SERVICE
1157
1158 Using options of NAMED group, e.g.chown, with abstract UNIX domain
1159 sockets, produced errors because the function was applied with a normal
1160 file system related call, e.g.chown(), using file "" (empty name). Instead of
1161 chown(), Socat now uses fchown() on the file descriptor. However, such
1162 a call usually has no real effect.
1163 Test: ABSTRACT_USER
1164 Thanks to Andreas Fink for reporting this issue.
1165
1166 Option -R did not only dump ("sniff") right-to-left, but also
1167 left-to-right traffic to the given file.
1168 Test: SNIFF_RIGHT_TO_LEFT
1169 Thanks to 1314 gsf for reporting this bug and sending a patch.
1170
1171 Options -r and -R, when opening a named pipe that has no actual reader,
1172 failed with "No such device or address". To solve this problem, Socat
1173 now opens the pipe in rw-Mode.
1174 Thanks to Cody J.Soultz for sending a patch.
1175
1176 The call "socat -r - PIPE" traced to file ./- instead of issuing a
1177 syntax error.
1178
1179 Print a message when readbytes option causes EOF
1180
1181 The ip-recverr option had no effect. Corrected and improved its
1182 handling of ancillary messages, so it is able to analyze ICMP error
1183 packets (Linux only?)
1184
1185 Setgui(), Setuid() calls in xio-progcall.c were useless.
1186
1187 Testing:
1188 Prevent the TIMESTAMP tests from sporadically failing due do seconds
1189 overflow
1190
1191 Fixed in test.sh a few issues reported by shellcheck
1192
1193 Documentation:
1194 Added missing docu of OpenSSL options min-proto-version,
1195 max-proto-version.
1196
1197 Added missing closing parenthesis in socat.yo.
1198 Thanks to Emanuele Torre for reporting this issue.
1199
1200 Corrected more typos and added missing bug info to CHANGES, performed
1201 some non functional corrections.
1202
1203 Porting:
1204 Corrected building when clock_gettime() not available, with or without
1205 gettimeofday().
1206
1207 ####################### V 1.7.4.1:
1208
1209 Corrections:
1210 Socat 1.7.4.0 failed to compile especially on 32 bit systems.
1211 Thanks to Wang Mingyu and others for sending a patch or reporting this
1212 issue.
1213
1214 Under certain conditions OpenSSL stream connections, in particular bulk
1215 data transfer in unidirectional mode, failed during transfer or near
1216 its end with Connection reset by peer on receiver side.
1217 This happened with Socat versions 1.7.3.3 to 1.7.4.0. Reasons were
1218 lazy SSL shutdown handling on the sender side in combination with
1219 SSL_MODE_AUTO_RETRY turned off.
1220 Fix: After SSL_shutdown() but before socket shutdown call SSL_read()
1221 Test: OPENSSL_STREAM_TO_SERVER
1222 Fixes Red Hat issue 1870279.
1223
1224 ####################### V 1.7.4.0:
1225
1226 Security:
1227 Buffer size option (-b) is internally doubled for CR-CRLF conversion,
1228 but not checked for integer overflow. This could lead to heap based
1229 buffer overflow, assuming the attacker could provide this parameter.
1230 Test: BLKSIZE_INT_OVERFL
1231 Thanks to Lê Hiếu Bùi for reporting this issue and sending an
1232 example exploit.
1233
1234 Corrections:
1235 Socats address parser read over end of string when there were unbalanced
1236 quotes
1237 Test: UNBALANCED_QUOTE
1238
1239 Removed unused usleep() call from sycls.c
1240
1241 Unsetenv() was conditional in sysutils.c but not in xio-openssl.c thus
1242 building failed on Solaris 9.
1243 Thanks to Greg Earle for reporting this issue and providing a patch.
1244
1245 Mitigated race condition of quickly terminating SYSTEM or EXEC child
1246 processes.
1247
1248 Option o-direct might require alignment of read/write buffer to, e.g.,
1249 512 bytes, Socat now takes care of this when allocating the buffer.
1250 With this fix read() succeeds, however, write() still might fail when
1251 not writing complete pages.
1252 Test: O_DIRECT
1253
1254 There was a race condition in the way Socat UDP-RECVFROM and similar
1255 addresses with option fork prevents one packet from triggering
1256 multiple processes. The symptom was that Socat master process seemed to
1257 hang and did not process further packets. The fix makes use of
1258 pselect() system call.
1259 Thanks to Fulvio Scapin for reporting this issue.
1260
1261 UNIX domain client addresses applied file system entry options (group
1262 NAMED) to the server socket instead of the client (bind) socket entry.
1263 Tests: UNIX_SENDTO_UNLINK UNIX_CONNECT_UNLINK
1264 Thanks to Nico Williams for reporting this major issue.
1265
1266 Length of single address options was limited to 511 bytes. This value
1267 is now increased to 2047 bytes.
1268 Change suggested by Mario Camou.
1269
1270 Addresses of type RECVFROM with option fork looped with an error
1271 message in case that the second address failed before consuming the
1272 packet. The fix makes RECVFROM drop the packet when the second address
1273 failed before reading it. Use retry or forever option with the second
1274 address if you want to avoid data loss.
1275 Fixes Red Hat bug 1907718
1276 Thanks to Chunmei Xu for reporting this issue and proving the patch.
1277
1278 Socats DTLS implementation has been reworked and appears to work now
1279 reasonably over UDP.
1280 New addresses: OPENSSL-DTLS-SERVER (DTLS-L),
1281 OPENSSL-DTLS-CLIENT (DTLS)
1282 Tests: OPENSSL_DTLS_CLIENT OPENSSL_DTLS_SERVER
1283 OPENSSL_METHOD_DTLS1 OPENSSL_METHOD_DTLS1.2
1284 Thanks to Brandon Carpenter, Qing Wan, and Pavel Nakonechnyi for
1285 sending patches.
1286
1287 filan did not output the socket protocol.
1288 filan -s assumed each stream socket to be TCP and each datagram socket
1289 to be UDP. Now it uses SO_PROTOCOL and getprotoent() for correct output.
1290
1291 Help text showed two parameters for UDP4-RECVFROM address, but only
1292 <port> is allowed.
1293 Thanks to John the Scott for reporting this issue.
1294
1295 Error messages from SSL_read() and SSL_write() sometimes stated
1296 SSL_connect instead of originating function name.
1297
1298 Fixed some more non functional minor issues.
1299
1300 Porting:
1301 In gcc version 10 the default changed from -fcommon to -fno-common.
1302 Consequently, linking filan and procan failed with error
1303 "multiple definition of `deny_severity'" and `allow_severity'
1304 Fixed by removing definitions in filan.c and procan.c
1305 Debian issue 957823
1306 Thanks to László Böszörményi and others for reporting this issue.
1307
1308 Solaris 9 does not provide strndup(); added substitute code.
1309 Thanks to Greg Earle for providing a patch.
1310
1311 Added configure option --enable-openssl-base to specify the location of
1312 a non-OS OpenSSL installation
1313
1314 There are systems whose kernel understands SCTP but getaddrinfo does
1315 not. As workaround after EIA_SOCKTYPE on name and service resolution
1316 fall back to ai_socktype=0; if it fails with EAI_SERVICE, set
1317 ai_protocol=0 and try again
1318 Test: SCTP_SERVICENAME
1319
1320 Per file filesystem options were still named ext2-* and dependent on
1321 <linux/ext2_fs.h>. Now they are called fs-* and depend on <linux/fs.h>.
1322 These fs-* options are also available on old systems with ext2_fs.h
1323
1324 New options openssl-min-proto-version (min-version) and
1325 openssl-max-proto-version (max-version) give access to the related
1326 OpenSSL set-macros and substitute deprecated version-specific methods.
1327 Test: OPENSSL_MIN_VERSION
1328
1329 With OpenSSL use OPENSSL_init_SSL when available, instead of deprecated
1330 SSL_library_init.
1331
1332 With OPENSSL_API_COMPAT=0x10000000L the files openssl/dh.h, openssl/bn.h
1333 must explicitly be included.
1334 Thanks to Rosen Penev for reporting and sending a patch.
1335
1336 Testing:
1337 test.sh now produces a list of tests that could not be performed for
1338 any reason. This helps to analyse these cases.
1339
1340 OpenSSL s_server apparently started to neglect TCPs half close feature.
1341 Test OPENSSL_TCP4 has been changed to tolerate this.
1342
1343 OpenSSL changed its behaviour when connection is rejected. Tests
1344 OPENSSLCERTSERVER, OPENSSL_CN_CLIENT_SECURITY, and
1345 OPENSSL_CN_SERVER_SECURITY now tolerate this.
1346
1347 OpenSSL no longer allows explicit renegotiation with TLSv1.3, thus the
1348 appropriate tests failed.
1349 Fix: use TLSv1.2 for renegotiation tests
1350 Tests: OPENSSLRENEG1 OPENSSLRENEG2
1351
1352 Ubuntu 20.04 requires 2048 bit certificates with OpenSSL
1353
1354 Archlinux 2020 has not which command; its ip,ss commands have modified
1355 version strings
1356
1357 More testing issues solved:
1358 * ss to pipe might omit column separator
1359 * UDP6MULTICAST_UNIDIR fails on newer Linux kernels
1360 * do not use sort -V
1361 * renamed testaddrs() to testfeats(), and introduced new testaddrs()
1362
1363 New features:
1364 GOPEN and UNIX-CLIENT addresses now support sockets of type SEQPACKET.
1365 Test: GOPENUNIXSEQPACKET
1366 Feature suggested by vi0oss.
1367
1368 The generic setsockopt-int and related options are, in case of
1369 listening/accepting addresses, applied to the connected socket(s). To enable
1370 setting options on the listening socket, a new option setsockopt-listen
1371 has been implemented. See the documentation for info on data types.
1372 Tests: SETSOCKOPT SETSOCKOPT_LISTEN
1373 Thanks to Steven Danna and Korian Edeline for reporting this issue.
1374
1375 Filan option -S gives short description like -s but with improved
1376 format
1377
1378 Socat OpenSSL client, when server was specified using IP address, did
1379 not verify connection on certificates SubjectAltName IP entries.
1380 Tests: OPENSSL_SERVERALTAUTH OPENSSL_SERVERALTIP4AUTH OPENSSL_SERVERALTIP6AUTH
1381 Fixes Red Hat bug 1805132
1382
1383 Added options -r and -R for raw dump of transferred data to files.
1384 Test: OPTION_RAW_DUMP
1385
1386 Added option ip-transparent (socket option IP_TRANSPARENT)
1387 Thanks to Wang Shanker for sending a patch.
1388
1389 OPENSSL-CONNECT now automatically uses the SNI feature, option
1390 openssl-no-sni turns it off. Option openssl-snihost overrides the value
1391 of option openssl-commonname or the server name.
1392 Tests: OPENSSL_SNI OPENSSL_NO_SNI
1393 Thanks to Travis Burtrum for providing the initial patch
1394
1395 New option accept-timeout (listen-timeout)
1396 Test: ACCEPTTIMEOUT
1397 Proposed by Roland
1398
1399 New option ip-add-source-membership
1400 Feature inspired by Brian (b f31415)
1401
1402 INCOMPATIBLE CHANGE: Address UDP-DATAGRAM now does not check peerport
1403 of replies, as it did up to version 1.7.3.4. Use option sourceport when
1404 you need the old behaviour.
1405 Test: UDP_DATAGRAM_SOURCEPORT
1406 Feature inspired by Hans Bueckler for SSDP inquiry (for UPnP)
1407
1408 New option proxy-authorization-file reads PROXY-CONNECT credentials
1409 from file and makes it possible to hide this data from the process
1410 table.
1411 Test: PROXYAUTHFILE
1412 Thanks to Charles Stephens for sending an initial patch.
1413
1414 Added AF_VSOCK support with VSOCK-CONNECT and VSOCK-LISTEN addresses.
1415 Developed by Stefano Garzarella.
1416
1417 Coding:
1418 Added printf formats for uint16_t etc.
1419
1420 Documentation:
1421 Address UDP-RECV does not support option fork.
1422 Thanks to Fulvio Scapin for reporting that mistake in docu.
1423
1424 TUN address documentation showed TCP for backend which may merge
1425 consecutive packets which causes data loss.
1426 Thanks to Tomasz Lakota for reporting this issue.
1427
1428 ####################### V 1.7.3.4:
1429
1430 Corrections:
1431 Header of xiotermios_speed() declared parameter unsigned int instead of
1432 speed_t, thus compiling failed on MacOS
1433 Thanks to Joe Strout and others for reporting this bug.
1434 Thanks to Andrew Childs and others for sending a patch.
1435
1436 Under certain circumstances, termios options of the first address were
1437 applied to the second address, resulting in error
1438 "Inappropriate ioctl for device"
1439 This affected version 1.7.3.3 only.
1440 Test: TERMIOS_PH_ALL
1441 Thanks to Ivan J. for reporting this issue.
1442
1443 Socat failed to compile when no poll() system call was found by
1444 configure.
1445 Thanks to Jason White for sending a patch.
1446
1447 Due to use of SSL_CTX_clear_mode() Socat failed to compile on old
1448 systems with, e.g., OpenSSL-0.9.8. Thanks to Simon Matter and Moritz B.
1449 for reporting this problem and sending initial patches.
1450
1451 getaddrinfo() in IP4-SENDTO and IP6-SENDTO addresses failed with
1452 "ai_socktype not supported" when protocol 6 was addressed.
1453 The fix removes the possibility to use service names with SCTP.
1454 Test: IP_SENDTO_6
1455 Thanks to Sören for sending an initial patch.
1456
1457 Under certain circumstances, Socat printed the "socket ... is at EOF"
1458 multiple times.
1459 Test: MULTIPLE_EOF
1460
1461 Newer parts of test.sh used substitutions ${x,,*} or ${x^^*} that are
1462 not implemented in older bash versions.
1463
1464 ####################### V 1.7.3.3:
1465
1466 Corrections:
1467 Makefile.in did not specify dependencies of filan on vsnprintf_r.o
1468 and snprinterr.o
1469 Added definition of FILAN_OBJS
1470 Thanks to Craig Leres, Clayton Shotwell, and Chris Packham for
1471 providing patches.
1472
1473 configure option --enable-msglevel did not work with numbers
1474
1475 The autoconf mechanism for determining SHIFT_OFFSET did not work when
1476 cross compiling.
1477 Thanks to Max Freisinger from Gentoo for sending a patch.
1478
1479 Socat still depended on obsolete gethostbyname() function, thus
1480 compiling with MUSL libc failed.
1481 Problem reported by Kennedy33.
1482
1483 The async signal safe diagnostic system used FDs 3 and 4 internally, so
1484 use of appropriate fdin or fdout led to failures.
1485 Test: DIAG_FDIN
1486 Problem reported by Onur Sentürk.
1487
1488 The socket based mechanism for passing messages and signal information
1489 from signal handler to process could reach and kill the wrong process.
1490 Introduces functions diag_sock_pair(), diag_fork()
1491 Thanks to Darren Zhao for analysing and reporting this problem.
1492
1493 Option ipv6-join-group did not work because it was applied in the wrong
1494 phase
1495 Test: UDP6MULTICAST_UNIDIR
1496 Thanks to Angus Gratton for sending a patch.
1497
1498 Setting ispeed and ospeed failed for some serial devices because the
1499 two settings were applied with two different get/set cycles, Thanks to
1500 Alexandre Fenyo for providing an initial patch.
1501 However, the actual fix is part of a conceptual change of the termios
1502 module that aims for applying all changes in a single tcsetattr call.
1503 Fixes FreeBSD Bug 198441
1504
1505 Termios options TAB0,TAB1,TAB2,TAB3, and XTABS did not have an effect.
1506 Thanks to Alan Walters for reporting this bug.
1507
1508 Substituted cumbersom ISPEED_OFFSET mechanism for cfsetispeed() calls
1509
1510 With TCP6-LISTEN and the other passive IPv6 addresses the range option
1511 just failed: due to a bug in the syntax parser and two more bugs in
1512 the xiocheckrange_ip6() function.
1513 The syntax has now been changed from "[::1/128]" to "[::1]/128"!
1514 Thanks Leah Neukirchen for sending an initial fix.
1515
1516 For name resolution Socat only checked the first character of the host
1517 name to decide if it is an IPv4 address. This was not RFC conform. This
1518 fix removes the possibility for use of IPv4 addresses with IPv6, e.g.
1519 TCP6:127.0.0.1:80
1520 Debian issue 695885
1521 Thanks to Nicolas Fournil for reporting this issue.
1522
1523 Print a useful error message when single character options appear to be
1524 merged in Socat invocation
1525 Test: SOCAT_OPT_HINT
1526
1527 Fixed some docu typos.
1528 Thanks to Travis Wellman, Thomas <tjps636>, Dan Kenigsberg,
1529 Julian Zinn, and Simon Matter
1530
1531 Porting:
1532 OpenSSL functions TLS1_client_method() and similar are
1533 deprecated. Socat now uses recommended TLS_client_method(). The old
1534 functions and dependent option openssl-method can still be
1535 used when configuring socat with --enable-openssl-method
1536
1537 Shell scripts in socat distribution are now headed with:
1538 #! /usr/bin/env bash
1539 to make them better portable to systems without /bin/bash
1540 Thanks to Maya Rashish for sending a patch
1541
1542 RES_AAONLY, RES_PRIMARY are deprecated. You can still enable them with
1543 configure option --enable-res-deprecated.
1544
1545 New versions of OpenSSL preset SSL_MODE_AUTO_RETRY which may hang socat.
1546 Solution: clear SSL_MODE_AUTO_RETRY when it is set.
1547
1548 Renamed configure.in to configure.ac and set an appropriate symlink for
1549 older environments.
1550 Related Gentoo bug 426262: Warning on configure.in
1551 Thanks to Francesco Turco for reporting that warning.
1552
1553 Fixed new IPv6 range code for platforms without s6_addr32 component.
1554
1555 Testing:
1556 test.sh: Show a warning when phase-1 (insecure phase) of a security
1557 test fails
1558
1559 OpenSSL tests failed on actual Linux distributions. Measures:
1560 Increased key lengths from 768 to 1024 bits
1561 Added test.sh option -C to delete temp certs from prevsious runs
1562 Provide DH-parameter in certificate in PEM
1563 OpenSSL s_server option -verify 0 must be omitted
1564 OpenSSL authentication method aNULL no longer works
1565 Failure of cipher aNULL is not a failure
1566 Failure of methods SSL3 and SSL23 is desired
1567
1568 test.sh depended on ifconfig and netstat utilities which are no longer
1569 availabie in some distributions. test.sh now checks for and prefers
1570 ip and ss.
1571 Thanks to Ruediger Meier for reporting this problem.
1572
1573 More corrections to test.sh:
1574 Language settings could still influence test results
1575 netstat was still required
1576 Suppress usleep deprecated message
1577 Force use of IPv4 with some certificates
1578 Set timeout for UDPxMAXCHILDREN tests
1579
1580 Git:
1581 Added missing Config/Makefile.DragonFly-2-8-2,
1582 Config/config.DragonFly-2-8-2.h
1583 Removed testcert.conf (to be generated by test.sh)
1584
1585 Cosmetics:
1586 Simplified handling of missing termios defines.
1587
1588 New features:
1589 Permit combined -d options as -dd etc.
1590
1591 porting:
1592 ext2 options are now fs options.
1593
1594 ####################### V 1.7.3.2:
1595
1596 corrections:
1597 SIGSEGV and other signals could lead to a 100% CPU loop
1598
1599 Failing name resolution could lead to SIGSEGV
1600 Thanks to Max for reporting this issue.
1601
1602 Include <stddef.h> for ptrdiff_t
1603 Thanks to Jeroen Roovers for reporting this issue.
1604
1605 Building with --disable-sycls failed due to missing sslcls.h defines
1606
1607 Socat hung when configured with --disable-sycls.
1608
1609 Some minor corrections with includes etc.
1610
1611 Option so-reuseport did not work. Thanks to Some Raghavendra Prabhu
1612 for sending a patch.
1613
1614 Programs invoked with EXEC, nofork, and -u or -U had stdin and stdout
1615 incorrectly assigned
1616 Test: EXEC_NOFORK_UNIDIR
1617 Thanks to David Reiss for reporting this problem.
1618
1619 Socat exited with status 0 even when a program invoked with SYSTEM or
1620 EXEC failed.
1621 Tests: SYSTEM_RC EXEC_RC
1622 Issue reported by Felix Winkelmann.
1623
1624 AddressSanitizer reported a few buffer overflows (false positives).
1625 Nevertheless fixed Socat source.
1626 Issue reported by Hanno Böck.
1627
1628 Socat did not use option ipv6-join-group.
1629 Test: USE_IPV6_JOIN_GROUP
1630 Thanks to Linus Lüssing for sending a patch.
1631
1632 UDP-LISTEN did not honor the max-children option.
1633 Test: UDP4MAXCHILDREN UDP6MAXCHILDREN
1634 Thanks to Leander Berwers for reporting this issue.
1635
1636 Options so-rcvtimeo and so-sndtimeo do not work with poll()/select()
1637 and therefore were useless.
1638 Thanks to Steve Borenstein for reporting this issue.
1639
1640 Option dhparam was documented as dhparams. Added the alias name
1641 dhparams to fix this.
1642 Thanks to Alexander Neumann for sending a patch.
1643
1644 Options shut-down and shut-close did not work.
1645 Thanks to Stefan Schimanski for providing a patch.
1646
1647 There was a bug in printing readline log message caused by a misleading
1648 indentation.
1649 Thanks to Paul Wouters for reporting.
1650
1651 The internal vsnprintf_r function looped or crashed on size parameter
1652 with hexadecimal output.
1653
1654 Ignore exit code of child process when it was killed by master due to
1655 EOF
1656
1657 Corrected byte order on read of IPV6_TCLASS value from ancillary
1658 message
1659
1660 Fixed type of the bool element in options. This had bug caused failures
1661 e.g. of ignoreeof on big-endian systems when bool was not based on int.
1662
1663 On systems with predefined bool type whose size differs from int some
1664 IPv6 and TCP options (per setsockopt()) failed.
1665
1666 Length of integral data in ancillary messages varies (TOS: 1 byte,
1667 TTL: 4 bytes), the old implementation failed for TTL on big-endian
1668 hosts.
1669
1670 Fixed an issue in options processing: TUN and DNS flags had failed on
1671 big-endian systems and the NO- forms had probable never worked.
1672
1673 porting:
1674 Type conflict between int and sig_atomic_t between declaration and
1675 definition of diag_immediate_type and diag_immediate_exit broke
1676 compilation on FreeBSD 10.1 with clang. Thanks to Emanuel Haupt for
1677 reporting this bug.
1678
1679 Socat failed to compile on platforms with OpenSSL without
1680 DTLSv1_client_method or DTLSv1_server_method.
1681 Thanks to Simon Matter for sending a patch.
1682
1683 NuttX OS headers do not provide struct ip, thus socat did not compile.
1684 Made struct ip subject to configure.
1685 Thanks to SP for reporting this issue.
1686
1687 Socat failed to compile with OpenSSL version 1.0.2d where
1688 SSLv3_server_method and SSLv3_client_method are no longer defined.
1689 Thanks to Mischa ter Smitten for reporting this issue and providing
1690 a patch.
1691
1692 configure checked for OpenSSL EC_KEY assuming it is a define but it
1693 is a type, thus OpenSSL ECDHE ciphers failed even on Linux.
1694 Thanks to Andrey Arapov for reporting this bug.
1695
1696 Changes to make socat compile with OpenSSL 1.1.
1697 Thanks to Sebastian Andrzej Siewior e.a. from the Debian team for
1698 providing the base patch.
1699 Debian Bug#828550
1700
1701 Make Socat compatible with BoringSSL.
1702 Thanks to Matt Braithwaite for providing a patch.
1703
1704 OpenSSL: Use RAND_status to determine PRNG state
1705 Thanks to Adam Langley for providing a patch
1706
1707 AIX-7 uses an extended O_ACCMODE that does not fit socat's internal
1708 requirements. Thanks to Garrick Trowsdale for providing a patch
1709
1710 LibreSSL support: check for OPENSSL_NO_COMP
1711 Thanks to Bernard Spil for providing a patch
1712
1713 testing:
1714 socks4echo.sh and socks4a-echo.sh hung with new bash with read -n
1715
1716 test.sh: stderr; option -v (verbose); FDOUT_ERROR description
1717
1718 improved proxy.sh - it now also takes hostnames
1719
1720 A few corrections in test.sh
1721
1722 DTLS1 test hangs on some distributions. Test is now only performed
1723 with OpenSSL 1.0.2 or higher.
1724
1725 More corrections to test.sh that reveal a mistake with IPV6_TCLASS
1726
1727 docu:
1728 Corrected source of socat man page to correctly show man references
1729 like socket(2); removed obsolete entries from See Also
1730
1731 Docu and some comments mentioned addresses SSL-LISTEN and SSL-CONNECT
1732 that do not exist (OPENSSL-LISTEN, SSL-L; and OPENNSSL-CONNECT, SSL
1733 are correct).
1734 Thanks to Zhigang Wang for reporting this issue.
1735
1736 Fixed a couple of English spelling and grammar mistakes.
1737 Thanks to Jakub Wild for sending the patches.
1738
1739 NOEXPAND() was not resolved 2 times.
1740
1741 More minor docu corrections
1742
1743 legal:
1744 Added contributors to copyright notices. Suggested by Matt Braithwaite.
1745
1746 ####################### V 1.7.3.1:
1747
1748 security:
1749 Socat security advisory 8
1750 A stack overflow in vulnerability was found that can be triggered when
1751 command line arguments (complete address specifications, host names,
1752 file names) are longer than 512 bytes.
1753 Successful exploitation might allow an attacker to execute arbitrary
1754 code with the privileges of the socat process.
1755 This vulnerability can only be exploited when an attacker is able to
1756 inject data into socat's command line.
1757 A vulnerable scenario would be a CGI script that reads data from clients
1758 and uses (parts of) this data as hostname for a Socat invocation.
1759 Test: NESTEDOVFL
1760 Credits to Takumi Akiyama for finding and reporting this issue.
1761
1762 Socat security advisory 7
1763 MSVR-1499
1764 CVE-2016-2217
1765 In the OpenSSL address implementation the hard coded 1024 bit DH p
1766 parameter was not prime. The effective cryptographic strength of a key
1767 exchange using these parameters was weaker than the one one could get by
1768 using a prime p. Moreover, since there is no indication of how these
1769 parameters were chosen, the existence of a trapdoor that makes possible
1770 for an eavesdropper to recover the shared secret from a key exchange
1771 that uses them cannot be ruled out.
1772 Furthermore, 1024bit is not considered sufficiently secure.
1773 Fix: generated a new 2048bit prime.
1774 Thanks to Santiago Zanella-Beguelin and Microsoft Vulnerability
1775 Research (MSVR) for finding and reporting this issue.
1776
1777 ####################### V 1.7.3.0:
1778
1779 security:
1780 Socat security advisory 6
1781 CVE-2015-1379: Possible DoS with fork
1782 Fixed problems with signal handling caused by use of not async signal
1783 safe functions in signal handlers that could freeze socat, allowing
1784 denial of service attacks.
1785 Many changes in signal handling and the diagnostic messages system were
1786 applied to make the code async signal safe but still provide detailed
1787 logging from signal handlers:
1788 Coded function vsnprintf_r() as async signal safe incomplete substitute
1789 of libc vsnprintf()
1790 Coded function snprinterr() to replace %m in strings with a system error
1791 message
1792 Instead of gettimeofday() use clock_gettime() when available
1793 Pass Diagnostic messages from signal handler per unix socket to the main
1794 program flow
1795 Use sigaction() instead of signal() for better control
1796 Turn off nested signal handler invocations
1797 Thanks to Peter Lobsinger for reporting and explaining this issue.
1798
1799 Red Hat issue 1019975: add TLS host name checks
1800 OpenSSL client checks if the server certificates names in
1801 extensions/subjectAltName/DNS or in subject/commonName match the name
1802 used to connect or the value of the openssl-commonname option.
1803 Test: OPENSSL_CN_CLIENT_SECURITY
1804
1805 OpenSSL server checks if the client certificates names in
1806 extensions/subjectAltNames/DNS or subject/commonName match the value of
1807 the openssl-commonname option when it is used.
1808 Test: OPENSSL_CN_SERVER_SECURITY
1809
1810 Red Hat issue 1019964: socat now uses the system certificate store with
1811 OPENSSL when neither options cafile nor capath are used
1812
1813 Red Hat issue 1019972: needs to specify OpenSSL cipher suites
1814 Default cipherlist is now "HIGH:-NULL:-PSK:-aNULL" instead of empty to
1815 prevent downgrade attacks
1816
1817 new features:
1818 OpenSSL addresses set couple of environment variables from values in
1819 peer certificate, e.g.:
1820 SOCAT_OPENSSL_X509_SUBJECT, SOCAT_OPENSSL_X509_ISSUER,
1821 SOCAT_OPENSSL_X509_COMMONNAME,
1822 SOCAT_OPENSSL_X509V3_SUBJECTALTNAME_DNS
1823 Tests: ENV_OPENSSL_{CLIENT,SERVER}_X509_*
1824
1825 Added support for methods TLSv1, TLSv1.1, TLSv1.2, and DTLS1
1826 Tests: OPENSSL_METHOD_*
1827
1828 Enabled OpenSSL server side use of ECDHE ciphers. Feature suggested
1829 by Andrey Arapov.
1830
1831 Added a new option termios-rawer for ptys.
1832 Thanks to Christian Vogelgsang for pointing me to this requirement
1833
1834 corrections:
1835 Bind with ABSTRACT commands used non-abstract namespace (Linux).
1836 Test: ABSTRACT_BIND
1837 Thanks to Denis Shatov for reporting this bug.
1838
1839 Fixed return value of nestlex()
1840
1841 Option ignoreeof on the right address hung.
1842 Test: IGNOREEOF_REV
1843 Thanks to Franz Fasching for reporting this bug.
1844
1845 Address SYSTEM, when terminating, shut down its parent addresses,
1846 e.g. an SSL connection which the parent assumed to still be active.
1847 Test: SYSTEM_SHUTDOWN
1848
1849 Passive (listening or receiving) addresses with empty port field bound
1850 to a random port instead of terminating with error.
1851 Test: TCP4_NOPORT
1852
1853 configure with some combination of disable options produced config
1854 files that failed to compile due to missing IPPROTO_TCP.
1855 Thanks to Thierry Fournier for report and patch.
1856
1857 fixed a few minor bugs with OpenSSL in configure and with messages
1858
1859 Socat did not work in FIPS mode because 1024 instead of 512 bit DH prime
1860 is required. Thanks to Zhigang Wang for reporting and sending a patch.
1861
1862 Christophe Leroy provided a patch that fixes memory leaks reported by
1863 valgrind
1864
1865 Help for filan -L was bad, is now corrected to:
1866 "follow symbolic links instead of showing their properties"
1867
1868 Address options fdin and fdout were silently ignored when not applicable
1869 due to -u or -U option. Now these combinations are caught as errors.
1870 Test: FDOUT_ERROR
1871 Issue reported by Hendrik.
1872
1873 Added option termios-cfmakeraw that calls cfmakeraw() and is preferred
1874 over option raw which is now obsolete. On SysV systems this call is
1875 simulated by appropriate setting.
1876 Thanks to Youfu Zhang for reporting issue with option raw.
1877
1878 porting:
1879 Socat included <sys/poll.h> instead of POSIX <poll.h>
1880 Thanks to John Spencer for reporting this issue.
1881
1882 Version 1.7.2.4 changed the check for gcc in configure.ac; this
1883 broke cross compiling. The particular check gets reverted.
1884 Thanks to Ross Burton and Danomi Manchego for reporting this issue.
1885
1886 Debian Bug#764251: Set the build timestamp to a deterministic time:
1887 support external BUILD_DATE env var to allow to build reproducible
1888 binaries
1889
1890 Joachim Fenkes provided an new adapted spec file.
1891
1892 Type bool and macros Min and Max are defined by socat which led to
1893 compile errors when they were already provided by build framework.
1894 Thanks to Liyu Liu for providing a patch.
1895
1896 David Arnstein contributed a patch for NetBSD 5.1 including stdbool.h
1897 support and appropriate files in Config/
1898
1899 Lauri Tirkkonen contributed a patch regarding netinet/if_ether.h
1900 on Illumos
1901
1902 Changes for Openindiana: define _XPG4_2, __EXTENSIONS__,
1903 _POSIX_PTHREAD_SEMANTICS; and minor changes
1904
1905 Red Hat issue 1182005: socat 1.7.2.4 build failure missing
1906 linux/errqueue.h
1907 Socat failed to compile on on PPC due to new requirements for
1908 including <linux/errqueue.h> and a weakness in the conditional code.
1909 Thanks to Michel Normand for reporting this issue.
1910
1911 doc:
1912 In the man page the PTY example was badly formatted. Thanks to
1913 J.F.Sebastian for sending a patch.
1914
1915 Added missing CVE ids to security issues in CHANGES
1916
1917 testing:
1918 Do not distribute testcert.conf with socat source but generate it
1919 (and new testcert6.conf) during test.sh run.
1920
1921 ####################### V 1.7.2.4:
1922
1923 corrections:
1924 LISTEN based addresses applied some address options, e.g. so-keepalive,
1925 to the listening file descriptor instead of the connected file
1926 descriptor
1927 Thanks to Ulises Alonso for reporting this bug
1928
1929 make failed after configure with non gcc compiler due to missing
1930 include. Thanks to Horacio Mijail for reporting this problem
1931
1932 configure checked for --disable-rawsocket but printed
1933 --disable-genericsocket in the help text. Thanks to Ben Gardiner for
1934 reporting and patching this bug
1935
1936 In xioshutdown() a wrong branch was chosen after RECVFROM type addresses.
1937 Probably no impact.
1938 Thanks to David Binderman for reporting this issue.
1939
1940 procan could not cleanly format ulimit values longer than 16 decimal
1941 digits. Thanks to Frank Dana for providing a patch that increases field
1942 width to 24 digits.
1943
1944 OPENSSL-CONNECT with bind option failed on some systems, eg.FreeBSD, with
1945 "Invalid argument"
1946 Thanks to Emile den Tex for reporting this bug.
1947
1948 Changed some variable definitions to make gcc -O2 aliasing checker happy
1949 Thanks to Ilya Gordeev for reporting these warnings
1950
1951 On big endian platforms with type long >32bit the range option applied a
1952 bad base address. Thanks to hejia hejia for reporting and fixing this bug.
1953
1954 Red Hat issue 1022070: missing length check in xiolog_ancillary_socket()
1955
1956 Red Hat issue 1022063: out-of-range shifts on net mask bits
1957
1958 Red Hat issue 1022062: strcpy misuse in xiosetsockaddrenv_ip4()
1959
1960 Red Hat issue 1022048: strncpy hardening: corrected suspicious strncpy()
1961 uses
1962
1963 Red Hat issue 1021958: fixed a bug with faulty buffer/data length
1964 calculation in xio-ascii.c:_xiodump()
1965
1966 Red Hat issue 1021972: fixed a missing NUL termination in return string
1967 of sysutils.c:sockaddr_info() for the AF_UNIX case
1968
1969 fixed some typos and minor issues, including:
1970 Red Hat issue 1021967: formatting error in manual page
1971
1972 UNIX-LISTEN with fork option did not remove the socket file system entry
1973 when exiting. Other file system based passive address types had similar
1974 issues or failed to apply options umask, user e.a.
1975 Thanks to Lorenzo Monti for pointing me to this issue
1976
1977 porting:
1978 Red Hat issue 1020203: configure checks fail with some compilers.
1979 Use case: clang
1980
1981 Performed changes for Fedora release 19
1982
1983 Adapted, improved test.sh script
1984
1985 Red Hat issue 1021429: getgroupent fails with large number of groups;
1986 use getgrouplist() when available instead of sequence of calls to
1987 getgrent()
1988
1989 Red Hat issue 1021948: snprintf API change;
1990 Implemented xio_snprintf() function as wrapper that tries to emulate C99
1991 behaviour on old glibc systems, and adapted all affected calls
1992 appropriately
1993
1994 Mike Frysinger provided a patch that supports long long for time_t,
1995 socklen_t and a few other libc types.
1996
1997 Artem Mygaiev extended Cedril Priscals Android build script with pty code
1998
1999 The check for fips.h required stddef.h
2000 Thanks to Matt Hilt for reporting this issue and sending a patch
2001
2002 Check for linux/errqueue.h failed on some systems due to lack of
2003 linux/types.h inclusion. Thanks to Michael Vastola for sending a patch.
2004
2005 autoconf now prefers configure.ac over configure.in
2006 Thanks to Michael Vastola for sending a patch.
2007
2008 type of struct cmsghdr.cmsg is system dependent, determine it with
2009 configure; some more print format corrections
2010
2011 docu:
2012 libwrap always logs to syslog
2013
2014 added actual text version of GPLv2
2015
2016 ####################### V 1.7.2.3:
2017
2018 security:
2019 Socat security advisory 5
2020 CVE-2014-0019: socats PROXY-CONNECT address was vulnerable to a buffer
2021 overflow with data from command line (see socat-secadv5.txt)
2022 Credits to Florian Weimer of the Red Hat Product Security Team
2023
2024 ####################### V 1.7.2.2:
2025
2026 security:
2027 Socat security advisory 4
2028 CVE-2013-3571:
2029 after refusing a client connection due to bad source address or source
2030 port socat shutdown() the socket but did not close() it, resulting in
2031 a file descriptor leak in the listening process, visible with lsof and
2032 possibly resulting in EMFILE Too many open files. This issue could be
2033 misused for a denial of service attack.
2034 Full credits to Catalin Mitrofan for finding and reporting this issue.
2035
2036 ####################### V 1.7.2.1:
2037
2038 security:
2039 Socat security advisory 3
2040 CVE-2012-0219:
2041 fixed a possible heap buffer overflow in the readline address. This bug
2042 could be exploited when all of the following conditions were met:
2043 1) one of the addresses is READLINE without the noprompt and without the
2044 prompt options.
2045 2) the other (almost arbitrary address) reads malicious data (which is
2046 then transferred by socat to READLINE).
2047 Workaround: when using the READLINE address apply option prompt or
2048 noprompt.
2049 Full credits to Johan Thillemann for finding and reporting this issue.
2050
2051 ####################### V 1.7.2.0:
2052
2053 corrections:
2054 when UNIX-LISTEN was applied to an existing file it failed as expected
2055 but removed the file. Thanks to Bjoern Bosselmann for reporting this
2056 problem
2057
2058 fixed a bug where socat might crash when connecting to a unix domain
2059 socket using address GOPEN. Thanks to Martin Forssen for bug report and
2060 patch.
2061
2062 UDP-LISTEN would always set SO_REUSEADDR even without fork option and
2063 when user set it to 0. Thanks to Michal Svoboda for reporting this bug.
2064
2065 UNIX-CONNECT did not support half-close. Thanks to Greg Hughes who
2066 pointed me to that bug
2067
2068 TCP-CONNECT with option nonblock reported successful connect even when
2069 it was still pending
2070
2071 address option ioctl-intp failed with "unimplemented type 26". Thanks
2072 to Jeremy W. Sherman for reporting and fixing that bug
2073
2074 socat option -x did not print packet direction, timestamp etc; thanks
2075 to Anthony Sharobaiko for sending a patch
2076
2077 address PTY does not take any parameters but did not report an error
2078 when some were given
2079
2080 Marcus Meissner provided a patch that fixes invalid output and possible
2081 process crash when socat prints info about an unnamed unix domain
2082 socket
2083
2084 Michal Soltys reported the following problem and provided an initial
2085 patch: when socat was interrupted, e.g. by SIGSTOP, and resumed during
2086 data transfer only parts of the data might have been written.
2087
2088 Option o-nonblock in combination with large transfer block sizes
2089 may result in partial writes and/or EAGAIN errors that were not handled
2090 properly but resulted in data loss or process termination.
2091
2092 Fixed a bug that could freeze socat when during assembly of a log
2093 message a signal was handled that also printed a log message. socat
2094 development had been aware that localtime() is not thread safe but had
2095 only expected broken messages, not corrupted stack (glibc 2.11.1,
2096 Ubuntu 10.4)
2097
2098 an internal store for child pids was susceptible to pid reuse which
2099 could lead to sporadic data loss when both fork option and exec address
2100 were used. Thanks to Tetsuya Sodo for reporting this problem and
2101 sending a patch
2102
2103 OpenSSL server failed with "no shared cipher" when using cipher aNULL.
2104 Fixed by providing temporary DH parameters. Thanks to Philip Rowlands
2105 for drawing my attention to this issue.
2106
2107 UDP-LISTEN slept 1s after accepting a connection. This is not required.
2108 Thanks to Peter Valdemar Morch for reporting this issue
2109
2110 fixed a bug that could lead to error or socat crash after a client
2111 connection with option retry had been established
2112
2113 fixed configure.in bug on net/if.h check that caused IF_NAMESIZE to be
2114 undefined
2115
2116 improved dev_t print format definition
2117
2118 porting:
2119 Cedril Priscal ported socat to Android (using Googles cross compiler).
2120 The port includes the socat_buildscript_for_android.sh script
2121
2122 added check for component ipi_spec_dst in struct in_pktinfo so
2123 compilation does not fail on Cygwin (thanks to Peter Wagemans for
2124 reporting this problem)
2125
2126 build failed on RHEL6 due to presence of fips.h; configure now checks
2127 for fipsld too. Thanks to Andreas Gruenbacher for reporting this
2128 problem
2129
2130 check for netinet6/in6.h only when IPv6 is available and enabled
2131
2132 don't fail to compile when the following defines are missing:
2133 IPV6_PKTINFO IPV6_RTHDR IPV6_DSTOPTS IPV6_HOPOPTS IPV6_HOPLIMIT
2134 Thanks to Jerry Jacobs for reporting this problem (Mac OS X Lion 10.7)
2135
2136 check if define __APPLE_USE_RFC_2292 helps to enable IPV6_* (MacOSX
2137 Lion 7.1); thanks to Jerry Jacobs to reporting this problem and
2138 proposing a solution
2139
2140 fixed compiler warnings on Mac OS X 64bit. Thanks to Guy Harris for
2141 providing the patch.
2142
2143 corrections for OpenEmbedded, especially termios SHIFT values and
2144 ISPEED/OSPEED. Thanks to John Faith for providing the patch
2145
2146 minor corrections to docu and test.sh resulting from local compilation
2147 on Openmoko SHR
2148
2149 fixed sa_family_t compile error on DragonFly. Thanks to Tony Young for
2150 reporting this issue and sending a patch.
2151
2152 Ubuntu Oneiric: OpenSSL no longer provides SSLv2 functions; libutil.sh
2153 is now bsd/libutil.h; compiler warns on vars that is only written to
2154
2155 new features:
2156 added option max-children that limits the number of concurrent child
2157 processes. Thanks to Sam Liddicott for providing the patch.
2158
2159 Till Maas added support for tun/tap addresses without IP address
2160
2161 added an option openssl-compress that allows to disable the compression
2162 feature of newer OpenSSL versions. Thanks to Michael Hanselmann for
2163 providing this contribution (sponsored by Google Inc.)
2164
2165 docu:
2166 minor corrections in docu (thanks to Paggas)
2167
2168 client process -> child process
2169
2170 ####################### V 1.7.1.3:
2171
2172 security:
2173 Socat security advisory 2
2174 CVE-2010-2799:
2175 fixed a stack overflow vulnerability that occurred when command
2176 line arguments (whole addresses, host names, file names) were longer
2177 than 512 bytes.
2178 Note that this could only be exploited when an attacker was able to
2179 inject data into socat's command line.
2180 Full credits to Felix Gröbert, Google Security Team, for finding and
2181 reporting this issue
2182
2183 ####################### V 1.7.1.2:
2184
2185 corrections:
2186 user-late and group-late, when applied to a pty, affected the system
2187 device /dev/ptmx instead of the pty (thanks to Matthew Cloke for
2188 pointing me to this bug)
2189
2190 socats openssl addresses failed with "nonblocking operation did not
2191 complete" when the peer performed a renegotiation. Thanks to Benjamin
2192 Delpy for reporting this bug.
2193
2194 info message during socks connect showed bad port number on little
2195 endian systems due to wrong byte order (thanks to Peter M. Galbavy for
2196 bug report and patch)
2197
2198 Debian bug 531078: socat execs children with SIGCHLD ignored; corrected
2199 to default. Thanks to Martin Dorey for reporting this bug.
2200
2201 porting:
2202 building socat on systems that predefined the CFLAGS environment to
2203 contain -Wall failed (esp.RedHat). Thanks to Paul Wouters for reporting
2204 this problem and to Simon Matter for providing the patch
2205
2206 support for Solaris 8 and Sun Studio support (thanks to Sebastian
2207 Kayser for providing the patches)
2208
2209 on some 64bit systems a compiler warning "cast from pointer to integer
2210 of different size" was issued on some option definitions
2211
2212 added struct sockaddr_ll to union sockaddr_union to avoid "strict
2213 aliasing" warnings (problem reported by Paul Wouters)
2214
2215 docu:
2216 minor corrections in docu
2217
2218 ####################### V 1.7.1.1:
2219
2220 corrections:
2221 corrected the "fixed possible SIGSEGV" fix because SIGSEGV still might
2222 occur under those conditions. Thanks to Toni Mattila for first
2223 reporting this problem.
2224
2225 ftruncate64 cut its argument to 32 bits on systems with 32 bit long type
2226
2227 socat crashed on systems without setenv() (esp. SunOS up to Solaris 9);
2228 thanks to Todd Stansell for reporting this bug
2229
2230 with unidirectional EXEC and SYSTEM a close() operation was performed
2231 on a random number which could result in hanging e.a.
2232
2233 fixed a compile problem caused by size_t/socklen_t mismatch on 64bit
2234 systems
2235
2236 docu mentioned option so-bindtodev but correct name is so-bindtodevice.
2237 Thanks to Jim Zimmerman for reporting.
2238
2239 docu changes:
2240 added environment variables example to doc/socat-multicast.html
2241
2242 ####################### V 1.7.1.0:
2243
2244 new features:
2245 address options shut-none, shut-down, and shut-close allow to control
2246 socat's half close behaviour
2247
2248 with address option shut-null socat sends an empty packet to the peer
2249 to indicate EOF
2250
2251 option null-eof changes the behaviour of sockets that receive an empty
2252 packet to see EOF instead of ignoring it
2253
2254 introduced option names substuser-early and su-e, currently equivalent
2255 to option substuser (thanks to Mike Perry for providing the patch)
2256
2257 corrections:
2258 fixed some typos and improved some comments
2259
2260 ####################### V 1.7.0.1:
2261
2262 corrections:
2263 fixed possible SIGSEGV in listening addresses when a new connection was
2264 reset by peer before the socket addresses could be retrieved. Thanks to
2265 Mike Perry for sending a patch.
2266
2267 fixed a bug, introduced with version 1.7.0.0, that let client
2268 connections with option connect-timeout fail when the connections
2269 succeeded. Thanks to Bruno De Fraine for reporting this bug.
2270
2271 option end-close "did not apply" to addresses PTY, SOCKET-CONNECT,
2272 and most UNIX-* and ABSTRACT-*
2273
2274 half close of EXEC and SYSTEM addresses did not work for pipes and
2275 sometimes socketpair
2276
2277 help displayed for some option a wrong type
2278
2279 under some circumstances shutdown was called multiple times for the
2280 same fd
2281
2282 ####################### V 1.7.0.0:
2283
2284 new features:
2285 new address types SCTP-CONNECT and SCTP-LISTEN implement SCTP stream
2286 mode for IPv4 and IPv6; new address options sctp-maxseg and
2287 sctp-nodelay (suggested by David A. Madore; thanks to Jonathan Brannan
2288 for providing an initial patch)
2289
2290 new address "INTERFACE" for transparent network interface handling
2291 (suggested by Stuart Nicholson)
2292
2293 added generic socket addresses: SOCKET-CONNECT, SOCKET-LISTEN,
2294 SOCKET-SENDTO, SOCKET-RECVFROM, SOCKET-RECV, SOCKET-DATAGRAM allow
2295 protocol independent socket handling; all parameters are explicitly
2296 specified as numbers or hex data
2297
2298 added address options ioctl-void, ioctl-int, ioctl-intp, ioctl-string,
2299 ioctl-bin for generic ioctl() calls.
2300
2301 added address options setsockopt-int, setsockopt-bin, and
2302 setsockopt-string for generic setsockopt() calls
2303
2304 option so-type now only affects the socket() and socketpair() calls,
2305 not the name resolution. so-type and so-prototype can now be applied to
2306 all socket based addresses.
2307
2308 new address option "escape" allows to break a socat instance even when
2309 raw terminal mode prevents ^C etc. (feature suggested by Guido Trotter)
2310
2311 socat sets environment variables SOCAT_VERSION, SOCAT_PID, SOCAT_PPID
2312 for use in executed scripts
2313
2314 socat sets environment variables SOCAT_SOCKADDR, SOCAT_SOCKPORT,
2315 SOCAT_PEERADDR, SOCAT_PEERPORT in LISTEN type addresses (feature
2316 suggested by Ed Sawicki)
2317
2318 socat receives all ancillary messages with each received packet on
2319 datagram related addresses. The messages are logged in raw form with
2320 debug level, and broken down with info level. note: each type of
2321 ancillary message must be enabled by appropriate address options.
2322
2323 socat provides the contents of ancillary messages received on RECVFROM
2324 addresses in appropriate environment variables:
2325 SOCAT_TIMESTAMP, SOCAT_IP_DSTADDR, SOCAT_IP_IF, SOCAT_IP_LOCADDR,
2326 SOCAT_IP_OPTIONS, SOCAT_IP_TOS, SOCAT_IP_TTL, SOCAT_IPV6_DSTADDR,
2327 SOCAT_IPV6_HOPLIMIT, SOCAT_IPV6_TCLASS
2328
2329 the following address options were added to enable ancillary messages:
2330 so-timestamp, ip-pktinfo (not BSD), ip-recvdstaddr (BSD), ip-recverr,
2331 ip-recvif (BSD), ip-recvopts, ip-recvtos, ip-recvttl, ipv6-recvdstopts,
2332 ipv6-recverr, ipv6-recvhoplimit, ipv6-recvhopopts, ipv6-recvpathmtu,
2333 ipv6-recvpktinfo, ipv6-recvrthdr, ipv6-recvtclass
2334
2335 new address options ipv6-tclass and ipv6-unicast-hops set the related
2336 socket options.
2337
2338 STREAMS (UNIX System V STREAMS) can be configured with the new address
2339 options i-pop-all and i-push (thanks to Michal Rysavy for providing a
2340 patch)
2341
2342 corrections:
2343 some raw IP and UNIX datagram modes failed on BSD systems
2344
2345 when UDP-LISTEN continued to listen after packet dropped by, e.g.,
2346 range option, the old listen socket would not be closed but a new one
2347 created. open sockets could accumulate.
2348
2349 there was a bug in ip*-recv with bind option: it did not bind, and
2350 with the first received packet an error occurred:
2351 socket_init(): unknown address family 0
2352 test: RAWIP4RECVBIND
2353
2354 RECVFROM addresses with FORK option hung after processing the first
2355 packet. test: UDP4RECVFROM_FORK
2356
2357 corrected a few mistakes that caused compiler warnings on 64bit hosts
2358 (thanks to Jonathan Brannan e.a. for providing a patch)
2359
2360 EXEC and SYSTEM with stderr injected socat messages into the data
2361 stream. test: EXECSTDERRLOG
2362
2363 when the EXEC address got a string with consecutive spaces it created
2364 additional empty arguments (thanks to Olivier Hervieu for reporting
2365 this bug). test: EXECSPACES
2366
2367 in ignoreeof polling mode socat also blocked data transfer in the other
2368 direction during the 1s wait intervals (thanks to Jorgen Cederlof for
2369 reporting this bug)
2370
2371 corrected alphabetical order of options (proxy-auth)
2372
2373 some minor corrections
2374
2375 improved test.sh script: more stable timing, corrections for BSD
2376
2377 replaced the select() calls by poll() to cleanly fix the problems with
2378 many file descriptors already open
2379
2380 socat option -lf did not log to file but to stderr
2381
2382 socat did not compile on Solaris when configured without termios
2383 feature (thanks to Pavan Gadi for reporting this bug)
2384
2385 porting:
2386 socat compiles and runs on AIX with gcc (thanks to Andi Mather for his
2387 help)
2388
2389 socat compiles and runs on Cygwin (thanks to Jan Just Keijser for his
2390 help)
2391
2392 socat compiles and runs on HP-UX with gcc (thanks to Michal Rysavy for
2393 his help)
2394
2395 socat compiles and runs on MacOS X (thanks to Camillo Lugaresi for his
2396 help)
2397
2398 further changes:
2399 filan -s prefixes output with FD number if more than one FD
2400
2401 Makefile now supports datarootdir (thanks to Camillo Lugaresi for
2402 providing the patch)
2403
2404 cleanup in xio-unix.c
2405
2406 ####################### V 1.6.0.1:
2407
2408 new features:
2409 new make target "gitclean"
2410
2411 docu source doc/socat.yo released
2412
2413 corrections:
2414 exec:...,pty did not kill child process under some circumstances; fixed
2415 by correcting typo in xio-progcall.c (thanks to Ralph Forsythe for
2416 reporting this problem)
2417
2418 service name resolution failed due to byte order mistake
2419 (thanks to James Sainsbury for reporting this problem)
2420
2421 socat would hang when invoked with many file descriptors already opened
2422 fix: replaced FOPEN_MAX with FD_SETSIZE
2423 thanks to Daniel Lucq for reporting this problem.
2424
2425 fixed bugs where sub processes would become zombies because the master
2426 process did not catch SIGCHLD. this affected addresses UDP-LISTEN,
2427 UDP-CONNECT, TCP-CONNECT, OPENSSL, PROXY, UNIX-CONNECT, UNIX-CLIENT,
2428 ABSTRACT-CONNECT, ABSTRACT-CLIENT, SOCKSA, SOCKS4A
2429 (thanks to Fernanda G Weiden for reporting this problem)
2430
2431 fixed a bug where sub processes would become zombies because the master
2432 process caught SIGCHLD but did not wait(). this affected addresses
2433 UDP-RECVFROM, IP-RECVFROM, UNIX-RECVFROM, ABSTRACT-RECVFROM
2434 (thanks to Evan Borgstrom for reporting this problem)
2435
2436 corrected option handling with STDIO; usecase: cool-write
2437
2438 configure --disable-pty also disabled option waitlock
2439
2440 fixed small bugs on systems with struct ip_mreq without struct ip_mreqn
2441 (thanks to Roland Illig for sending a patch)
2442
2443 corrected name of option intervall to interval (old form still valid
2444 for us German speaking guys)
2445
2446 corrected some print statements and variable names
2447
2448 make uninstall did not uninstall procan
2449
2450 fixed lots of weaknesses in test.sh
2451
2452 corrected some bugs and typos in doc/socat.yo, EXAMPLES, C comments
2453
2454 further changes:
2455 procan -c prints C defines important for socat
2456
2457 added test OPENSSLEOF for OpenSSL half close
2458
2459 ####################### V 1.6.0.0:
2460
2461 new features:
2462 new addresses IP-DATAGRAM and UDP-DATAGRAM allow versatile broadcast
2463 and multicast modes
2464
2465 new option ip-add-membership for control of multicast group membership
2466
2467 new address TUN for generation of Linux TUN/TAP pseudo network
2468 interfaces (suggested by Mat Caughron); associated options tun-device,
2469 tun-name, tun-type; iff-up, iff-promisc, iff-noarp, iff-no-pi etc.
2470
2471 new addresses ABSTRACT-CONNECT, ABSTRACT-LISTEN, ABSTRACT-SENDTO,
2472 ABSTRACT-RECV, and ABSTRACT-RECVFROM for abstract UNIX domain addresses
2473 on Linux (requested by Zeeshan Ali); option unix-tightsocklen controls
2474 socklen parameter on system calls.
2475
2476 option end-close for control of connection closing allows FD sharing
2477 by sub processes
2478
2479 range option supports form address:mask with IPv4
2480
2481 changed behaviour of OPENSSL-LISTEN to require and verify client
2482 certificate per default
2483
2484 options f-setlkw-rd, f-setlkw-wr, f-setlk-rd, f-setlk-wr allow finer
2485 grained locking on regular files
2486
2487 uninstall target in Makefile (lack reported by Zeeshan Ali)
2488
2489 corrections:
2490 fixed bug where only first tcpwrap option was applied; fixed bug where
2491 tcpwrap IPv6 check always failed (thanks to Rudolf Cejka for reporting
2492 and fixing this bug)
2493
2494 filan (and socat -D) could hang when a socket was involved
2495
2496 corrected PTYs on HP-UX (and maybe others) using STREAMS (inspired by
2497 Roberto Mackun)
2498
2499 correct bind with udp6-listen (thanks to Jan Horak for reporting this
2500 bug)
2501
2502 corrected filan.c peekbuff[0] which did not compile with Sun Studio Pro
2503 (thanks to Leo Zhadanovsky for reporting this problem)
2504
2505 corrected problem with read data buffered in OpenSSL layer (thanks to
2506 Jon Nelson for reporting this bug)
2507
2508 corrected problem with option readbytes when input stream stayed idle
2509 after so many bytes
2510
2511 fixed a bug where a datagram receiver with option fork could fork two
2512 sub processes per packet
2513
2514 further changes:
2515 moved documentation to new doc/ subdir
2516
2517 new documents (kind of mini tutorials) are provided in doc/
2518
2519 ####################### V 1.5.0.0:
2520
2521 new features:
2522 new datagram modes for udp, rawip, unix domain sockets
2523
2524 socat option -T specifies inactivity timeout
2525
2526 rewrote lexical analysis to allow nested socat calls
2527
2528 addresses tcp, udp, tcp-l, udp-l, and rawip now support IPv4 and IPv6
2529
2530 socat options -4, -6 and environment variables SOCAT_DEFAULT_LISTEN_IP,
2531 SOCAT_PREFERRED_RESOLVE_IP for control of protocol selection
2532
2533 addresses ssl, ssl-l, socks, proxy now support IPv4 and IPv6
2534
2535 option protocol-family (pf), esp. for openssl-listen
2536
2537 range option supports IPv6 - syntax: range=[::1/128]
2538
2539 option ipv6-v6only (ipv6only)
2540
2541 new tcp-wrappers options allow-table, deny-table, tcpwrap-etc
2542
2543 FIPS version of OpenSSL can be integrated - initial patch provided by
2544 David Acker. See README.FIPS
2545
2546 support for resolver options res-debug, aaonly, usevc, primary, igntc,
2547 recurse, defnames, stayopen, dnsrch
2548
2549 options for file attributes on advanced filesystems (ext2, ext3,
2550 reiser): secrm, unrm, compr, ext2-sync, immutable, ext2-append, nodump,
2551 ext2-noatime, journal-data etc.
2552
2553 option cool-write controls severeness of write failure (EPIPE,
2554 ECONNRESET)
2555
2556 option o-noatime
2557
2558 socat option -lh for hostname in log output
2559
2560 traffic dumping provides packet headers
2561
2562 configure.in became part of distribution
2563
2564 socats unpack directory now has full version, e.g. socat-1.5.0.0/
2565
2566 corrected docu of option verify
2567
2568 corrections:
2569 fixed tcpwrappers integration - initial fix provided by Rudolf Cejka
2570
2571 exec with pipes,stderr produced error
2572
2573 setuid-early was ignored with many address types
2574
2575 some minor corrections
2576
2577 ####################### V 1.4.3.1:
2578
2579 corrections:
2580 PROBLEM: UNIX socket listen accepted only one (or a few) connections.
2581 FIX: do not remove listening UNIX socket in child process
2582
2583 PROBLEM: SIGSEGV when TCP part of SSL connect failed
2584 FIX: check ssl pointer before calling SSL_shutdown
2585
2586 In debug mode, show connect client port even when connect fails
2587
2588 ####################### V 1.4.3.0:
2589
2590 new features:
2591 socat options -L, -W for application level locking
2592
2593 options "lockfile", "waitlock" for address level locking
2594 (Stefan Luethje)
2595
2596 option "readbytes" limits read length (Adam Osuchowski)
2597
2598 option "retry" for unix-connect, unix-listen, tcp6-listen (Dale Dude)
2599
2600 pty symlink, unix listen socket, and named pipe are per default removed
2601 after use; option unlink-close overrides this new behaviour and also
2602 controls removal of other socat generated files (Stefan Luethje)
2603
2604 corrections:
2605 option "retry" did not work with tcp-listen
2606
2607 EPIPE condition could result in a 100% CPU loop
2608
2609 further changes:
2610 support systems without SHUT_RD etc.
2611 handle more size_t types
2612 try to find makedepend options with gcc 3 (richard/OpenMacNews)
2613
2614 ####################### V 1.4.2.0:
2615
2616 new features:
2617 option "connect-timeout" limits wait time for connect operations
2618 (requested by Giulio Orsero)
2619
2620 option "dhparam" for explicit Diffie-Hellman parameter file
2621
2622 corrections:
2623 support for OpenSSL DSA certificates (Miika Komu)
2624
2625 create install directories before copying files (Miika Komu)
2626
2627 when exiting on signal, return status 128+signum instead of 1
2628
2629 on EPIPE and ECONNRESET, only issue a warning (Santiago Garcia
2630 Mantinan)
2631
2632 -lu could cause a core dump on long messages
2633
2634 further changes:
2635 modifications to simplify using socats features in applications
2636
2637 ####################### V 1.4.1.0:
2638
2639 new features:
2640 option "wait-slave" blocks open of pty master side until a client
2641 connects, "pty-intervall" controls polling
2642
2643 option -h as synonym to -? for help (contributed by Christian
2644 Lademann)
2645
2646 filan prints formatted time stamps and rdev (disable with -r)
2647
2648 redirect filan's output, so stdout is not affected (contributed by
2649 Luigi Iotti)
2650
2651 filan option -L to follow symbolic links
2652
2653 filan shows termios control characters
2654
2655 corrections:
2656 proxy address no longer performs unsolicited retries
2657
2658 filan -f no longer needs read permission to analyze a file (but still
2659 needs access permission to directory, of course)
2660
2661 porting:
2662 Option dsusp
2663 FreeBSD options noopt, nopush, md5sig
2664 OpenBSD options sack-disable, signature-enable
2665 HP-UX, Solaris options abort-threshold, conn-abort-threshold
2666 HP-UX options b900, b3600, b7200
2667 Tru64/OSF1 options keepinit, paws, sackena, tsoptena
2668
2669 further corrections:
2670 address pty now uses ptmx as default if openpty is also available
2671
2672 ####################### V 1.4.0.3:
2673
2674 security:
2675 Socat security advisory 1
2676 CVE-2004-1484:
2677 fix to a syslog() based format string vulnerability that can lead to
2678 remote code execution. See advisory socat-adv-1.txt
2679
2680 ####################### V 1.4.0.2:
2681
2682 corrections:
2683 exec'd write-only addresses get a chance to flush before being killed
2684
2685 error handler: print notice on error-exit
2686
2687 filan printed wrong file type information
2688
2689 ####################### V 1.4.0.1:
2690
2691 corrections:
2692 socks4a constructed invalid header. Problem found, reported, and fixed
2693 by Thomas Themel, by Peter Palfrader, and by rik
2694
2695 with nofork, don't forget to apply some process related options
2696 (chroot, setsid, setpgid, ...)
2697
2698 ####################### V 1.4.0.0:
2699
2700 new features:
2701 simple openssl server (ssl-l), experimental openssl trust
2702
2703 new options "cafile", "capath", "key", "cert", "egd", and "pseudo" for
2704 openssl
2705
2706 new options "retry", "forever", and "intervall"
2707
2708 option "fork" for address TCP improves `gender changer´
2709
2710 options "sigint", "sigquit", and "sighup" control passing of signals to
2711 sub process (thanks to David Shea who contributed to this issue)
2712
2713 readline takes respect to the prompt issued by the peer address
2714
2715 options "prompt" and "noprompt" allow to override readline's new
2716 default behaviour
2717
2718 readline supports invisible password with option "noecho"
2719
2720 socat option -lp allows to set hostname in log output
2721
2722 socat option -lu turns on microsecond resolution in log output
2723
2724
2725 corrections:
2726 before reading available data, check if writing on other channel is
2727 possible
2728
2729 tcp6, udp6: support hostname specification (not only IP address), and
2730 map IP4 names to IP6 addresses
2731
2732 openssl client checks server certificate per default
2733
2734 support unidirectional communication with exec/system subprocess
2735
2736 try to restore original terminal settings when terminating
2737
2738 test.sh uses tmp dir /tmp/$USER/$$ instead of /tmp/$$
2739
2740 socks4 failed on platforms where long does not have 32 bits
2741 (thanks to Peter Palfrader and Thomas Seyrat)
2742
2743 hstrerror substitute wrote wrong messages (HP-UX, Solaris)
2744
2745 proxy error message was truncated when answer contained multiple spaces
2746
2747
2748 porting:
2749 compiles with AIX xlc, HP-UX cc, Tru64 cc (but might not link)
2750
2751 ####################### V 1.3.2.2:
2752
2753 corrections:
2754 PROXY CONNECT failed when the status reply from the proxy server
2755 contained more than one consecutive spaces. Problem reported by
2756 Alexandre Bezroutchko
2757
2758 do not SIGSEGV when proxy address fails to resolve server name
2759
2760 udp-listen failed on systems where AF_INET != SOCK_DGRAM (e.g. SunOS).
2761 Problem reported by Christoph Schittel
2762
2763 test.sh only tests available features
2764
2765 added missing IP and TCP options in filan analyzer
2766
2767 do not apply stdio address options to both directions when in
2768 unidirectional mode
2769
2770 on systems lacking /dev/*random and egd, provide (weak) entropy from
2771 libc random()
2772
2773
2774 porting:
2775 changes for HP-UX (VREPRINT, h_NETDB_INTERNAL)
2776
2777 compiles on True64, FreeBSD (again), NetBSD, OpenBSD
2778
2779 support for long long as st_ino type (Cygwin 1.5)
2780
2781 compile on systems where pty can not be featured
2782
2783 ####################### V 1.3.2.1:
2784
2785 corrections:
2786 "final" solution for the ENOCHLD problem
2787
2788 corrected "make strip"
2789
2790 default gcc debug/opt is "-O" again
2791
2792 check for /proc at runtime, even if configure found it
2793
2794 src.rpm accidentally supported SuSE instead of RedHat
2795
2796 ####################### V 1.3.2.0:
2797
2798 new features:
2799 option "nofork" connects an exec'd script or program directly
2800 to the file descriptors of the other address, circumventing the socat
2801 transfer engine
2802
2803 support for files >2GB, using ftruncate64(), lseek64(), stat64()
2804
2805 filan has new "simple" output style (filan -s)
2806
2807
2808 porting:
2809 options "binary" and "text" for controlling line termination on Cygwin
2810 file system access (hint from Yang Wu-Zhou)
2811
2812 fix by Yang Wu-Zhou for the Cygwin "No Children" problem
2813
2814 improved support for OSR: _SVID3; no IS_SOCK, no F_GETOWN (thanks to
2815 John DuBois)
2816
2817 minor corrections to avoid warnings with gcc 3
2818
2819
2820 further corrections and minor improvements:
2821 configure script is generated with autoconf 2.57 (no longer 2.52)
2822
2823 configure passes CFLAGS to Makefile
2824
2825 option -??? for complete list of address options and their short forms
2826
2827 program name in syslog messages is derived from argv[0]
2828
2829 SIGHUP now prints notice instead of error
2830
2831 EIO during read of pty now gives Notice instead of Error, and
2832 triggers EOF
2833
2834 use of hstrerror() for printing resolver error messages
2835
2836 setgrent() got required endgrent()
2837
2838 ####################### V 1.3.1.0:
2839
2840 new features:
2841 integration of Wietse Venema's tcpwrapper library (libwrap)
2842
2843 with "proxy" address, option "resolve" controls if hostname or IP
2844 address is sent in request
2845
2846 option "lowport" establishes limited authorization for TCP and UDP
2847 connections
2848
2849 improvement of .spec file for RPM creation (thanks to Gerd v. Egidy)
2850 An accompanying change in the numbering scheme results in an
2851 incompatibility with earlier socat RPMs!
2852
2853
2854 solved problems and bugs:
2855 PROBLEM: socat daemon terminated when the address of a connecting
2856 client did not match range option value instead of continue listening
2857 SOLVED: in this case, print warning instead of error to keep daemon
2858 active
2859
2860 PROBLEM: tcp-listen with fork sometimes left excessive number of zombie
2861 processes
2862 SOLVED: dont assume that each exiting child process generates SIGCHLD
2863
2864 when converting CRNL to CR, socat converted to NL
2865
2866
2867 further corrections:
2868 configure script now disables features that depend on missing files
2869 making it more robust in "unsupported" environments
2870
2871 server.pem permissions corrected to 600
2872
2873 "make install" now does not strip; use "make strip; make install"
2874 if you like strip (suggested by Peter Bray)
2875
2876 ####################### V 1.3.0.1:
2877
2878 solved problems and bugs:
2879 PROBLEM: OPENSSL did not apply tcp, ip, and socket options
2880 SOLVED: OPENSSL now correctly handles the options list
2881
2882 PROBLEM: CRNL to NL and CRNL to CR conversions failed when CRNL crossed
2883 block boundary
2884 SOLVED: these conversions now simply strip all CR's or NL's from input
2885 stream
2886
2887
2888 porting:
2889 SunOS ptys now work on x86, too (thanks to Peter Bray)
2890
2891 configure looks for freeware libs in /pkgs/lib/ (thanks to Peter Bray)
2892
2893
2894 further corrections:
2895 added WITH_PROXY value to -V output
2896
2897 added compile dependencies of WITH_PTY and WITH_PROXY
2898
2899 -?? did not print option group of proxy options
2900
2901 corrected syntax for bind option in docu
2902
2903 corrected an issue with stdio in unidirectional mode
2904
2905 options socksport and proxyport support service names
2906
2907 ftp.sh script supports proxy address
2908
2909 man page no longer installed with execute permissions (thanks to Peter
2910 Bray)
2911
2912 fixed a malloc call bug that could cause SIGSEGV or false "out of
2913 memory" errors on EXEC and SYSTEM, depending on program name length and
2914 libc.
2915
2916 ####################### V 1.3.0.0:
2917
2918 new features:
2919 proxy connect with optional proxy authentication
2920
2921 combined hex and text dump mode, credits to Gregory Margo
2922
2923 address pty applies options user, group, and perm to device
2924
2925
2926 solved problems and bugs:
2927 PROBLEM: option reuseport was not applied (BSD, AIX)
2928 SOLVED: option reuseport now in phase PASTSOCKET instead of PREBIND,
2929 credits to Jean-Baptiste Marchand
2930
2931 PROBLEM: ignoreeof with stdio was ignored
2932 SOLVED: ignoreeof now works correctly with address stdio
2933
2934 PROBLEM: ftp.sh did not use user supplied password
2935 SOLVED: ftp.sh now correctly passes password from command line
2936
2937 PROBLEM: server.pem had expired
2938 SOLVED: new server.pem valid for ten years
2939
2940 PROBLEM: socks notice printed wrong port on some platforms
2941 SOLVED: socks now uses correct byte-order for port number in notice
2942
2943
2944 further corrections:
2945 option name o_trunc corrected to o-trunc
2946
2947 combined use of -u and -U is now detected and prevented
2948
2949 made message system a little more robust against format string attacks
2950
2951
2952 ####################### V 1.2.0.0:
2953
2954 new features:
2955 address pty for putting socat behind a new pseudo terminal that may
2956 fake a serial line, modem etc.
2957
2958 experimental openssl integration
2959 (it does not provide any trust between the peers because is does not
2960 check certificates!)
2961
2962 options flock-ex, flock-ex-nb, flock-sh, flock-sh-nb to control all
2963 locking mechanism provided by flock()
2964
2965 options setsid and setpgid now available with all address types
2966
2967 option ctty (controlling terminal) now available for all TERMIOS
2968 addresses
2969
2970 option truncate (a hybrid of open(.., O_TRUNC) and ftruncate()) is
2971 replaced by options o-trunc and ftruncate=offset
2972
2973 option sourceport now available with TCP and UDP listen addresses to
2974 restrict incoming client connections
2975
2976 unidirectional mode right-to-left (-U)
2977
2978
2979 solved problems and bugs:
2980 PROBLEM: addresses without required parameters but an option containing
2981 a '/' were incorrectly interpreted as implicit GOPEN address
2982 SOLVED: if an address does not have ':' separator but contains '/',
2983 check if the slash is before the first ',' before assuming
2984 implicit GOPEN.
2985
2986
2987 porting:
2988 ptys under SunOS work now due to use of stream options
2989
2990
2991 further corrections:
2992 with -d -d -d -d -D, don't print debug info during file analysis
2993
2994
2995 ####################### V 1.1.0.1:
2996
2997 new features:
2998 .spec file for RPM generation
2999
3000
3001 solved problems and bugs:
3002 PROBLEM: GOPEN on socket did not apply option unlink-late
3003 SOLUTION: GOPEN for socket now applies group NAMED, phase PASTOPEN
3004 options
3005
3006 PROBLEM: with unidirectional mode, an unnecessary close timeout was
3007 applied
3008 SOLUTION: in unidirectional mode, terminate without wait time
3009
3010 PROBLEM: using GOPEN on a unix domain socket failed for datagram
3011 sockets
3012 SOLUTION: when connect() fails with EPROTOTYPE, use a datagram socket
3013
3014
3015 further corrections:
3016
3017 open() flag options had names starting with "o_", now corrected to "o-"
3018
3019 in docu, *-listen addresses were called *_listen
3020
3021 address unix now called unix-connect because it does not handle unix
3022 datagram sockets
3023
3024 in test.sh, apply global command line options with all tests
3025
3026
3027 ####################### V 1.1.0.0:
3028
3029 new features:
3030 regular man page and html doc - thanks to kromJx for prototype
3031
3032 new address type "readline", utilizing GNU readline and history libs
3033
3034 address option "history-file" for readline
3035
3036 new option "dash" to "exec" address that allows to start login shells
3037
3038 syslog facility can be set per command line option
3039
3040 new address option "tcp-quickack", found in Linux 2.4
3041
3042 option -g prevents option group checking
3043
3044 filan and procan can print usage
3045
3046 procan prints rlimit infos
3047
3048
3049 solved problems and bugs:
3050 PROBLEM: raw IP socket SIGSEGV'ed when it had been shut down.
3051 SOLVED: set eof flag of channel on shutdown.
3052
3053 PROBLEM: if channel 2 uses a single non-socket FD in bidirectional mode
3054 and has data available while channel 1 reaches EOF, the data is
3055 lost.
3056 SOLVED: during one loop run, first handle all data transfers and
3057 _afterwards_ handle EOF.
3058
3059 PROBLEM: despite to option NONBLOCK, the connect() call blocked
3060 SOLVED: option NONBLOCK is now applied in phase FD instead of LATE
3061
3062 PROBLEM: UNLINK options issued error when file did not exist,
3063 terminating socat
3064 SOLVED: failure of unlink() is only warning if errno==ENOENT
3065
3066 PROBLEM: TCP6-LISTEN required numeric port specification
3067 SOLVED: now uses common TCP service resolver
3068
3069 PROBLEM: with PIPE, wrong FDs were shown for data transfer loop
3070 SOLVED: retrieval of FDs now pays respect to PIPE peculiarities
3071
3072 PROBLEM: using address EXEC against an address with IGNOREEOF, socat
3073 never terminated
3074 SOLVED: corrected EOF handling of sigchld
3075
3076
3077 porting:
3078 MacOS and old AIX versions now have pty
3079
3080 flock() now available on Linux (configure check was wrong)
3081
3082 named pipe were generated using mknod(), which requires root under BSD
3083 now they are generated using mkfifo
3084
3085
3086 further corrections:
3087 lots of address options that were "forgotten" at runtime are now
3088 available
3089
3090 option BINDTODEVICE now also called SO-BINDTODEVICE, IF
3091
3092 "make install" now installs binaries with ownership 0:0
3093
3094
3095 ####################### V 1.0.4.2:
3096
3097 solved problems and bugs:
3098 PROBLEM: EOF of one stream caused close of other stream, giving it no
3099 chance to go down regularly
3100 SOLVED: EOF of one stream now causes shutdown of write part of other
3101 stream
3102
3103 PROBLEM: sending mail via socks address to qmail showed that crlf
3104 option does not work
3105 SOLVED: socks address applies PH_LATE options
3106
3107 PROBLEM: in debug mode, no info about socat and platform was issued
3108 SOLVED: print socat version and uname output in debug mode
3109
3110 PROBLEM: invoking socat with -t and no following parameters caused
3111 SIGSEGV
3112 SOLVED: -t and -b now check next argv entry
3113
3114 PROBLEM: when opening of logfile (-lf) failed, no error was reported
3115 and no further messages were printed
3116 SOLVED: check result of fopen and print error message if it failed
3117
3118 new features:
3119 address type UDP-LISTEN now supports option fork: it internally applies
3120 socket option SO_REUSEADDR so a new UDP socket can bind to port after
3121 `accepting´ a connection (child processes might live forever though)
3122 (suggestion from Damjan Lango)
3123
3124
3125 ####################### V 1.0.4.1:
3126
3127 solved problems and bugs:
3128 PROB: assert in libc caused an endless recursion
3129 SOLVED: no longer catch SIGABRT
3130
3131 PROB: socat printed wrong verbose prefix for "right to left" packets
3132 SOLVED: new parameter for xiotransfer() passes correct prefix
3133
3134 new features:
3135 in debug mode, socat prints its command line arguments
3136 in verbose mode, escape special characters and replace unprintables
3137 with '.'. Patch from Adrian Thurston.
3138
3139
3140 ####################### V 1.0.4.0:
3141
3142 solved problems and bugs:
3143 Debug output for lstat and fstat said "stat"
3144
3145 further corrections:
3146 FreeBSD now includes libutil.h
3147
3148 new features:
3149 option setsid with exec/pty
3150 option setpgid with exec/pty
3151 option ctty with exec/pty
3152 TCP V6 connect test
3153 gettimeofday in sycls.c (no use yet)
3154
3155 porting:
3156 before Gethostbyname, invoke inet_aton for MacOSX
3157
3158
3159 ####################### V 1.0.3.0:
3160
3161 solved problems and bugs:
3162
3163 PROB: test 9 of test.sh (echo via file) failed on some platforms,
3164 socat exited without error message
3165 SOLVED: _xioopen_named_early(): preset statbuf.st_mode with 0
3166
3167 PROB: test 17 hung forever
3168 REASON: child death before select loop did not result in EOF
3169 SOLVED: check of existence of children before starting select loop
3170
3171 PROB: test 17 failed
3172 REASON: child dead triggered EOF before last data was read
3173 SOLVED: after child death, read last data before setting EOF
3174
3175 PROB: filan showed that exec processes incorrectly had fd3 open
3176 REASON: inherited open fd3 from main process
3177 SOLVED: set CLOEXEC flag on pty fd in main process
3178
3179 PROB: help printed "undef" instead of group "FORK"
3180 SOLVED: added "FORK" to group name array
3181
3182 PROB: fatal messages did not include severity classifier
3183 SOLVED: added "F" to severity classifier array
3184
3185 PROB: IP6 addresses where printed incorrectly
3186 SOLVED: removed type casts to unsigned short *
3187
3188 further corrections:
3189 socat catches illegal -l modes
3190 corrected error message on setsockopt(linger)
3191 option tabdly is of type uint
3192 correction for UDP over IP6
3193 more cpp conditionals, esp. for IP6 situations
3194 better handling of group NAMED options with listening UNIX sockets
3195 applyopts2 now includes last given phase
3196 corrected option group handling for most address types
3197 introduce dropping of unappliable options (dropopts, dropopts2)
3198 gopen now accepts socket and unix-socket options
3199 exec and system now accept all socket and termios options
3200 child process for exec and system addresses with option pty
3201 improved descriptions and options for EXAMPLES
3202 printf format for file mode changed to "0%03o" with length spec.
3203 added va_end() in branch of msg()
3204 changed phase of lock options from PASTOPEN to FD
3205 support up to four early dying processes
3206
3207 structural changes:
3208 xiosysincludes now includes sysincludes.h for non xio files
3209
3210 new features:
3211 option umask
3212 CHANGES file
3213 TYPE_DOUBLE, u_double
3214 OFUNC_OFFSET
3215 added getsid(), setsid(), send() to sycls
3216 procan prints sid (session id)
3217 mail.sh gets -f (from) option
3218 new EXAMPLEs for file creation
3219 gatherinfo.sh now tells about failures
3220 test.sh can check for much more address/option combinations
3221
3222 porting:
3223 ispeed, ospeed for termios on FreeBSD
3224 getpgid() conditional for MacOS 10
3225 added ranlib in Makefile.in for MacOS 10
3226 disable pty option if no pty mechanism is available (MacOS 10)
3227 now compiles and runs on MacOS 10 (still some tests fail)
3228 setgroups() conditional for cygwin
3229 sighandler_t defined conditionally
3230 use gcc option -D_GNU_SOURCE