1. A system comprising: a computing device comprising: a processor; an operating system that includes an execution environment in which applications can execute computer-specific commands; and a web-browser application comprising: a scripting environment for interpreting scripted modules according to one or more security policies that restrict interpretation of scripted modules; a native environment in which native modules can securely execute computer-specific commands, the native environment configured to restrict native modules from accessing one or more resources of the computing device or to restrict execution of one or more computer-specific commands; and an interface between the scripting environment of the web-browser application and the native environment of the web-browser application, the interface including functions to asynchronously pass data objects by value, from one of the scripting environment and the native environment, to the other of the scripting environment and the native environment, by providing copies of the data objects to one of the scripting environment and the native environment so that the copies are available to a scripted module or a native module in the other of the scripting environment and the native environment, respectively.
1. A system comprising: a computing device comprising: a processor; an operating system that includes an execution environment in which applications can execute computer-specific commands; and a web-browser application comprising: a scripting environment for interpreting scripted modules according to one or more security policies that restrict interpretation of scripted modules; a native environment in which native modules can securely execute computer-specific commands, the native environment configured to restrict native modules from accessing one or more resources of the computing device or to restrict execution of one or more computer-specific commands; and an interface between the scripting environment of the web-browser application and the native environment of the web-browser application, the interface including functions to asynchronously pass data objects by value, from one of the scripting environment and the native environment, to the other of the scripting environment and the native environment, by providing copies of the data objects to one of the scripting environment and the native environment so that the copies are available to a scripted module or a native module in the other of the scripting environment and the native environment, respectively. 6. The system of claim 1 , wherein web-browser application further comprises: a library of values, the library available to the scripting environment and to the native environment; and wherein the data object is an index of a value of the library.