locked
JScript and permissions RRS feed

  • Question

  • Hi

    Is it possible to restrict permissions to a JScript. For example, prevent it from creating COM components or accessing parts of the file system.


    Thanks
    Thursday, November 15, 2007 6:16 PM

Answers

  • Hi bkejser,

     

    Thanks for your quick reply.

     

    YES.You are right that those settings are specific to the scripts executed by the browser. JScript is Microsoft's implementation of JavaScript. Both JavaScript and JScript are based upon the ECMAScript standard. JScript is implemented as a Windows Script engine. This means that it can be "plugged in" to any application that supports Windows Script, such as Internet Explorer, Active Server Pages, and Windows Script Host.

    Based on my understanding, for jscript itself, I don't think it has any restricted permissions. If you would like to execute the scripts in an ASP.NET web page, you can refer to the statements of my last post to set the restricted permissions through IE ->Internet Options->Security.

     

    If I have misunderstood you, please correct me and clarify what you are concerning. Thanks.

     

    Regards,

    Monday, November 19, 2007 3:13 PM
    Moderator

All replies

  • Hi bkejser,

     

    As I understand, if you would like to restrict the permissioms to a jscript, I suggest you to take a look at the custom security level of IE through Open IE -> Tools ->Internet Options -> Security -> Custom Level.

    If you would like to prevent it from creating ActiveX COM components, you can try to disable "Initialize and script ActiveX controls not marked as safe for scripting" in IE.

     

    Hope this helps,

    Regards,

     

    Monday, November 19, 2007 8:33 AM
    Moderator
  • Aren't those settings specific to Javascript (executed by the browser) and not JScript (executed by cscript or wscript)?
    Monday, November 19, 2007 1:26 PM
  • Hi bkejser,

     

    Thanks for your quick reply.

     

    YES.You are right that those settings are specific to the scripts executed by the browser. JScript is Microsoft's implementation of JavaScript. Both JavaScript and JScript are based upon the ECMAScript standard. JScript is implemented as a Windows Script engine. This means that it can be "plugged in" to any application that supports Windows Script, such as Internet Explorer, Active Server Pages, and Windows Script Host.

    Based on my understanding, for jscript itself, I don't think it has any restricted permissions. If you would like to execute the scripts in an ASP.NET web page, you can refer to the statements of my last post to set the restricted permissions through IE ->Internet Options->Security.

     

    If I have misunderstood you, please correct me and clarify what you are concerning. Thanks.

     

    Regards,

    Monday, November 19, 2007 3:13 PM
    Moderator