Hi! I made an online graphviz editor which generates graphviz images that can be used directly on any website without a need to host images on a server. Instead of downloading the image and hosting it on a server, the user can just copy the link generated and use it anywhere.
Very cool! I played with this just now and itās quite fun to experiment.
One minor thing: I donāt know much about building web sites, but this site absolutely hammers my machine. Typing visibly laggy, CPUs at 100%, ā¦ This doesnāt appear to be related to graph generation itself, because this is happening when just typing, not clicking āGenerate.ā If I had to guess, Iād say it was the background animation, which is also quite distracting while youāre trying to type. This is in Firefox 104.0.1 on Fedora 36 in an X11 session.
Youāll want to be a bit careful running Graphviz on the server and exposing it to the public internet; thereās a lot of possible exploits; you might want to sandbox it, or at least be careful to run it as a user that has very few permissions.
I agree with Mark (I would seriously question the expertise of anyone who claims a computer-based system is ā100% secureā), but from a quick look at the back end it appears to run the server inside Docker. So for a useful exploit, presumably you would have to chain a Graphviz bug with a container escape. So itās more than script-kiddie level hacking.
Having said that, I would assume such a thing is possible. From the issues filed by Google Autofuzz that Mark linked, I expect most can be leveraged into RCE. At a guess, I would say it would take a motivated attacker only a few days to come up with something usable.
In the past, Iāve pondered whether we should ship a sandboxing tool with Graphviz. OS sandboxing mechanisms have reached a level of maturity on all the platforms we support that this would not be complex to implement. But Iāve shied away from this for threat modeling reasons. If you donāt trust a binary your vendor is shipping you, why would you trust the sandboxer they ship you? Thereās a bit of nuance here (weāre trying to defend against malicious input, not an actively malicious binary), but I still think itās wiser to depend on a third-party sandboxer with a more paranoid mindset (e.g. Bubblewrap). Ubuntu Snaps kind of have the right idea and macOS is moving in this direction, but decades of users expecting promiscuous file system access from their programs is making rolling this stuff out a bit of a tightrope-walk.