Commit Graph
214 Commits
Author SHA1 Message Date
modeco80 23c57dbb3b cvm-rs: Add jpegResizeEncode(), remove usage of sharp
sharp sucks.
2025-06-05 16:40:46 -04:00
dependabot[bot]andElijah R d9f9f0d07f build(deps): bump base-x from 3.0.10 to 3.0.11
Bumps [base-x](https://github.com/cryptocoinjs/base-x) from 3.0.10 to 3.0.11.
- [Commits](https://github.com/cryptocoinjs/base-x/compare/v3.0.10...v3.0.11)

---
updated-dependencies:
- dependency-name: base-x
  dependency-version: 3.0.11
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-06-05 15:46:11 -04:00
Elijah R 5621067c38 Bump nodejs-rfb, fix vncvm 2025-06-05 15:45:36 -04:00
modeco80 495a212c5f cvm-rs: bump turbojpeg-sys 2025-05-21 20:25:12 -04:00
Elijah RandGitHub a7971b2eec make compatibility more clear 2025-04-09 16:26:37 -04:00
LilyandGitHub f331767705 Merge pull request #29 from computernewb/dev/proto_capability_rework
merge proto rework branch
2025-03-21 22:11:26 -04:00
Elijah R 1c088cf814 cvmts: protocol error logging 2025-03-21 21:45:04 -04:00
Elijah R db4ddea2e7 cvmts: fix ban, re-add audit log 2025-03-21 21:36:02 -04:00
Elijah R 5705971be6 cvmts: fix rename oddities 2025-03-21 21:28:13 -04:00
Elijah R 10dd3c2489 cvmts: Move initial protocol selection to transport layer 2025-03-21 20:29:16 -04:00
Elijah R ab63420075 cvmts: rip out raw tcp transport
it's really just a tech debt that nothing uses, these is pretty much no point keeping it
2025-03-21 19:13:15 -04:00
Elijah R e1e5f4a352 Merge branch 'master' into dev/proto_capability_rework 2025-03-21 19:03:55 -04:00
modeco80 53dd05ccc2 cvmts: Fix protocol error disconnection behavior so it actually works 2025-03-06 17:08:58 -05:00
modeco80 b015274e3b cvm-rs: Fix out of bound element length scanning
Also, add a unit test just to make sure this doesn't happen again.
2025-03-06 16:46:09 -05:00
LilyandGitHub 751b0492f6 Merge pull request #32 from computernewb/dependabot/npm_and_yarn/micromatch-4.0.8
build(deps): bump micromatch from 4.0.7 to 4.0.8
2024-11-05 05:35:15 -05:00
modeco80 405e88bd1b cvmts: Allow specifying cgroup cpu period
probably limited utility wise but it's there now
2024-11-03 13:10:57 -05:00
modeco80 fe82973b9f Only try enabling cpuset controller if required
Additionally, "handle" (in many airquotes) errors trying to set controller values.
2024-11-02 18:01:07 -04:00
modeco80 e7a06b7141 cvmts: Delete cgroup on VM stop
Makes clean shutdown with systemd actually work.

I've also made superqemu version a SemVer thing so that we don't need to bump it as often, only on a major or minor bump.
2024-11-02 11:58:35 -04:00
modeco80 a3581854d2 had to help this hellfest of a language along slightly 2024-11-02 08:06:36 -04:00
modeco80 9fbdb84822 ok fiiiiine i'll do it the non hacky way 2024-11-02 07:54:26 -04:00
modeco80 86f1345a2d cvmts: Only target QEMU vCPU threads by default
Previous behaviour was to limit the whole QEMU process; this only limits the vCPU threads. A bit (very) hacky how I did this but it does work.
2024-11-02 07:46:59 -04:00
modeco80 4344b233bc cvmts: Bump up cpu.max period to 100000
(well, it DOES still work, but i imagine it's 100000 by default for a reason)
2024-11-02 06:33:31 -04:00
modeco80 e780ecabf0 cvmts: Add support for cgroup process resource limits on Linux
Using systemd's `Delegate=` option, it is possible to get it to let you manage your own cgroup subtree, therefore allowing you to set options and other fun stuff.

This commit adds support for doing so and configuring the resource limits in config.toml.

For later: The cgroup created has to be a threaded one. Iin theory, we can actually wait for the QEMU process to handshake qmp, grab the vCPU threads, and only limit those. For now, just limiting the entire QEMU process works, though and is the least complicated.

NOTE: Windows support should still work, even if you have resource limits configured. If you do, it should only warn and complain, but still function.
2024-11-02 06:08:26 -04:00
modeco80 bbc873a113 cvmts: Bump superqemu to 0.3.0 2024-11-02 03:11:07 -04:00
modeco80 25ed0515dd Revert "cvmts: rate limit the 'sync' instruction"
This reverts commit 199924ff92.

nvm the decade old shitcode webapp that people seem to still flock to for NO reason breaks
honestly why do we even support that hunk of trash it's a decade old, falling apart, and all it does
is stifle progress if anything
2024-10-05 05:11:02 -04:00
modeco80 199924ff92 cvmts: rate limit the 'sync' instruction
the original Guacamole code did this too I'm pretty sure, and it was even more aggressive about it.
2024-10-05 05:00:52 -04:00
modeco80 41ee71f053 cvmts: Add staff audit logging support
Basically what it says on the tin.

More staff operations should probably be audited, but for now this provides a good starting point.
2024-09-21 21:14:27 -04:00
modeco80 072fd06918 cvmts: fix display event handler duplication
By only adding event handlers when the display is first lazily initalized.
2024-09-19 04:11:25 -04:00
modeco80 210e36f430 cvmts: fix memory leak
javascript blows chunks
2024-09-12 13:11:12 -04:00
dependabot[bot]andGitHub 4fdd209c87 build(deps): bump micromatch from 4.0.7 to 4.0.8
Bumps [micromatch](https://github.com/micromatch/micromatch) from 4.0.7 to 4.0.8.
- [Release notes](https://github.com/micromatch/micromatch/releases)
- [Changelog](https://github.com/micromatch/micromatch/blob/master/CHANGELOG.md)
- [Commits](https://github.com/micromatch/micromatch/compare/4.0.7...4.0.8)

---
updated-dependencies:
- dependency-name: micromatch
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-09-12 05:23:11 +00:00
modeco80 9d57779c75 fix config error logging so pino actually logs the Error object 2024-09-09 22:39:01 -04:00
modeco80 689be9d395 cvmts: Explicitly disable ws PMD/tracking
Seems to fix or at least make a pretty bad memory leak much slower.

I hate ws but the only other library is written by someone who isn't
a very nice person (putting it on the nice side)
2024-09-05 04:15:19 -04:00
modeco80 fae4c6d146 cvmts: Fix WebSocket errors causing process crashes 2024-08-30 20:30:17 -04:00
modeco80 4c085619ff remove todo that was done already 2024-08-23 10:15:38 -04:00
modeco80 48409a469a remove dead import 2024-08-23 10:15:38 -04:00
modeco80 a8d32f0555 move ProtocolManager into its own unit 2024-08-23 10:15:35 -04:00
modeco80 74d7b17d8b re-org source tree slightly
network layer is net/
protocol is protocol/
2024-08-23 10:15:10 -04:00
modeco80 f7fb30ba20 make network abstraction pass bare buffer
this bitrots tcp a bit. once the tcp protocol is replaced with a message based one it shouild be fine
2024-08-23 10:14:25 -04:00
modeco80 53b5b6d874 oops 2024-08-23 10:14:25 -04:00
modeco80 8f48092c5c move turn to protocol
everything now uses the protocol layer! woohoo.
2024-08-23 10:14:25 -04:00
modeco80 5dc53116b2 move flag and rename to protocol layer
This means that 'turn' is now the only thing not sent by the protocol layer.
2024-08-23 10:14:25 -04:00
modeco80 c9edb174f1 keep forgeting javascript tooling has about the same usability as a 80s ford 2024-08-23 10:14:25 -04:00
modeco80 0010a8f300 move 'vote' to Protocol 2024-08-23 10:14:24 -04:00
modeco80 1673f0abd7 move some shared stuff into a new baseclass for protocols to implement
will make greenfield (i.e: brand new non-Guac or whatever) protocol implementation a bit less boilerplatey
2024-08-23 10:14:23 -04:00
modeco80 4583531fce re-implement binrect protocol
pretty easy since we can just subclass guac
2024-08-23 10:14:23 -04:00
modeco80 6e1a075194 oops thought that was one of the admin only opcodes 2024-08-23 10:14:22 -04:00
modeco80 a82388f823 handle admin messages
TODO: Add senders for admin responses
and flag
and rename

also verify I didn't fuck boolean conversion up
2024-08-23 10:14:20 -04:00
modeco80 1c062697b9 WIP: protocol abstraction
Work on abstracting the CollabVMServer so it now calls into a interface for sending/recieving protocol messages. This will allow cleaner bringup of a fully binary protocol, and generally is just cleaner code.

Mostly everything is parsd/running through this new layer, although there are some TODO items:

- NetworkClient/... should just spit out a Buffer or something that eventually turns into or has one
- TCP protocol will need to be revamped so we can support an actual binary protocol on top of it. The current thing is line based
- More admin op stuff needs to be handled
- The handlers are a bit jumbled around atm
- There is still a good amount of code which assumes guacamole which needs to be rewritten

dont use this branch fuckers
2024-08-23 10:13:15 -04:00
LilyandGitHub 3c4ddb72b8 Merge pull request #30 from computernewb/dev/better_display
merge better display branch
2024-08-23 10:04:19 -04:00
modeco80 338cc6e824 clean up some stuff and upgrade to the latest superqemu release 2024-08-23 10:01:41 -04:00