]> PatchyGit - patchyircd.git/log
patchyircd.git
2 years agoalways compile admin.[ch]
Egor [Wed, 31 Jan 2024 19:08:33 +0000 (21:08 +0200)]
always compile admin.[ch]

this makes it easier to do windows builds

2 years agopasswd.c: fix compilation on windows
Egor [Wed, 31 Jan 2024 19:07:48 +0000 (21:07 +0200)]
passwd.c: fix compilation on windows

2 years agoFD_CLOEXEC everything
Egor [Wed, 31 Jan 2024 18:53:39 +0000 (20:53 +0200)]
FD_CLOEXEC everything

_GNU_SOURCE is needed for socket4

2 years agofix localhost/hidden service detection
Egor [Wed, 31 Jan 2024 11:52:12 +0000 (13:52 +0200)]
fix localhost/hidden service detection

tbh hidden service should be probably done via AF_UNIX

2 years agoadd lua/local.lua to gitignore
Egor [Fri, 26 Jan 2024 15:48:23 +0000 (17:48 +0200)]
add lua/local.lua to gitignore

2 years agoapply a different hostname on 127.0.0.2
Egor [Fri, 26 Jan 2024 15:13:37 +0000 (17:13 +0200)]
apply a different hostname on 127.0.0.2

for the people who connect to the hidden service

2 years agouse luaL_setfuncs to register globals
Egor [Fri, 26 Jan 2024 14:04:04 +0000 (16:04 +0200)]
use luaL_setfuncs to register globals

2 years agoexpose channel creation/MODE/TOPIC in lua
Egor [Fri, 26 Jan 2024 13:03:33 +0000 (15:03 +0200)]
expose channel creation/MODE/TOPIC in lua

2 years agomake it possible to use channel_mode without client
Egor [Fri, 26 Jan 2024 12:00:10 +0000 (14:00 +0200)]
make it possible to use channel_mode without client

2 years agomove channel MODE setting into a separate func
Egor [Fri, 26 Jan 2024 11:33:56 +0000 (13:33 +0200)]
move channel MODE setting into a separate func

2 years agoload lua/local.lua if it exists
Egor [Fri, 26 Jan 2024 10:56:24 +0000 (12:56 +0200)]
load lua/local.lua if it exists

2 years agoLIST: show all channels to ircops
Egor [Fri, 26 Jan 2024 10:34:13 +0000 (12:34 +0200)]
LIST: show all channels to ircops

2 years agoallow AUTHENTICATE after registration
Egor [Thu, 25 Jan 2024 11:32:07 +0000 (13:32 +0200)]
allow AUTHENTICATE after registration

why are so many clients so stupid?

also don't leak the saslbuf

2 years agoirccloud.lua: read from text database
Egor [Thu, 25 Jan 2024 04:02:34 +0000 (06:02 +0200)]
irccloud.lua: read from text database

2 years agorun all username updates through chghost
Egor [Thu, 25 Jan 2024 03:50:16 +0000 (05:50 +0200)]
run all username updates through chghost

2 years agodon't allow deauthing with USER command
Egor [Thu, 25 Jan 2024 03:01:37 +0000 (05:01 +0200)]
don't allow deauthing with USER command

2 years agoremove outdated comment
Egor [Thu, 25 Jan 2024 02:56:48 +0000 (04:56 +0200)]
remove outdated comment

2 years agoabort SASL on registration
Egor [Thu, 25 Jan 2024 02:55:37 +0000 (04:55 +0200)]
abort SASL on registration

From the spec:
If the client completes registration (with CAP END, NICK, USER and any
other necessary messages) while the SASL authentication is still in
progress, the server SHOULD abort it and send a 906 numeric, then
register the client without authentication.

2 years agoadd extra nick reservations
Egor [Thu, 25 Jan 2024 02:42:22 +0000 (04:42 +0200)]
add extra nick reservations

2 years agoadmin.c: add comments regarding sasl variables
Egor [Thu, 25 Jan 2024 02:31:31 +0000 (04:31 +0200)]
admin.c: add comments regarding sasl variables

2 years agomove server logging to sendbuf
Egor [Thu, 25 Jan 2024 02:29:54 +0000 (04:29 +0200)]
move server logging to sendbuf

2 years agoadd SASL EXTERNAL support
Egor [Thu, 25 Jan 2024 02:22:32 +0000 (04:22 +0200)]
add SASL EXTERNAL support

2 years agouse unsigned char instead of uint8_t
Sam Smith [Thu, 25 Jan 2024 01:54:56 +0000 (03:54 +0200)]
use unsigned char instead of uint8_t

