Commit Graph

18 Commits

Author SHA1 Message Date
Matthew Penner
d1c0ca5260
server(filesystem): rebuild everything imaginable
This wonderfully large commit replaces basically everything under the
`server/filesystem` package, re-implementing essentially everything.

This is related to
https://github.com/pterodactyl/wings/security/advisories/GHSA-494h-9924-xww9

If any vulnerabilities related to symlinks persist after this commit, I
will be very upset.

Signed-off-by: Matthew Penner <me@matthewp.io>
2024-03-13 12:27:29 -06:00
DaneEveritt
7bd11c1c28
Switch to SQLite for activity tracking 2022-07-10 16:51:11 -04:00
DaneEveritt
f28e06267c
Better tracking of SFTP events 2022-07-10 14:30:32 -04:00
DaneEveritt
59fbd2bcea
Add initial niaeve implementation of SFTP logging
This will end up flooding the activity logs due to the way SFTP works, we'll need to have an intermediate step in Wings that batches events every 10 seconds or so and submits them as a single "event" for activity.
2022-07-09 19:37:42 -04:00
DaneEveritt
7fa7cc313f
Fix permissions not being checked correctly for admins 2022-05-29 21:48:49 -04:00
Dane Everitt
301788805c Ensure a file uploaded using SFTP is properly owned at the end; closes pterodactyl/panel#3689 2022-01-23 13:14:02 -05:00
Matthew Penner
d8df353ce8
replace deprecated ioutil function calls 2021-11-15 10:24:52 -07:00
Matthew Penner
ca25ba5fab
sftp: deny access if server is suspended (#100) 2021-08-03 19:56:02 -07:00
Matthew Penner
3c54c1f840 break everything
- upgrade dependencies
- run gofmt and goimports to organize code
- fix typos
- other small tweaks
2021-08-02 15:07:00 -06:00
Dane Everitt
2968ea3498
Modify stat to embed os.FileInfo differently and update file content reader 2021-01-16 12:03:55 -08:00
Dane Everitt
0cb3b815d1
Finish refactoring SFTP server logic 2021-01-10 15:06:06 -08:00
Dane Everitt
c228acaafc
Massive refactor of SFTP system now that it is deeply integrated with Wings 2021-01-10 14:25:39 -08:00
Jakob Schrettenbrunner
648072436f organize imports with gopls format 2021-01-10 01:22:39 +00:00
Matthew Penner
a4c8b8714b Bump all dependencies 2020-12-27 11:49:08 -07:00
Matthew Penner
de51fd1c51
Error handling improvements (#71)
* Remove `emperror.dev/errors`, remove all `errors#Wrap` and `errors#WithStack` calls
* Improve logging in `server/backup.go`
2020-11-28 16:57:10 -07:00
Dane Everitt
be9d1a3986
Replace error handling package with emperror; add better reporting for errors escaping server root 2020-11-08 13:52:20 -08:00
Matthew Penner
7ba32aca84 Fix some typos and run gofmt on all .go files 2020-09-05 13:08:40 -06:00
Dane Everitt
1e633ae302
Bring the sftp server code into the package itself 2020-08-31 20:14:04 -07:00