Ok now that I have generously coated myself in flame-war retardant.

I have an existing webapp/server written in c++/qt. Having selected OpenBSD as the hosting OS for security reasons.

If I use the BCHS stacks httpd must I use FastCGI to generate dynamic content, as the webapp already understands http I find FastCGI a Pointless overhead ?

If I replace httpd with my webapp any suggestion how it should be sandboxed ?

  • 1
    You're going to write your own web server? – swdev Dec 28 '16 at 1:29
  • I wish, it is just webapp on top of a QtWebApp a server framework. but the app does server static and dynamic content so it could replace httpd. – ArchNemSyS Dec 28 '16 at 12:26
  • that article you cite is realllly stretching it - sure, implementing fastcgi from the ground up isn't going to be easy, but using the existing libraries is simple – pete Jan 1 '17 at 16:25

Running C++ CGI application in Apache is fairly straightforward. And it actually convenient if you entire code base is C++ and you just want a basic web user interface. At work we did a internal portal with this technique. Never did FastCGI since only a handful of people used the service. But I think you have taken your design a step further which few have ventured.

Apache (or probably any httpd) will let you run specific URL as a specific user which can sandbox the process. That would be my recommendation right there. But if you decide you want to use QtWebApp a server framework then the framework needs to have that ability (my guess is it doesn't) -or- inside your WebApp you need spawn a process as another user and hope it doesn't cause problems in your framework.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.