2 years agoannounce SASL mechanisms when using CAP 302
Egor [Thu, 25 Jan 2024 01:46:23 +0000 (03:46 +0200)]
announce SASL mechanisms when using CAP 302

2 years agosend msg_join_extended during chghost fallback
Egor [Thu, 25 Jan 2024 01:45:25 +0000 (03:45 +0200)]
send msg_join_extended during chghost fallback

2 years agodon't log AUTHENTICATE
Egor [Wed, 24 Jan 2024 07:20:17 +0000 (09:20 +0200)]
don't log AUTHENTICATE

2 years agoadd SASL auth support
Egor [Wed, 24 Jan 2024 07:15:51 +0000 (09:15 +0200)]
add SASL auth support

2 years agoirccloud.lua: minor fixes
Egor [Wed, 24 Jan 2024 07:06:43 +0000 (09:06 +0200)]
irccloud.lua: minor fixes

2 years agoadd all the caps to CAP LS
Egor [Wed, 24 Jan 2024 03:02:47 +0000 (05:02 +0200)]
add all the caps to CAP LS

2 years agomove all of ctcp probing into ctcp.lua
Egor [Tue, 23 Jan 2024 11:51:13 +0000 (13:51 +0200)]
move all of ctcp probing into ctcp.lua

2 years agoadd associated lua data for clients
Egor [Tue, 23 Jan 2024 11:14:19 +0000 (13:14 +0200)]
add associated lua data for clients

2 years agomove spam filtering to a separate module
Egor [Tue, 23 Jan 2024 10:50:25 +0000 (12:50 +0200)]
move spam filtering to a separate module

2 years agomove ctcp probing to a separate module
Egor [Tue, 23 Jan 2024 10:48:56 +0000 (12:48 +0200)]
move ctcp probing to a separate module

2 years agoadd irccloud authentication lua script
Egor [Tue, 23 Jan 2024 10:38:25 +0000 (12:38 +0200)]
add irccloud authentication lua script

2 years agoallow running only half of refreshctcp
Egor [Tue, 23 Jan 2024 08:25:10 +0000 (10:25 +0200)]
allow running only half of refreshctcp

2 years agofix refreshctcp command
Egor [Tue, 23 Jan 2024 05:08:47 +0000 (07:08 +0200)]
fix refreshctcp command

2 years agoadd lua refreshctcp command
Egor [Tue, 23 Jan 2024 05:02:34 +0000 (07:02 +0200)]
add lua refreshctcp command

2 years agoadd lua summon command
Egor [Tue, 23 Jan 2024 04:41:49 +0000 (06:41 +0200)]
add lua summon command

2 years agoadd mask support to the WHO command
Egor [Tue, 23 Jan 2024 04:22:25 +0000 (06:22 +0200)]
add mask support to the WHO command

2 years agoadd ctcp time logging
Egor [Tue, 23 Jan 2024 03:21:16 +0000 (05:21 +0200)]
add ctcp time logging

2 years agomove the password rejection later down the line
Egor [Tue, 23 Jan 2024 02:19:13 +0000 (04:19 +0200)]
move the password rejection later down the line

2 years agoadd ctcp logging
Egor [Tue, 23 Jan 2024 01:59:33 +0000 (03:59 +0200)]
add ctcp logging

2 years agominor adjustments to rpl_localusers/rpl_globalusers
Egor [Tue, 23 Jan 2024 01:19:51 +0000 (03:19 +0200)]
minor adjustments to rpl_localusers/rpl_globalusers

2 years agoupdate client->nuh on chghost
Egor [Fri, 27 Oct 2023 21:27:49 +0000 (00:27 +0300)]
update client->nuh on chghost

2 years agoadd RPL_VISIBLEHOST
Egor [Fri, 27 Oct 2023 21:27:09 +0000 (00:27 +0300)]
add RPL_VISIBLEHOST

2 years agoecho CHGHOST, SETNAME, ACCOUNT
Egor [Fri, 27 Oct 2023 21:19:33 +0000 (00:19 +0300)]
echo CHGHOST, SETNAME, ACCOUNT

2 years agolua: make globals global
Egor [Fri, 27 Oct 2023 21:12:29 +0000 (00:12 +0300)]
lua: make globals global

2 years agoadd chghost, setname, account-notify
Egor [Fri, 27 Oct 2023 20:59:10 +0000 (23:59 +0300)]
add chghost, setname, account-notify

2 years agoadd MONITOR limit
Egor [Fri, 27 Oct 2023 20:19:25 +0000 (23:19 +0300)]
add MONITOR limit

