QtScript and restricting IOScr



  • Hi,

    I need scripting in my Qt App and since I am already using Qt, it makes sense to use QtScript.
    But the script is handling sensitive data and can be potentially be written by a third person. For that reason I require that no data may be send to the outside except by functions which I define.
    So now writing to files, no connecting to the internet, no (something I do not think of right now).

    Is it possible to restrict the QtScript interpreter in this way? For example by not loading some libraries or so?

    Thanks!
    Nathan



  • I'm not sure this is the right approach but you could provide your own interface functions (overrides so to speak) for the common things you want to prevent. Those overwrites would still allow the script to run but you'd intercept and not allow the desired action or perhaps throw a script exception.


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.