This should be a hard assertion, but it's a soft assertion because that was getting triggered and leading to aborts. However, it shouldn't be asserting at all, so this needs to be fixed. Even if it's not aborting now, it still results in a disconnect of the entire IMAP session.
[2024-04-26 08:40:50.127] DEBUG[3527962]: net_imap.c:4675 handle_client: 0x7f414effa5d0 => 322 STATUS "REDACTED" (UNSEEN MESSAGES RECENT SIZE)
[2024-04-26 08:40:50.127] DEBUG[3527962]: imap_client.c:828 __load_virtual_mailbox: Reusing existing active connection for REDACTED
[2024-04-26 08:40:50.127] DEBUG[3527962]: imap_server_maildir.c:255 set_maildir_readonly: Mailbox 'REDACTED' has a virtual mapping
[2024-04-26 08:40:50.127] ERROR[3527962]: imap_client_status.c:525 remote_status: Remote IMAP client does not have an associated IMAP session???
[2024-04-26 08:40:50.127] ERROR[3527962]: imap_client_status.c:526 remote_status: Failed soft assertion 0
[2024-04-26 08:40:50.127] ERROR[3527962]: backtrace.c:263 bbs_log_backtrace: Got 10 backtrace records
[2024-04-26 08:40:50.424] ERROR[3527962]: backtrace.c:287 bbs_log_backtrace: 0: lbbs bbs_log_backtrace()
[2024-04-26 08:40:50.424] ERROR[3527962]: backtrace.c:287 bbs_log_backtrace: 1: [0x7f4190dc5b60] net_imap.so imap_client_status.c:527 remote_status()
[2024-04-26 08:40:50.424] ERROR[3527962]: backtrace.c:287 bbs_log_backtrace: 2: [0x7f4190dde756] net_imap.so net_imap.c:1243 handle_remote_status()
[2024-04-26 08:40:50.425] ERROR[3527962]: backtrace.c:287 bbs_log_backtrace: 3: [0x7f4190de9376] net_imap.so net_imap.c:1512 handle_status()
[2024-04-26 08:40:50.425] ERROR[3527962]: backtrace.c:287 bbs_log_backtrace: 4: [0x7f4190df05b2] net_imap.so net_imap.c:4257 imap_process()
[2024-04-26 08:40:50.425] ERROR[3527962]: backtrace.c:283 bbs_log_backtrace: 5: [0x7f4190df5b16] net_imap.so net_imap.c:4677 handle_client()
[2024-04-26 08:40:50.425] ERROR[3527962]: backtrace.c:283 bbs_log_backtrace: 5: [ inlined] net_imap.so net_imap.c:4710 imap_handler()
[2024-04-26 08:40:50.425] ERROR[3527962]: backtrace.c:287 bbs_log_backtrace: 6: [0x7f4190df61b4] net_imap.so net_imap.c:4735 __imap_handler()
[2024-04-26 08:40:50.425] ERROR[3527962]: backtrace.c:287 bbs_log_backtrace: 7: lbbs <unknown>()
[2024-04-26 08:40:50.425] ERROR[3527962]: backtrace.c:287 bbs_log_backtrace: 8: [0x7f4195df8044] libc.so.6 pthread_create.c:442 start_thread()
[2024-04-26 08:40:50.425] ERROR[3527962]: backtrace.c:287 bbs_log_backtrace: 9: [0x7f4195e7861c] libc.so.6 clone3.S:83 clone3()
[2024-04-26 08:40:50.425] DEBUG[3527962]: net_imap.c:4625 imap_process: STATUS command returned -1
[2024-04-26 08:40:50.425] DEBUG[3527962]: mod_mail.c:228 mailbox_dispatch_event: Dispatching mailbox event 'Logout'
Possibly related?
Thread 1 (Thread 0x7f8395ffb6c0 (LWP 1120694)):
#0 0x00007f83d27c1e9b in __imap_client_send_wait_response (client=0x7f83d801d900, fd=fd@entry=-1, ms=ms@entry=5000, echo=echo@entry=1, lineno=<optimized out>, cb=0x0, cbdata=<optimized out>, f>
buf = 0xffffffffffffff10 <error: Cannot access memory at address 0xffffffffffffff10>
len = <optimized out>
res = -1
tagbuf = "\000\000\000\000\000\000\000\027\000\000\000\000\000\000"
taglen = <optimized out>
ap = {{gp_offset = 3816488351, fp_offset = 32643, overflow_arg_area = 0x17, reg_save_area = 0x7f83e37c7693 <__strcspn_generic+387>}}
tag = 0x7f83d27ef09f "tag"
__func__ = "__imap_client_send_wait_response"
#1 0x00007f83d27eadbb in imap_process (imap=imap@entry=0x7f8395ff86b0, s=<optimized out>, s@entry=0x7f8395ff8b40 "32") at net_imap.c:4536
You must be
10/13/2024 12:25 PM — InterLinked
Autoresolved by code commit on GitHub:
net_imap: Prevent invalid memory accesses due to stale pointer.
https://github.com/InterLinked1/lbbs/commit/d86994c4e00a03dd22b096b7a2bab2d7346a5f33