2 years agoadd MONITOR and extended-monitor
Egor [Fri, 27 Oct 2023 20:14:20 +0000 (23:14 +0300)]
add MONITOR and extended-monitor

2 years agoadd WHOX support
Egor [Fri, 27 Oct 2023 16:31:10 +0000 (19:31 +0300)]
add WHOX support

2 years agorpl_whoreply: move bot flag to the end
Egor [Fri, 27 Oct 2023 16:02:56 +0000 (19:02 +0300)]
rpl_whoreply: move bot flag to the end

2 years agoadd lua scripting
Egor [Fri, 27 Oct 2023 15:43:57 +0000 (18:43 +0300)]
add lua scripting

2 years agomark localhost connections as secure
Egor [Wed, 25 Oct 2023 10:28:17 +0000 (13:28 +0300)]
mark localhost connections as secure

3 years agomake USE_MAP_DYNARR configurable
Egor [Mon, 23 Oct 2023 10:08:34 +0000 (13:08 +0300)]
make USE_MAP_DYNARR configurable

3 years agothe great findfirst refactoring
Egor [Mon, 23 Oct 2023 09:58:31 +0000 (12:58 +0300)]
the great findfirst refactoring

not only is the syntax markedly better now, but also it's no longer
nescessary to allocate any memory to do a traversal.

3 years agotrie_findfirst: fix subtle bug with struct reusal
Egor [Sun, 22 Oct 2023 21:36:37 +0000 (00:36 +0300)]
trie_findfirst: fix subtle bug with struct reusal

3 years agotrie_find: underscore the internal fields
Egor [Sun, 22 Oct 2023 21:36:00 +0000 (00:36 +0300)]
trie_find: underscore the internal fields

3 years agotrie: limit key size
Egor [Sun, 22 Oct 2023 21:34:09 +0000 (00:34 +0300)]
trie: limit key size

3 years agodocument map traversal funcs
Egor [Sun, 22 Oct 2023 21:18:36 +0000 (00:18 +0300)]
document map traversal funcs

3 years agothe great trie_find renaming
Egor [Sun, 22 Oct 2023 20:52:19 +0000 (23:52 +0300)]
the great trie_find renaming

3 years agosimplify map_dynarr traversal
Egor [Sun, 22 Oct 2023 20:37:00 +0000 (23:37 +0300)]
simplify map_dynarr traversal

i've checked that we indeed do not rely on modification during traversal

3 years agomap: change f->n->value to f->value
Egor [Sun, 22 Oct 2023 20:15:18 +0000 (23:15 +0300)]
map: change f->n->value to f->value

3 years agocombine trie.h and map_dynarr.h into map.h
Egor [Sun, 22 Oct 2023 20:04:17 +0000 (23:04 +0300)]
combine trie.h and map_dynarr.h into map.h

3 years agorename trie_{get,set,unset,free} to map_*
Egor [Sun, 22 Oct 2023 18:11:56 +0000 (21:11 +0300)]
rename trie_{get,set,unset,free} to map_*

3 years agotrie_set: always check the error
Egor [Sun, 22 Oct 2023 18:08:23 +0000 (21:08 +0300)]
trie_set: always check the error

and guarantee that no errors can occur on unset

3 years agoadd alternative map impl, fix some memory leaks
Egor [Sun, 22 Oct 2023 15:46:21 +0000 (18:46 +0300)]
add alternative map impl, fix some memory leaks

3 years agoimprove mod message support
Egor [Sun, 22 Oct 2023 13:43:11 +0000 (16:43 +0300)]
improve mod message support

3 years agonetpoll: small tweak to binary search func
Egor [Sun, 22 Oct 2023 13:03:39 +0000 (16:03 +0300)]
netpoll: small tweak to binary search func

3 years agonetpoll: optimize epoll implementation
Egor [Sat, 21 Oct 2023 17:01:49 +0000 (20:01 +0300)]
netpoll: optimize epoll implementation

3 years agonetpoll: add epoll implementation
Egor [Sat, 21 Oct 2023 16:15:26 +0000 (19:15 +0300)]
netpoll: add epoll implementation

3 years agonetpoll: add poll implementation
Egor [Sat, 21 Oct 2023 15:49:27 +0000 (18:49 +0300)]
netpoll: add poll implementation

3 years agoadd event loop abstraction
Egor [Sat, 21 Oct 2023 15:25:30 +0000 (18:25 +0300)]
add event loop abstraction

3 years agouse SA_RESTART for SIGINT
Egor [Sat, 21 Oct 2023 11:23:56 +0000 (14:23 +0300)]
use SA_RESTART for SIGINT

