Navigation
Table of Contents
Guide That Contains This Content
[+] Expand All
[-] Collapse All
Creating the DPI Script Service (SRC CLI)
To create the script service:
- Create a script service in the [edit services scope name service name] hierarchy.
In this sample procedure, the service is configured in the DPI service
scope, and DPI is the name of the service. user@host# edit services scope DPI service DPI
- Set the type of service to script. [edit services scope DPI service DPI]user@host# set type script
- (Optional) Configure other properties as needed for your service.
- Configure the script properties. [edit services scope DPI service DPI]user@host# edit script
- Configure net.juniper.smgt.dpiscriptservice.DpiService as the name of the class that implements the script service.[edit services scope DPI service DPI script]user@host# set class-name net.juniper.smgt.dpiscriptservice.DpiScriptService
- Configure Java archive file as the type of script that
the script service uses. [edit services scope DPI service DPI script]user@host# set script-type java-archive
- Specify the filename of the script service implementation
so that its contents will be loaded into the file option.
Copy the dpiss.jar file to the C Series Controller
before you specify the filename. In this sample procedure, the dpiss.jar file was copied from a location that is accessible
by a URL (such as an FTP or HTTP server) to the /tmp directory. [edit services scope DPI service DPI script]user@host# run file copy URL /tmp/dpiss.jar user@host# set filename /tmp/dpiss.jar
- (Optional) From configuration mode, enter the service
parameter configuration and configure values for parameters. user@host# edit services scope DPI service DPI parameter [edit services scope DPI service DPI parameter]user@host# set substitution [substitution...]
For example, to specify the configuration file that is used or to specify whether the configuration file is reloaded for each script service activation:
user@host# set substitution dpiConfig=\"resource/dpiConf.xml\"user@host# set substitution dpiConfigDebug=\"off\" - (Optional) Verify your configuration.
[edit services scope DPI service DPI] user@host# show