1
0
mirror of https://github.com/unrealircd/unrealircd.git synced 2026-06-12 17:14:46 +02:00
Commit Graph

73 Commits

Author SHA1 Message Date
Bram Matthys d73c8b30d2 Fix compile problem with central-blocklist on FreeBSD. 2023-11-24 09:13:13 +01:00
Bram Matthys 98c0e786b5 Make UnrealIRCd compile on Windows again.
Updated the makefile to build unrealircdctl.exe etc.
2022-01-03 13:10:53 +01:00
Bram Matthys dbef19cd7a Add initial implementation of UNIX domain sockets (listen::file).
Various things still need to be done: a lot more testing, ability to
set permissions on the file, #ifdef's because of lack of support
on Windows (currently won't compile), etc.

One thing that I don't intend to change is that I chose not to display
the socket in the host but have clients show up as 'localhost' (and
ip '127.0.0.1'). Doing it this way keeps things easy, otherwise we risk
a lot of breakage for nearly nothing gained, really.

Things can be tested via:
listen {
        file "/tmp/listen";
}

and then with netcat:
nc -U /tmp/listen
USER x x x x
NICK hai
etc...
2022-01-01 18:48:17 +01:00
Bram Matthys 7ad7b36312 Remove useless ifdef, this was never reached. 2021-08-10 09:09:21 +02:00
Bram Matthys 8783280a68 Make UnrealDB big-endian-proof. Rather rare, but you never know
on what hardware people end up running UnrealIRCd.

Also (unrelated) add a check for >64kb strings in unrealdb_write_str()
and return an API error. That too is unlikely to ever happen, but..
better be correct.
2021-05-05 19:04:11 +02:00
Bram Matthys d8af0c170b sys/resource.h must be included earlier, otherwise ulimit (the fd limit)
is left unchanged at 1024.
2019-12-14 05:23:10 +01:00
Bram Matthys dfa83aa6e5 Add module manager. See https://www.unrealircd.org/docs/Module_manager
Also update release notes and some unrelated changes.
BIG commits. Lots of work. Requires more testing.
2019-11-01 12:57:12 +01:00
Bram Matthys 599f83cbd4 Move some #define's out of the way, some re-indenting, .. 2019-10-25 09:47:52 +02:00
Bram Matthys 5e4c481d93 Yes, strcasecmp is always available, configure. 2019-09-09 16:30:02 +02:00
Bram Matthys 1183e88077 Remove old SunOS / Solaris / AIX code.
And some other outdated things for non-POSIX systems...
2019-09-09 15:46:19 +02:00
Bram Matthys 8d453ffc40 Get rid of index() and some useless casts 2019-09-09 14:54:49 +02:00
Bram Matthys d434cf948b Get rid of bcmp/bcopy/bzero. 2019-09-09 14:41:40 +02:00
Bram Matthys 2276185939 Get rid of more ./configure checks.
(Let's see if Windows complains again...)
2019-09-09 13:56:37 +02:00
Bram Matthys c423f9c8f7 Remove some more ./configure checks that are likely unneeded. 2019-09-08 20:22:45 +02:00
Bram Matthys 8484511296 Make Windows build compile without warnings with /W3
Disable these warnings, though:
C4267: downgrade of size_t to int and such. pointless...
C4101: unreferenced local variable
C4018: signed/unsigned mismatch
C4244: implicit conversions with "possible loss of data".
       there are 75+ of them and they are likely all harmless
       and/or intentional (usually plain obvious too)
C4996: fixme! warnings about deprecated functions, currently only for GetVersion..
2019-08-25 13:00:31 +02:00
Bram Matthys 85b3b91b19 Windows build: Add format string verification during build.
(Will be used to hunt and fix those time_t integer type mismatches)
2019-08-24 17:10:44 +02:00
Bram Matthys 8c70769bef Windows: Use W7 API (or later) so we have inet_pton/inet_ntop. 2019-08-22 18:01:59 +02:00
Bram Matthys 8007a83020 Get rid of include/inet.h and use system headers properly. 2019-08-22 17:48:39 +02:00
Bram Matthys ded4a65a60 u_int16_t -> uint16_t and u_int32_t -> uint32_t, remove typedefs for
these types and others, that should no longer be needed thanks to
stdint.h.
2019-06-26 17:06:46 +02:00
Bram Matthys c507db9005 Get rid of Windows compile warning regarding abort(). 2019-06-23 08:57:39 +02:00
Bram Matthys a9a94652ec Be consistent when setting WINVER. This fixes a compile issue
with Visual Studio 2017.
2017-10-22 16:23:52 +02:00
Bram Matthys a886c1ebc6 Check for and include sys/wait.h. Fixes compile problem on OpenBSD (#4663). 2016-04-23 09:55:58 +02:00
Bram Matthys 2eda1cb285 Windows... 2016-04-03 20:13:58 +02:00
Bram Matthys 14aca6bcde Remove unused alloca stuff. Fix windows warnings. 2015-07-29 12:30:40 +02:00
Bram Matthys ae23d99e07 Get rid of #if INET6 stuff, as all supported OS's support IPv6 at compile time. Use set::options::disable-ipv6 to disable IPv6 at runtime. Cleanup unused IPv6 structs/vars/functions/.. 2015-07-29 10:31:12 +02:00
Bram Matthys 3b217f083a Make IPv6 work on Windows 2015-07-29 09:50:36 +02:00
Bram Matthys fa87577918 and some more. 2015-07-28 22:14:58 +02:00
Bram Matthys 034d2b239d fixed typo preventing a compile, reported by rfrederick (#4245). 2013-11-24 20:22:56 +01:00
Bram Matthys 559bdcbc48 Fix for OS X so it can actually compile. Reported by QIXOZL (#4236). 2013-11-24 11:30:18 +01:00
Bram Matthys 101d2dd6a3 Big 3.4.x commit containing bug fixes and enhancements. Modularizing
user & channel modes. Fixing Windows build. Etc..
2014-05-11 20:56:02 +02:00
William Pitcock afdf5d780a - Replace ircsprintf() with bounds-checking ircsnprintf(), patch from FalconKirtaran. (#4208) 2013-05-21 06:26:52 +00:00
binki 9f710925f8 - Fix missing #include <stdint.h>. Fixes compile error on OpenBSD
reported by CuleX (#3977).
2010-12-21 04:53:05 +00:00
Bram Matthys 1309531df8 forgot to remove an #ifndef 2010-12-12 16:37:34 +00:00
Bram Matthys 58260b3917 Major win32 build system cleanup:
- Win32: Attempt to move to 100% winsock2 (the include, to be precise),
  this means includes have to be in a very particular order (!)
- Win32: #define _WIN32_WINNT 0x0501 and force our own inet_ntop/pton,
  otherwise you get an ntop runtime error on XP and earlier.
- Win32: Get rid of c-ares includes and library in our tree, and use the
  DLL instead of static LIB, just like we do for ssl and zlib.
- Win32: Get rid of TRE lib and includes
- Win32: reorder includes to fix winsock errors with curl
2010-12-12 16:32:55 +00:00
binki a744b9b212 - Don't use sys/errno.h, as it's not POSIX and breaks on QNX-6.5.0. (#3955) 2010-09-07 15:39:47 +00:00
binki 06e807130c - Added error message for unknown directives in the "files" block
- Remote MOTD support. Not adequately tested. Required restructuring of the asynchronous download callback and handler.
- Added some consts throughout url.c, etc.
- Fix segfault where the an include directive specifies a URL and cURL follows redirects, resulting in a different resultant URL. The remote includes code would look for the an include block using the resultant URL and assume that it would be found. The new code searches differently, has new checks, and ignores the resultant URL.
- Removed duplicated m_motd() and friends that were both in modules and s_serv.c. The copies in s_serv.c (core) were overriding the in-module functions.
2010-06-16 05:44:15 +00:00
Bram Matthys d10223fc2e - The OS version output is now taken from uname() at runtime instead of
'uname -a' at compile time. This fixes bug #1438 and #3320 reported by
  Mouse and Monk, where because of previous behavior the IRCd sometimes
  would not compile in certain environments.
2008-08-09 14:56:34 +00:00
Bram Matthys 62af4dd7a0 - Fixed Mac OS X issue where "access denied" errors were encountered when
trying to read unrealircd.conf. All due to strange chmod() behavior. We now no
  longer try to set permissions on Mac OS X. Patch provided by Tibby (#3489).
2007-09-25 15:23:27 +00:00
Bram Matthys 3b84610599 - IPv6: Added configure check for in6addr_any to fix Fedora Core 4 compile problem,
reported by wheatie80 (#2594).
2005-07-25 21:11:27 +00:00
codemastr b9a516d664 Hopefully fixed the last of the alloca warnings 2005-01-17 20:41:27 +00:00
Bram Matthys 4a6f784e37 - Got rid of wma/wmv in dccallow.conf, better to require an explicit select here due to
recent DRM exploits (spyware etc).
- Fixed /restart reasons, reported by SouL-FoRTuNe.
- Partial (incomplete!) fix for alloca warnings during compile (especially w/SSL).
2005-01-05 01:44:42 +00:00
codemastr 191127296a Rewrote some of the previous change to deal with some strange issues 2004-11-26 22:14:30 +00:00
codemastr e5f16b777a Made the win32 version use a dynamically linked libc 2004-05-30 00:59:05 +00:00
codemastr c1af4a4516 Added NICKIP 2004-05-27 22:05:58 +00:00
Bram Matthys 7c4418113b - Changed random number generator to use arc4random-alike routines so we can get "secure"
random numbers. We will also no longer be using rand()/random() anywhere.
  Thanks to dek\ for pointing out this is potentionally dangerous, especially on
  win32 with NOSPOOF enabled.
2004-01-19 19:49:28 +00:00
codemastr 084d57cef1 Updated TRE dll and fixed a MAX_PATH problem 2003-12-23 01:47:02 +00:00
Bram Matthys c25223913c - (Internal) Added __attribute__ format checking for most format string functions,
this will currently produce a lot of warnings with -Wall.
- Fixed 159 of 184 warnings detected by the above, the other warnings are false.
  Most warnings had to do with long vs int, and thus the format strings (%d->%ld)
  or the vars (int->long) have been changed (many of these were time_t/TS vs int).
  Only a few rare crashbugs were discovered.
- Module coders: for HOOKTYPE_LOCAL_CHANMODE the 'sendts' parameter was changed
  from type 'int' to 'time_t', while in most circumstances (like on ia32)
  you won't notice, I suggest you to update your callback functions anyway.
- Possibly fixed an issue with set::modes-on-join and mode +f, it could have
  set random remove-chanmode times in the default chanmode line.
2003-11-02 02:58:11 +00:00
codemastr a450522052 *nix resolver for Windows 2003-08-21 16:11:08 +00:00
Bram Matthys 95c0add864 Fix for error msgs flood at (at least) Linux 2.4.x and FreeBSD caused by
socket already disconnected when getpeername() is done.
2003-01-28 22:14:56 +00:00
Bram Matthys 1e51112790 Fixed win32 compile error because of report_error patch (oops, lalala :P).
Added P_ECONNABORTED and P_ECONNRESET.
2003-01-20 19:33:18 +00:00