SA_RESTART specifically doesn't affect polling syscalls (the thing we
want to interrupt), but it prevents stupid things like having to check
for EINTR on recv/send (which we weren't doing anyway)

3 years agohandle write errors and connection closes more gracefully
Egor [Sat, 21 Oct 2023 11:19:02 +0000 (14:19 +0300)]
handle write errors and connection closes more gracefully

3 years agonet_cleanup after closing the listeners
Egor [Sat, 21 Oct 2023 09:11:26 +0000 (12:11 +0300)]
net_cleanup after closing the listeners

3 years agofix crash with NULL peername
Egor [Thu, 19 Oct 2023 14:27:36 +0000 (17:27 +0300)]
fix crash with NULL peername

3 years agokillConnection: never block
Egor [Thu, 19 Oct 2023 13:59:50 +0000 (16:59 +0300)]
killConnection: never block

3 years agomove data files to data directory
Egor [Thu, 19 Oct 2023 13:31:44 +0000 (16:31 +0300)]
move data files to data directory

mv cert.pem chanlog.txt help.txt init.txt key.pem motd.txt \
    newusers.txt ops.txt users.txt data

3 years agoadd motd.txt support
Egor [Thu, 19 Oct 2023 13:10:42 +0000 (16:10 +0300)]
add motd.txt support

3 years agoreadme documentation
Egor [Thu, 19 Oct 2023 12:57:24 +0000 (15:57 +0300)]
readme documentation

3 years agomove sources to src/
Egor [Thu, 19 Oct 2023 11:21:55 +0000 (14:21 +0300)]
move sources to src/

3 years agoMakefile: explicitly name all source files
Egor [Thu, 19 Oct 2023 11:17:06 +0000 (14:17 +0300)]
Makefile: explicitly name all source files

3 years agomove irc_glob to util.c
Egor [Thu, 19 Oct 2023 11:10:20 +0000 (14:10 +0300)]
move irc_glob to util.c

3 years agofix header guards
Egor [Thu, 19 Oct 2023 11:05:38 +0000 (14:05 +0300)]
fix header guards

3 years agomove netsock into root dir
Egor [Thu, 19 Oct 2023 11:04:41 +0000 (14:04 +0300)]
move netsock into root dir

3 years agoremove networking-tests
Egor [Thu, 19 Oct 2023 11:01:37 +0000 (14:01 +0300)]
remove networking-tests

3 years agorewrite netsock
Egor [Thu, 19 Oct 2023 10:56:46 +0000 (13:56 +0300)]
rewrite netsock

3 years agomake irc hostname configurable
Egor [Thu, 19 Oct 2023 09:20:23 +0000 (12:20 +0300)]
make irc hostname configurable

3 years agogive a different hostname for localhost connections
Egor [Thu, 19 Oct 2023 09:15:34 +0000 (12:15 +0300)]
give a different hostname for localhost connections

3 years agouse unsigned for bitfield
Egor [Wed, 18 Oct 2023 20:45:56 +0000 (23:45 +0300)]
use unsigned for bitfield

3 years agoget rid of stdbool.h
Egor [Wed, 18 Oct 2023 20:21:05 +0000 (23:21 +0300)]
get rid of stdbool.h

3 years agoclean up allocClient
Egor [Wed, 18 Oct 2023 20:19:26 +0000 (23:19 +0300)]
clean up allocClient

3 years agouse sigaction to set handler for SIGPIPE
Egor [Wed, 18 Oct 2023 20:08:20 +0000 (23:08 +0300)]
use sigaction to set handler for SIGPIPE

3 years agosendClient: never block
Egor [Wed, 18 Oct 2023 20:00:17 +0000 (23:00 +0300)]
sendClient: never block

3 years agorecvProc: never block
Egor [Wed, 18 Oct 2023 18:55:29 +0000 (21:55 +0300)]
recvProc: never block

3 years agonet: add proper blocking for non-tls
Egor [Wed, 27 Sep 2023 23:04:46 +0000 (02:04 +0300)]
net: add proper blocking for non-tls

3 years agoantispam 2
Egor [Wed, 5 Jul 2023 09:31:50 +0000 (12:31 +0300)]
antispam 2

3 years agoantispam
Egor [Tue, 4 Jul 2023 19:59:23 +0000 (22:59 +0300)]
antispam

3 years agotls: add proper blocking with select/poll
Egor [Fri, 19 May 2023 21:29:05 +0000 (00:29 +0300)]
tls: add proper blocking with select/poll