LiteSpeed SAPI Context
Table of Contents
URI | LiteSpeed SAPI App | 标头控制 | 域 | 认证名称 | Require(授权的用户/组) | 允许访问列表 | 拒绝访问列表 | Authorizer | 添加默认的字符集 | 自定义默认字符集 | 启用IP地理定位
LiteSpeed SAPI Context⇑
Description
External applications cannot be used directly. They must be either configured as a script handler or mapped to a URL through a context. An LiteSpeed SAPI Context will associate a URI with an LSAPI (LiteSpeed Server Application Programming Interface) application. Currently PHP, Ruby and Python have LSAPI modules. LSAPI, as it is developed specifically for LiteSpeed web server, is the most efficient way to communicate with LiteSpeed web server.
URI⇑
Description
Specifies the URI for this context.
Syntax
指定此context下的URI。这个URI应该以"/"开始。 如果一个URI以"/"结束,那么该context将包含这个URI下的所有下级URI。如果context类型映射到系统目录上,则必须添加结尾的"/"
See Also
LiteSpeed SAPI App⇑
Description
指定要连接到此context的LiteSpeed SAPI应用程序。 此应用程序必须在服务器或虚拟主机级别的 外部应用中定义。
Syntax
从列表中选择
标头控制⇑
Description
指定要添加的附加响应/请求头。可以添加每行一个来添加多个头指令。"NONE "可以用来禁止父头继承。如果没有提供,则假定为 "Header"。
Syntax
[Header]|RequestHeader [condition] set|append|merge|add|unset header [value] [early|env=[!]variable]
例子
append Cache-control no-store
Header set My-header cust_header_val
RequestHeader set My-req-header cust_req_header_val
提示
语法和用法类似于 Apache's mod_headers directives
The 'Header' directive is is optional and can be excluded or left in when copying rules from elsewhere without issue.
域⇑
Description
指定这个context下的realm授权。 当指定时,必须提供有效的用户和用户名来访问这个context。 Realms授权需要在虚拟主机安全部分进行设置。 此设置使用每个realm的域名称。
Syntax
从列表中选择
认证名称⇑
Description
为当前context下的realm认证指定一个替代的名称。 如果没有指定,原realm名称将被使用。 认证名称将显示在浏览器登陆弹出窗口。
Require(授权的用户/组)⇑
Description
指定哪些用户/用户组可以访问此context。 这里允许你使用一个用户/组数据库(在 域中指定)访问多个context, 但只允许该数据库下特定的用户/组访问这个context。
Syntax
Syntax is compatible with Apache's Require directive. For example:
- user username [username ...]
Only listed users can access this context. - group groupid [groupid ...]
Only users belonging to the listed groups can access this context.
允许访问列表⇑
Description
指定允许访问这个context下资源的IP地址或子网。综合 拒绝访问列表项的配置以及服务器/虚拟主机级别访问控制, 可访问性将以客户端IP所符合的最小范围来确定。
Syntax
Comma-delimited list of IPs/sub-networks.
例子
拒绝访问列表⇑
Description
指定哪个IP地址或子网不被允许访问这个context下的资源。 综合允许访问列表项的配置以及服务器/虚拟主机级别访问控制, 可访问性将以客户端IP所符合的最小范围来确定。
Syntax
Comma-delimited list of IPs/sub-networks.
例子
Authorizer⇑
Description
指定可用于生成授权/未授权 decisions的外部应用程序。 目前,仅FastCGI授权器可用。 有关FastCGI授权者角色的更多详细信息, 请访问https://fastcgi-archives.github.io/。
Syntax
从列表中选择
添加默认的字符集⇑
Description
S指定当内容类型是"text/html"或"text/plain"且没有参数时,是否添加字符集标记到"Content-Type"响应报头中。当设置为Off时,该功能禁用。当设置为On时,将添加自定义默认字符集中指定的字符集,如果没有指定,将添加默认的"iso-8859-1"字符集。
Syntax
从单选框选择
自定义默认字符集⇑
Description
指定一个字符集当添加默认的字符集是On时使用。这是可选的。默认值是iso-8859-1。当添加默认的字符集是Off时本设置将不生效。
Syntax
Name of a character set.
例子
启用IP地理定位⇑
Description
指定是否启用IP地理定位查找。 可以在服务器级别,虚拟主机级别,或context级别设置。
Syntax
从单选框选择