Matthias Ahouansou
c48535ef32
fix: avoid panics when admin room is not available
...
Co-authored-by: strawberry <strawberry@puppygock.gay>
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-19 00:17:41 -04:00
strawberry
5473631e1d
admin command to see a room's full state from our database
...
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-19 00:17:41 -04:00
strawberry
935f83af98
dont allow GetRemotePdu server to be ourselves
...
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-16 00:09:48 -04:00
strawberry
0bed5ca506
remove unnecessary variable qualifications
...
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-16 00:09:48 -04:00
strawberry
0ac2092888
check if federation is enabled in GetRemotePdu
...
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-16 00:09:48 -04:00
strawberry
f1507a4522
handle GetRemotePdu response as backfilled PDU
...
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-16 00:09:48 -04:00
strawberry
9dc4290438
split GetPdu and GetRemotePdu, handle response as incoming PDU
...
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-16 00:09:48 -04:00
Charles Hall
3160a36634
refactor clap into a separate file
...
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-16 00:09:48 -04:00
strawberry
7d825690f7
admin cmd to fetch PDU from remote server
...
does not append to timeline/database yet
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-16 00:09:48 -04:00
strawberry
496a9c7af8
resolve some pedantic lints, reduce some allocations
...
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-08 12:51:21 -05:00
Matthias Ahouansou
5ab76a1332
update ruma appservice Registration type MR
...
from https://gitlab.com/famedly/conduit/-/merge_requests/583
and fixed panic from blocking async call in timeline/mod.rs
Co-authored-by: strawberry <strawberry@puppygock.gay>
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-08 12:51:21 -05:00
strawberry
7c1624931d
remove various unnecessary qualifications
...
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-08 12:51:21 -05:00
Matthias Ahouansou
4ec2d3ecb5
refactor: use async-aware RwLocks and Mutexes where possible
...
squashed from https://gitlab.com/famedly/conduit/-/merge_requests/595
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-08 12:51:21 -05:00
strawberry
f419c64aca
add rustfmt.toml, format entire codebase
...
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-08 12:51:21 -05:00
strawberry
34e8fd38cf
extend room banning to local+remote room invites
...
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-03 22:20:37 -05:00
strawberry
e2c7afe69c
go through a ton of pedantic clippy lints
...
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-03 22:20:37 -05:00
strawberry
04d16ac544
remove two unnecessary string heap allocs
...
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-03 22:20:37 -05:00
strawberry
cde6fdd741
resolve or_fun_call clippy lint
...
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-03 22:20:37 -05:00
strawberry
93cc98a04c
fix cargo doc lint
...
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-03 22:20:37 -05:00
strawberry
27f61a2dee
add missing comment slash
...
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-03 22:20:37 -05:00
strawberry
ee548bd2e7
admin command to delete all remote media within the past x time
...
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-03 22:20:37 -05:00
strawberry
abf41f4c79
check if specified user belongs to us
...
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-02-28 13:56:19 -05:00
strawberry
ee4f0a0ae5
admin cmd to list all rooms a user is in
...
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-02-28 13:56:19 -05:00
strawberry
f76937a085
fix incorrect repo link on welcome msg
...
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-02-26 00:40:15 -05:00
strawberry
24625e9659
resolve nightly rust warnings
...
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-02-26 00:40:15 -05:00
strawberry
cdc644946d
admin cmd to delete MXCs via event_id
...
this can be used as a way to deal with the thumbnail
and the media file at the same time without knowing
the thumbnail MXC URL.
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-02-26 00:40:15 -05:00
strawberry
50fb202382
admin cmd to delete multiple MXC URLs in bulk
...
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-02-26 00:40:15 -05:00
strawberry
4d624846ee
admin command to delete media via MXC url
...
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-02-24 13:04:13 -05:00
strawberry
1ecad225be
feat: custom text for user displayname suffix upon registration
...
replaces the lightning bolt emoji option with support for
your own text or emojis
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-02-24 13:04:13 -05:00
strawberry
03d796e95e
support room aliases for room blocking, argument to disable federation
...
and makes parsing the room more generic (room ID or room alias)
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-02-20 07:06:57 -05:00
strawberry
bdda875416
bump conduwuit version to 0.1.3
...
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-02-20 07:06:57 -05:00
strawberry
9a6a77974b
add support for bulk banning room IDs
...
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-02-20 07:06:57 -05:00
strawberry
e25d574208
move room moderation stuff to a subcommand
...
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-02-20 07:06:57 -05:00
strawberry
c9364dc077
dont evict admins from room, allow admins to join banned rooms
...
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-02-20 07:06:57 -05:00
strawberry
ed0c8e86f7
initial implementation of banning room IDs
...
takes a full room ID, evicts all our users from that room,
adds room ID to banned room IDs metadata db table, and
forbids any new local users from attempting to join it.
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-02-20 07:06:57 -05:00
strawberry
a2f7f6fda4
prefix every admin room help cmd with -
...
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-02-20 07:06:57 -05:00
Matthias Ahouansou
784d307425
revamp appservice registration to ruma's Registration type
...
squashed from https://gitlab.com/famedly/conduit/-/merge_requests/583
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-02-11 21:56:55 -05:00
strawberry
2f16726bac
raise generated passwords to 25 chars
...
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-01-14 20:55:56 -05:00
strawberry
149d22eef7
make set avatar, displayname, and blurhash async and forgot another let _
...
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-01-14 20:55:56 -05:00
strawberry
5c4b8ad7a3
replace panics on unknown room versions with errors
...
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-01-14 20:55:56 -05:00
strawberry
c70ce49ec0
don't allow non-local users to have their creds modified in Deactivate admin cmds
...
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-01-14 20:55:56 -05:00
strawberry
06e0360142
change welcome message
...
Signed-off-by: strawberry <strawberry@puppygock.gay>
2023-12-25 17:07:24 -05:00
Val Lorentz
33cae7eaab
Explicitly match RoomVersionId::V11
2023-12-25 11:09:19 -05:00
Charles Hall
311c7d83ca
fix rustdoc warnings
...
Also removed all instances of `#[command(verbatim_doc_comment)]` because
I'm pretty sure it's not necessary anymore. The `[commandbody]` things
were making rustdoc upset about broken link syntax. I also normalized
"code-block" to "code block" in that file since the latter appears more
often.
2023-12-20 21:46:54 -05:00
strawberry
f62f641545
add rocksdb configurable options and tweaks, logging improvements, exp. room v11 support
...
split out the spinning disk focused options into a configurable option, current
conduwuit users are NVMe/SSDs anyways so those options are just hindering performance.
rocksdb logging builds up overtime with no cleanup or anything, adds support for
configuring the amount of logging, size of files, log rotate, etc.
fixes https://gitlab.com/girlbossceo/conduwuit/-/issues/1
misc conduit logging improvements for help debugging issues and maybe a future feature
experimental Room V11 support from https://gitlab.com/famedly/conduit/-/merge_requests/562
Signed-off-by: strawberry <strawberry@puppygock.gay>
2023-12-02 21:30:06 -05:00
strawberry
56e4166ee8
never let clippy fail, use CARGO_PKG_NAME, allow issues on gh, simplify regex a tad
...
Signed-off-by: strawberry <strawberry@puppygock.gay>
2023-11-29 23:19:53 -05:00
strawberry
b06ed1b92f
remove # from internal room ID list
...
internal room IDs do not have #, they start with !
Signed-off-by: strawberry <june@girlboss.ceo>
2023-11-27 01:35:30 -05:00
strawberry
e2ec2a98ba
make rooms alias list command more nicer
...
room IDs in conduit have a server name attached to them already
outputting the server name again just makes it look incorrect
also add codeblock to the internal room ID portion
Signed-off-by: strawberry <june@girlboss.ceo>
2023-11-27 01:25:20 -05:00
strawberry
54a3f47851
fix every clippy warning possible, remove io_uring as default feature
...
this project's codebase is so horrendous, im shocked that no one has ran
clippy at all. it had ~200 total lint warnings, some with performance
issues and unsoundness, and the rest just very ugly codebase. i have sat
down and fixed as many of these as possible and i am exhausted.
i haven't fixed some extremely complex ones, but i brought it down from
~200 to ~30.
i have also removed io_uring as a default feature due to it falling
under the same category as linux eBPF: major kernel attack surface for
minimal performance gains. this also makes it impossible to cross-compile
from macOS to Linux because io_uring does not exist in Darwin land.
there are far better ways to achieve better performance than io_uring on
the codebase level.
Signed-off-by: strawberry <june@girlboss.ceo>
2023-11-27 00:50:55 -05:00
tezlm
19d1b484e0
split out room info into its own function
2023-11-26 22:16:38 -05:00