1
0
mirror of https://github.com/spacebarchat/server.git synced 2024-11-08 20:02:39 +01:00
Commit Graph

604 Commits

Author SHA1 Message Date
ngn13
9efe160340
making min password length configurable
Co-authored-by: Puyodead1 <puyodead@proton.me>
2023-06-10 22:13:44 +03:00
ngn
f006ddc735 Implemented password length check 2023-06-10 20:51:21 +03:00
Madeline
6c603afc54
Fix docs for /users/:id/profile 2023-06-11 00:51:03 +10:00
Madeline
6e47b8e0b3
Send user and roles id array in GET /guilds/:id/members/:id 2023-06-11 00:27:38 +10:00
Madeline
e545edad94
Return entire guild object in POST /guilds 2023-05-30 20:09:03 +10:00
Zert3x
09b163f8de
Update Connection.ts 2023-05-28 21:40:21 -04:00
Zert3x
6306c5e725
Update ipAddress.ts 2023-05-28 21:39:50 -04:00
Zert3x
6f7ce2bc77
forwaded -> forwarded 2023-05-28 21:27:01 -04:00
V3L0C1T13S
564d1a2fc9
feat: implement member list id generation 2023-05-24 12:02:03 -04:00
CyberL1
6390786018 fix: add return and run prettier 2023-05-13 11:09:52 +02:00
Cyber
654403a8e8
Merge branch 'spacebarchat:master' into master 2023-05-13 10:48:42 +02:00
Madeline
8ee792c2a2
Prevent /invites/:code for bots 2023-05-12 14:05:28 +10:00
CyberL1
5b3ef06c6b fix: don't create new vanity url when there's no ALIASABLE_NAMES flag 2023-05-10 18:57:04 +02:00
Puyodead1
ba0d1bb6ff
Merge pull request #1052 from spacebarchat/feat/auto-create-bot-users
Feat: Auto add bot users to new apps
2023-05-07 00:15:04 -04:00
Puyodead1
8534342e30
add initial_guild_id client state property 2023-05-07 00:11:18 -04:00
Puyodead1
f256209ff2
fix build failure 2023-05-07 00:06:56 -04:00
Puyodead1
bb22e42da9
create util for app bot user creation 2023-05-07 00:00:42 -04:00
Puyodead1
942cce913d
add option to auto add bot users to new apps 2023-05-06 23:53:43 -04:00
Puyodead1
dedb20d64f
add flags property to voice state update 2023-05-06 23:51:26 -04:00
Pete Pongpeauk
b95827939d
refactor SELECT_PROTOCOL_ACK (4) voice opcode to SESSION_DESCRIPTION
Signed-off-by: Pete Pongpeauk <kurtsiberg@gmail.com>
2023-05-04 16:52:26 -04:00
Erkin Alp Güney
21a589c2f6
Rename the guild feature to match discord.com
discord.com has this too, and it is called `INVITES_DISABLED`
2023-04-27 18:28:00 +03:00
Madeline
eb62028103
start listening before starting components in bundle 2023-04-24 23:42:25 +10:00
Madeline
797778db68
start listening before starting components in bundle 2023-04-24 23:40:07 +10:00
Madeline
40ad7bb3af
Merge branch 'master' into openapi 2023-04-19 01:27:19 +10:00
Madeline
4c6b1e8e16
Fix UserRelationsResponse schema 2023-04-19 01:24:51 +10:00
Madeline
31b2db8c54
Merge branch 'master' into feat/refactorIdentify 2023-04-18 21:36:28 +10:00
Madeline
cec495cc5f
Enforce theme_colors to be ints 2023-04-18 01:18:05 +10:00
Madeline
164fcc25f3
Fix body-parser errors not being filtered in ErrorHandler middleware 2023-04-16 21:46:50 +10:00
Madeline
b438f2b071
Rewrite getRouteDescriptions, fix message route not appearing in openapi spec 2023-04-16 01:51:52 +10:00
Madeline
46d86c4079
move guild/user prop initialisations into create/register methods 2023-04-14 22:27:22 +10:00
Madeline
4ecee6b291
fix typos 2023-04-14 22:26:11 +10:00
Puyodead1
a8a28542f7
fix some types not being generated correctly 2023-04-13 20:13:58 -04:00
Puyodead1
78d98f0244
spacebar 2023-04-13 15:48:27 -04:00
Puyodead1
866eb15d90
clusterfuck 2023-04-13 15:44:39 -04:00
Puyodead1
4824e14661
oapi: fix a few response types in auth 2023-04-13 15:41:49 -04:00
Puyodead1
e68819d97a
oapi: add missing 2fa types to login 2023-04-13 15:41:49 -04:00
Puyodead1
0d666732c6
oapi: bug fixes 2023-04-13 15:41:23 -04:00
Puyodead1
3a23842924
oapi: root level routes 2023-04-13 15:40:51 -04:00
Puyodead1
fd283f1d15
oapi: voice regions 2023-04-13 15:39:56 -04:00
Puyodead1
860b9d583e
oapi: finish users 2023-04-13 15:39:31 -04:00
Puyodead1
1ce7879ee8
oapi: users progress 2023-04-13 15:38:52 -04:00
Puyodead1
c97ce59a0a
oapi: stickers 2023-04-13 15:33:03 -04:00
Puyodead1
ad5f5cb90d
oapi: sticker packs 2023-04-13 15:32:37 -04:00
Puyodead1
a1d8869271
oapi: readstates 2023-04-13 15:32:05 -04:00
Puyodead1
3fa2a95429
oapi: policies 2023-04-13 15:32:04 -04:00
Puyodead1
1b1fbce4d3
oapi: oauth2 2023-04-13 15:30:37 -04:00
Puyodead1
3a40254ca5
oapi: invites 2023-04-13 15:30:09 -04:00
Puyodead1
5c0a6f4e55
oapi: fix guild discovery requirements 2023-04-13 15:29:21 -04:00
Puyodead1
c2ce88dee7
guilds 2023-04-13 15:28:41 -04:00
Puyodead1
787de50140
backfill missing query params 2023-04-13 15:24:37 -04:00
Puyodead1
0dc5b19bd8
gifs and query params 2023-04-13 15:24:37 -04:00
Puyodead1
6b3a3b750f
fixing lots of openapi crap 2023-04-13 15:20:10 -04:00
Puyodead1
777e7208dc
AAA 2023-04-13 15:06:21 -04:00
Puyodead1
6347a77a79
gateway 2023-04-13 15:05:35 -04:00
Puyodead1
4a7811a25c
channels 2023-04-13 15:04:56 -04:00
Puyodead1
3335f16ad1
applications 2023-04-13 15:00:32 -04:00
Puyodead1
a567ca3f51
auth routes 2023-04-13 14:58:53 -04:00
Madeline
5a6cb33f5e
Merge branch 'master' into feat/refactorIdentify 2023-04-13 19:45:44 +10:00
Madeline
9a6390b9bd
Fix DC client throwing on GUILD_CREATE 2023-04-12 21:03:49 +10:00
Madeline
2d50adf151
Add missing route middleware to messages route 2023-04-12 11:45:51 +10:00
Madeline
3c981b496b
don't allow editing @everyone role 2023-04-11 13:51:55 +10:00
Madeline
80c7eaa70f
Merge pull request #1023 from Rainb0wCodes/master
properly track reactions
2023-04-11 13:48:08 +10:00
Madeline
ab07ad692c
send public member in message_reaction_add eventt 2023-04-11 13:47:26 +10:00
Madeline
f040caa712
Merge pull request #1026 from ochen1/patch-3
Add support for Discord's new endpoints to update roles
2023-04-11 13:20:09 +10:00
Madeline
d865528442
Add erkins note 2023-04-11 13:19:26 +10:00
Madeline
7a2a41be3e
Don't fetch the entire role relation when counting member ids 2023-04-11 13:17:51 +10:00
Madeline
e9ce4ca51b
member-counts route 2023-04-11 13:11:19 +10:00
Madeline
debfaea866
Use partition func instead + use Promise.all 2023-04-11 12:56:32 +10:00
Madeline
6a148898a5
Remove Member.isInGuildOrFail, as it will always pass ( route permission check ) 2023-04-11 12:33:59 +10:00
Madeline
b91fca6d74
prettier 2023-04-11 12:28:16 +10:00
Rainb0w :3
88031fd0b7
Update reactions.ts 2023-04-10 20:26:00 -06:00
Madeline
6dfe88d61b
Merge pull request #1025 from ochen1/patch-2
Send guild name and icon of guild through Identify gateway opcode
2023-04-10 17:30:19 +10:00
ochen1
36ac484a9d
Fix obvious bugs in Member removeRole function 2023-04-09 14:22:24 -06:00
ochen1
f4e172eec2
Add PATCH /guilds/#guild_id/roles/#role_id/member-ids API 2023-04-09 12:38:13 -06:00
ochen1
4a7eb89a72
Fix indentation 2023-04-09 12:36:31 -06:00
ochen1
3c2d07d0b1
Add PATCH /guilds/#guild_id/roles/#role_id/members API
Discord uses this in the Edit Role menu, Manage members tab to update the list of members with the role.
2023-04-09 12:34:45 -06:00
ochen1
7327669672
Send guild name and icon of guild through Identify gateway opcode
These properties are mandatory as per the documentation:
https://discord.com/developers/docs/resources/guild#guild-object
2023-04-09 11:13:28 -06:00
Rainb0w :3
2c067969a0
properly track reactions 2023-04-08 22:07:23 -06:00
Madeline
df696d362a
Close if already identified 2023-04-05 20:47:47 +10:00
Madeline
a9eac479bb
prettier whoops 2023-04-05 19:42:28 +10:00
Madeline
89c77dc449
Missing ready guild properties 2023-04-04 00:20:13 +10:00
Madeline
0095b65050
Role flags 2023-04-04 00:17:02 +10:00
Madeline
3e9e8aac3b
Don't send random read state / guild settings version numbers 2023-04-04 00:16:10 +10:00
Madeline
a476319fb4
Send d: {} in heartbeat ack 2023-04-04 00:15:37 +10:00
Madeline
6ee26082ef
Respect CLIENT_STATE_V2 capability 2023-04-03 23:50:48 +10:00
Madeline
844f1de6aa
License information 2023-04-02 11:32:40 +10:00
Madeline
2e27281e23
Less spammy user connection logs 2023-04-02 11:26:51 +10:00
Madeline
d90fd6b4e5
Update connection metadata visibility 2023-04-02 11:15:08 +10:00
Madeline
218f71b82c
Merge branch 'master' into refactor/dev/connections 2023-04-02 10:55:17 +10:00
Madeline
d944dd4ef4
allow all role props through ready 2023-04-01 19:49:54 +11:00
Madeline
13dedb6d25
Merge branch 'master' into feat/refactorIdentify 2023-04-01 19:04:22 +11:00
Madeline
ed724472b3
gatewayresponse?? 2023-04-01 19:01:34 +11:00
Madeline
095cbf7b20
Remove ALL fosscord mentions 2023-03-31 15:52:33 +11:00
Madeline
698ad90d3e
Revert "Merge pull request #1008 from spacebarchat/dev/samuel"
This reverts commit 69ea71aa9e, reversing
changes made to 8b2faf0b18.
2023-03-31 15:26:15 +11:00
Samuel
c8f65ca4c7 fix: disable cache if multi threaded 2023-03-30 18:26:19 +02:00
Samuel (Flam3rboy)
69ea71aa9e
Merge pull request #1008 from spacebarchat/dev/samuel 2023-03-30 18:13:34 +02:00
Madeline
8b2faf0b18
SPACEBAR 2023-03-31 02:15:42 +11:00
Madeline
64e747a4d2
SPACEBAR 2023-03-31 02:05:02 +11:00
Madeline
59c0dd0731
Merge branch 'master' of github.com:fosscord/fosscord-server 2023-03-24 04:18:19 +11:00
Madeline
0f928e479c
Work towards fixing openapi spec 2023-03-24 04:16:58 +11:00
Madeline
ce52a8884a
Merge pull request #1012 from Puyodead1/patch/totp-user-settings
fix totp using wrong settings key
2023-03-22 14:32:50 +11:00
Puyodead1
002480df9d
fix totp using wrong settings key 2023-03-21 22:32:55 -04:00
Madeline
1fd01fa000
Merge branch 'master' of github.com:fosscord/fosscord-server 2023-03-19 22:11:54 +11:00
Madeline
240076a5d8
Add basic information page to / 2023-03-19 21:49:45 +11:00
Puyodead1
5a7765c7dc
prettier 2023-03-18 19:50:38 -04:00
Puyodead1
7116a9a1b0
fix a few linting errors 2023-03-18 19:48:44 -04:00
Madeline
c7277efbad
Move redirect uri generation to getRedirectUri function of Connection class.
Use api_endpointPublic instead of cdn_endpointPublic
2023-03-18 19:33:32 -04:00
Madeline
9d5c5a8292
Check visibility for connected accounts in /users/:id/profile 2023-03-18 19:28:47 -04:00
Puyodead1
eab530a63d
Add Youtube connection 2023-03-18 19:28:47 -04:00
Puyodead1
d8ecc4269f
replace node-fetch with wretch 2023-03-18 19:28:46 -04:00
Puyodead1
06140fc768
add Xbox connection 2023-03-18 19:28:46 -04:00
Puyodead1
0baa37e41f
add Twitter connection 2023-03-18 19:28:46 -04:00
Puyodead1
bdd4ddda52
don't send token_data on connection update 2023-03-18 19:28:45 -04:00
Puyodead1
7e10d73dac
use connection revoked error 2023-03-18 19:28:45 -04:00
Puyodead1
6d6944cfee
Add Twitch, error handling, revokation changes, etc 2023-03-18 19:28:45 -04:00
Madeline
a60f147156
Fix connection update visibilty dying when given boolean 2023-03-18 19:27:40 -04:00
Puyodead1
02a4a6998d
Update todo in access-token route 2023-03-18 19:27:40 -04:00
Puyodead1
0db1fa5f0b
Refreshable connections, refactoring, access-token endpoint
- Aded /users/@me/connections/:connection_name/:connection_id/access-token
- Replaced `access_token` property on ConnectedAccount with `token_data` object for refreshing tokens
- Made a common interface for connection things like ComonOAuthTokenResponse
- Added `RefreshableConnection` class
- Added token refresh to Spotify connection (disabled)
2023-03-18 19:27:39 -04:00
Madeline
50f068400d
Don't try to upload entire config for each connection loaded 2023-03-18 19:26:16 -04:00
Madeline
42b2237d0f
Switch from Github real name to username for GH connection 2023-03-18 19:26:16 -04:00
Madeline
3f9887d855
Add discriminator usernames for Discord connection 2023-03-18 19:26:15 -04:00
Madeline
2bae842926
Delete connections 2023-03-18 19:26:15 -04:00
Puyodead1
747ff5d322
fix discord connection 2023-03-18 19:26:15 -04:00
Puyodead1
3c7cde5985
Add spotify connection 2023-03-18 19:26:15 -04:00
Puyodead1
ab4a28ee31
Add reddit connection 2023-03-18 19:26:14 -04:00
Puyodead1
901d126d6b
Add facebook connection 2023-03-18 19:26:14 -04:00
Puyodead1
d12751006e
add epic games connection 2023-03-18 19:26:14 -04:00
Madeline
d76198d200
WIP Discord connection 2023-03-18 19:26:14 -04:00
Madeline
8ff3767d32
Fix ConnectionLoader from throwing when uploading default config keys 2023-03-18 19:25:03 -04:00
Madeline
a390596e3c
Follow Discord docs for visibility and metadata_visibility fields in ConnectedAccount 2023-03-18 19:25:03 -04:00
Madeline
2364096a97
entities/ConnectionUpdateSchema -> schemas/ConnectionUpdateSchema 2023-03-18 19:25:03 -04:00
Madeline
5491c58ffc
Don't use mergeDeep 2023-03-18 19:23:57 -04:00
Madeline
a4961800d7
handleCallback returns connection if created for USER_CONNECTIONS_UPDATE 2023-03-18 19:23:20 -04:00
Puyodead1
5c682137b2
implement PATCH connection 2023-03-18 19:16:41 -04:00
Puyodead1
6a52e65e27
adding connection now works 2023-03-18 19:15:40 -04:00
Puyodead1
21bfda32e4
add connections 2023-03-18 19:09:51 -04:00
Samuel
3dc0e68534 feat: add DB_LOGGING env 2023-03-18 05:11:33 +01:00
Samuel
f1f7e5ad7d fix: local cache 2023-03-18 05:11:14 +01:00
Samuel
c6708f7443 build: remove sqlite3 in favor of better-sqlite3 2023-03-18 04:39:28 +01:00
Samuel
fd1c99db2d build: remove sqlite3 in favor of better-sqlite3 2023-03-18 04:20:03 +01:00
Samuel
d97dbdf73c fix: remove proxy 2023-03-18 04:18:18 +01:00
Samuel
7b00e99053 fix: use entity.save() instead of insert (needed for caching) 2023-03-18 04:13:04 +01:00
Samuel
52f8508b38 fix: missing id in select query 2023-03-18 04:12:16 +01:00
Samuel
366c4935a4 feat: Database Query Cache 2023-03-18 04:11:48 +01:00
Samuel
2e473576cf wip: cache 2023-03-17 19:47:23 +01:00
Samuel
cae6fcc72a fix: request language property 2023-03-17 19:30:54 +01:00
Samuel
5ba7c6b5bc perf: optimize getPermission() 2023-03-17 19:18:57 +01:00
Samuel
197f1aacd2 feat: better-sqlite3 support 2023-03-17 19:18:31 +01:00
Samuel
d086c053bb perf: custom i18next middleware that only initializes when needed 2023-03-17 17:50:59 +01:00
Samuel
810f5dd84c perf: cache jwt secret as key 2023-03-17 17:47:43 +01:00
Samuel
5b6b97e86c fix: types when using yarn 2023-03-17 16:36:44 +01:00
Samuel
1de0dbe509 build: update dependencies 2023-03-17 16:36:25 +01:00
Madeline
1234d0c95b
Merge pull request #997 from Puyodead1/dev/default-group-dm-avatars
Add default group dm icons
2023-03-16 15:50:08 +11:00
Madeline
d76568bd29
Merge pull request #996 from Puyodead1/patch/rename-default-avatars
Rename default avatar files
2023-03-16 15:49:48 +11:00
Madeline
4d06b86d7b
Fix UserSettings relation being in select rather than relations 2023-03-16 11:31:24 +11:00
Madeline
f228561f4c
Initial identify rewrite 2023-03-13 19:02:52 +11:00
Puyodead1
c257973741
add default group dm avatars 2023-03-07 22:59:47 -05:00
Puyodead1
b9346f7b01
use real md5 hash 2023-03-07 22:52:34 -05:00
Madeline
b9ffef8753
Remove test client and client patcher 2023-03-01 18:45:58 +11:00
Madeline
deb0da524e Rename password_reset config to passwordReset as it messes with config key generation 2023-02-25 20:31:10 +11:00
Madeline
048459b75f Merge branch 'master' of github.com:fosscord/fosscord-server 2023-02-24 23:49:07 +11:00
Madeline
51fe1b8955 send required_action in gateway for when email verification is required 2023-02-24 23:46:52 +11:00
Puyodead1
a22cdaaac6 fix a few issues with emails 2023-02-24 07:45:29 -05:00
Puyodead1
d3b1fd2026 move transporters to their own files 2023-02-24 07:10:56 -05:00
Puyodead1
770217b4b2 simplify replacer function 2023-02-24 07:02:36 -05:00
Puyodead1
91e9d60040 first batch of requested changes 2023-02-24 06:52:01 -05:00
Puyodead1
ed38d74b3e don't return token on register if verification required 2023-02-24 06:36:57 -05:00
Puyodead1
05453ec148 implement password reset 2023-02-24 01:54:10 -05:00
Puyodead1
dc48a74373 add SendGrid transport 2023-02-24 00:39:17 -05:00
Puyodead1
a78e13073f don't print anything if email send is successful 2023-02-24 00:10:50 -05:00
Puyodead1
6daaaf71e6 error if correspondence email is not set 2023-02-23 23:59:24 -05:00
Puyodead1
ed5aa51a8f fix for when secure is set to false 2023-02-23 23:44:48 -05:00
Puyodead1
ada821070b add right to resend verification emails 2023-02-23 22:52:24 -05:00
Puyodead1
1aba7d591c fix: email verification 2023-02-23 22:49:55 -05:00
Puyodead1
54dbc7190b fix: verification required for login not working correctly 2023-02-23 22:49:55 -05:00
Puyodead1
34cde14f75 config: require account verification 2023-02-23 22:40:05 -05:00
Puyodead1
97bafa81fc fix linting errors 2023-02-23 22:40:05 -05:00
Puyodead1
bf55ebc81f Add mailjet transport 2023-02-23 22:38:02 -05:00
Puyodead1
4383fcd449 Add Mailgun transport 2023-02-23 22:35:07 -05:00
Puyodead1
01103268c3 rename SMTPConfigurations to EmailConfiguration 2023-02-23 21:35:54 -05:00
Puyodead1
689b710c9e Fix template rendering and use verify email template
email html is weird, some stuff isn't supported.
2023-02-23 21:35:54 -05:00
Puyodead1
a47d80b255 Email verification works
- Added /auth/verify to authenticated route whitelist
- Updated /auth/verify to properly mark a user as verified, return a response, and fix expiration time check
- Implemented /auth/verify/resend
- Moved verification email sending to a helper method
- Fixed VerifyEmailSchema requiring captcha_key
2023-02-23 21:35:51 -05:00
Puyodead1
cc6bf066b1 add missing copyright headers 2023-02-23 21:35:50 -05:00
Puyodead1
256c7ed8fe send email verification 2023-02-23 21:35:49 -05:00
Puyodead1
ed6c1cbd15 Start implementing smtp 2023-02-23 21:35:49 -05:00
Madeline
eee98516dd Fix gateway encoding Date objects as {} when using erlpack. Fixes NaN/NaN/NaN timestamps in desktop client 2023-02-21 12:01:49 +11:00
Madeline
5f553cc614 Close #954 2023-02-21 11:35:06 +11:00
TheArcaneBrony
16f13616d2 Remove channel mentions from messages, in order to fix them in test client.
Signed-off-by: TheArcaneBrony <myrainbowdash949@gmail.com>
2023-02-20 05:09:57 +01:00
Madeline
3dae9d4e59 Implement default avatars #979 2023-02-18 12:57:06 +11:00
Madeline
2b627ab4a4 Update default avatar colour scheme and fix ordering 2023-02-18 12:52:32 +11:00
Puyodead1
1189deaa7c add support for desktop/web 2023-02-17 19:59:12 -05:00
Puyodead1
6fa4f9649f async 2023-02-17 18:10:05 -05:00
Puyodead1
090060d580 Implement default avatars 2023-02-17 18:00:16 -05:00
Madeline
c59af81563 Fix a bug prevent connections using erlpack (#977) 2023-02-16 19:31:36 +11:00
Madeline
cc50ebf47b Fix being unable to unset nicknames
Remove unwanted guild profile handler in cdn
Fix rights check for bio/avatars of your own user
2023-02-05 12:35:27 +11:00
Madeline
e7e3c67a77 Don't use relative path for db entities. Closes #937 2023-02-03 22:45:07 +11:00
Madeline
6d8e6eca9d On db sync/first run, add all the current migrations to migrations table to prevent running them on restarts 2023-02-03 22:39:10 +11:00
Madeline
d899942b1a Merge branch 'master' of github.com:fosscord/fosscord-server 2023-02-03 16:28:12 +11:00
Madeline
9aa31d24ab remove MANAGE_GUILDS, EDIT_FLAGS, SELF_EDIT_FLAGS, MANAGE_GROUPS from default rights 2023-02-03 16:26:50 +11:00
Puyodead1
e290965d00 various fixes for webauthn (#973) 2023-02-03 15:05:54 +11:00
Madeline
74570994c8 run add:license 2023-02-03 14:40:41 +11:00
Madeline
16a5cbac87 Don't allow message types to be edited 2023-02-03 14:39:42 +11:00
Madeline
6e04c92f07 Merge pull request from GHSA-9qvc-84ch-5p2x
* Check permissions and rights

* Prevent editing message type unless MANAGE_MESSAGES right. Also don't send sensitive data in patch response.
2023-02-02 22:26:22 +11:00
Madeline
067d2d8be8 Merge pull request from GHSA-hqqp-gpqw-9w5c 2023-02-02 22:24:56 +11:00
Madeline
cf04de4add Merge pull request from GHSA-9q7f-pv47-cxp9 2023-02-02 22:22:30 +11:00
Madeline
af6b5a6594 Merge pull request from GHSA-r7h4-76f7-6264
* Actually use maxUsername config value.

* Change maxUsername default to discord.com default
2023-02-02 22:15:03 +11:00
Madeline
da20866967 Use erlpack instead of @yukikaze-bot/erlpack (#968) 2023-02-01 13:00:04 +11:00
TheArcaneBrony
352ad14e9a Rename postgresql to postgres -> fix silently failing migrations
Signed-off-by: TheArcaneBrony <myrainbowdash949@gmail.com>
2023-01-31 23:33:07 +01:00
TheArcaneBrony
6b466ab654 Hotfix postgres connection string to not silently fail migrations 2023-01-31 23:27:19 +01:00
TheArcaneBrony
c99deeb69b Fix missing capitalisation in database connected log 2023-01-31 23:15:10 +01:00
TheArcaneBrony
1b6bc94afc Add a tiny bit of extra logging to database connection 2023-01-31 23:13:23 +01:00
Madeline
63b4a8997f Fix missing props in welcome message creation, which causes every client who received the welcome message to disconnect. 2023-02-01 00:12:00 +11:00
Madeline
ae8f4d6752 check pw and other auth before letting users undisable 2023-01-31 15:13:19 +11:00
Madeline
d4d1ab181e subscribe clients to member events when they lazy request members 2023-01-30 20:23:35 +11:00
Madeline
ac51849f28 question mark. 2023-01-30 20:05:07 +11:00
Madeline
1c4cb721be Impl member lazy request (#970) 2023-01-30 19:57:00 +11:00
Madeline
71258f6487 read-states/ack-bulk (#969) 2023-01-30 13:34:27 +11:00
Puyodead1
709dc7280e Implement WebAuthn (#967)
* implement webauthn

* code review

---------

Co-authored-by: Madeline <46743919+MaddyUnderStars@users.noreply.github.com>
2023-01-30 13:30:42 +11:00
Madeline
e98cdfbce0 Merge branch 'master' of github.com:fosscord/fosscord-server 2023-01-26 14:30:34 +11:00
Madeline
ac7a178f88 Fix SIGTERM handler not disconnecting gateway clients and leaving timeouts active 2023-01-26 14:29:33 +11:00
Madeline
8384a2c539 also don't use 3002 as default when gateway endpoints are null 2023-01-26 10:21:13 +11:00
Madeline
1886d53943 Use localhost:3001 as fallback when cdn endpoints are null rather than 3003 2023-01-26 10:18:16 +11:00
Madeline
1dcaa9f5f9 Don't set default cdn endpoints. Null endpoints means to not update them in GLOBAL_ENV. TODO: Don't use private endpoint locations in global env if public is not set, as this limits infra config 2023-01-26 01:10:05 +11:00
Madeline
85c880b230 Refactor config utils (#963) 2023-01-24 11:09:14 +11:00
Madeline
084dc0be08 Add ESLint (#941)
* Add eslint, switch to lint-staged for precommit

* Fix all ESLint errors

* Update GH workflow to check prettier and eslint
2023-01-20 18:10:47 +11:00
Puyodead1
0c815fde91 fix: route file regex (#956) 2023-01-20 01:52:05 +11:00
ChrisChrome
a537df8218 Apparently its still accepted, just depricated 2023-01-18 19:37:15 -07:00
ChrisChrome
6f5d429403 It's seconds, not days 2023-01-18 19:33:30 -07:00
ChrisChrome
70475d8397 Fix a funny security vuln 2023-01-18 12:27:15 -07:00
Chris Chrome
fbac5c7cd7 Merge pull request #952 from fosscord/dev/endpoints-in-ping
Merge /dev/endpoints-in-ping to master
2023-01-18 12:14:05 -07:00
Madeline
1a0cbcb1d4 Merge branch 'master' of github.com:fosscord/fosscord-server 2023-01-18 20:17:36 +11:00
Madeline
1ab279e2ef Don't fetch the emoji owner in identify, as this causes mass-disconnects with large emoji counts.
TODO: Remove some additional emoji props from being sent (user_id for example)
2023-01-18 20:16:49 +11:00
Chris Chrome
7152a1c2c1 Add youtu.be embed handler (#945) 2023-01-18 17:47:23 +11:00
Madeline
0e7f127ece Script to add license preamble to each file. Also, does that. (#935)
* Add script to automatically add license to each file

* Add license preamble to each file.

* Fix existing preamble detection breaking due to line endings. Git :(

* Prevent license from being added to code with other licenses
2023-01-18 13:05:49 +11:00
V3L0C1T13S
eb2f6ab79a send GUILD_CREATE after READY event (#938)
* Fix lazy guilds being sent before READY event

* Make casing consistent
2023-01-17 15:44:29 +11:00
Madeline
0af3da6db7 Fix deleting an application if it has a bot 2023-01-17 00:01:14 +11:00
Madeline
0b89db8031 Merge pull request #934 from fosscord/master
Merge master into dev/endpoints-in-ping
2023-01-16 17:00:32 +11:00
Madeline
5771247645 Return embed proxy url even if imagor not set up. Also make warning nicer 2023-01-16 14:20:17 +11:00
Chris Chrome
8a23ac19f8 Move endpoints from ping -> policies/instance/domains (#933) 2023-01-16 13:46:41 +11:00
Madeline
de3909f646 Update dead lines 2023-01-16 00:03:51 +11:00
Madeline
dda70a66c9 Add an error log if embed handler fails, in addition to the existing sentry log 2023-01-15 16:21:46 +11:00
TheArcaneBrony
1d27e61029 Fix some default value
Signed-off-by: TheArcaneBrony <myrainbowdash949@gmail.com>
2023-01-14 23:34:33 +01:00
TheArcaneBrony
754d8dbf64 Add basic info in ping
Signed-off-by: TheArcaneBrony <myrainbowdash949@gmail.com>
2023-01-14 19:55:19 +01:00
Erkin Alp Güney
876c15b1a9 Add /users/:id/delete (#926) 2023-01-14 19:15:35 +11:00
Madeline
43a0260cd8 Fix guild delete failing when template exists 2023-01-13 22:38:55 +11:00
Madeline
f544c6890c Fix dumping incoming messages 2023-01-13 13:49:58 +11:00
Madeline
a69c047854 Fix setting user premium_type/etc (non-nullable) to null in db when null in config 2023-01-13 13:44:58 +11:00
Madeline
3bbf997295 Dont send sessions replace or presence update for unidentified users 2023-01-13 13:44:19 +11:00
TheArcaneBrony
6122374e4d Dev/post refactor fixes (#927)
* Re-introduce outgoing message logging

Signed-off-by: TheArcaneBrony <myrainbowdash949@gmail.com>

* Websocket dumping

* Sentry user count on API

* Generate session ID upon opening websocket, fix gateway dumps

* Async file io in src/gateway/events/Message.ts

Signed-off-by: TheArcaneBrony <myrainbowdash949@gmail.com>

* Async file io in src/util/util/Config.ts

Signed-off-by: TheArcaneBrony <myrainbowdash949@gmail.com>

* Make pre-commit hook executable

Signed-off-by: TheArcaneBrony <myrainbowdash949@gmail.com>

* Fixed sync file io in src/util/util/Config.ts

Signed-off-by: TheArcaneBrony <myrainbowdash949@gmail.com>

* Fixed missing await call in src/util/util/AutoUpdate.ts

Signed-off-by: TheArcaneBrony <myrainbowdash949@gmail.com>

* Add comment to src/gateway/events/Connection.ts

Signed-off-by: TheArcaneBrony <myrainbowdash949@gmail.com>

* Clean up gateway dumping code

Signed-off-by: TheArcaneBrony <myrainbowdash949@gmail.com>
Co-authored-by: Madeline <46743919+MaddyUnderStars@users.noreply.github.com>
2023-01-12 23:46:36 +11:00
Madeline
da9ce34933 Temp fix for DMs 2023-01-12 00:32:24 +11:00