app payload特征配置的l3_header配置增加属性,并且必须输入十六进制字符串,后台转为偏移表达式的字符串配置
This commit is contained in:
@@ -43,6 +43,19 @@ public class AppComplexFeatureCfg extends BaseCfg<AppComplexFeatureCfg> {
|
||||
private String appName;
|
||||
private List<AppIpCfg> ipPortList = new ArrayList();
|
||||
private String cfgRegionCode1;
|
||||
//以下参数为APP PAYLOAD L3_HEADER的特殊属性(使用偏移表达式处理)
|
||||
private String ver;
|
||||
private String ihl;
|
||||
private String tos;
|
||||
private String totalLength;
|
||||
private String flags;
|
||||
private String fragmentOffset;
|
||||
private String protocol;
|
||||
private String icmpType;
|
||||
private String icmpCode;
|
||||
private String icmpIdentifier;
|
||||
private String headerType;
|
||||
|
||||
public String getCfgRegionCode1() {
|
||||
return cfgRegionCode1;
|
||||
}
|
||||
@@ -197,5 +210,94 @@ public class AppComplexFeatureCfg extends BaseCfg<AppComplexFeatureCfg> {
|
||||
public void setIpPortList(List<AppIpCfg> ipPortList) {
|
||||
this.ipPortList = ipPortList;
|
||||
}
|
||||
|
||||
public String getVer() {
|
||||
return ver;
|
||||
}
|
||||
|
||||
public void setVer(String ver) {
|
||||
this.ver = ver;
|
||||
}
|
||||
|
||||
public String getIhl() {
|
||||
return ihl;
|
||||
}
|
||||
|
||||
public void setIhl(String ihl) {
|
||||
this.ihl = ihl;
|
||||
}
|
||||
|
||||
public String getTos() {
|
||||
return tos;
|
||||
}
|
||||
|
||||
public void setTos(String tos) {
|
||||
this.tos = tos;
|
||||
}
|
||||
|
||||
public String getTotalLength() {
|
||||
return totalLength;
|
||||
}
|
||||
|
||||
public void setTotalLength(String totalLength) {
|
||||
this.totalLength = totalLength;
|
||||
}
|
||||
|
||||
public String getFlags() {
|
||||
return flags;
|
||||
}
|
||||
|
||||
public void setFlags(String flags) {
|
||||
this.flags = flags;
|
||||
}
|
||||
|
||||
public String getFragmentOffset() {
|
||||
return fragmentOffset;
|
||||
}
|
||||
|
||||
public void setFragmentOffset(String fragmentOffset) {
|
||||
this.fragmentOffset = fragmentOffset;
|
||||
}
|
||||
|
||||
public String getProtocol() {
|
||||
return protocol;
|
||||
}
|
||||
|
||||
public void setProtocol(String protocol) {
|
||||
this.protocol = protocol;
|
||||
}
|
||||
|
||||
public String getIcmpType() {
|
||||
return icmpType;
|
||||
}
|
||||
|
||||
public void setIcmpType(String icmpType) {
|
||||
this.icmpType = icmpType;
|
||||
}
|
||||
|
||||
public String getIcmpCode() {
|
||||
return icmpCode;
|
||||
}
|
||||
|
||||
public void setIcmpCode(String icmpCode) {
|
||||
this.icmpCode = icmpCode;
|
||||
}
|
||||
|
||||
public String getIcmpIdentifier() {
|
||||
return icmpIdentifier;
|
||||
}
|
||||
|
||||
public void setIcmpIdentifier(String icmpIdentifier) {
|
||||
this.icmpIdentifier = icmpIdentifier;
|
||||
}
|
||||
|
||||
public String getHeaderType() {
|
||||
return headerType;
|
||||
}
|
||||
|
||||
public void setHeaderType(String headerType) {
|
||||
this.headerType = headerType;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -104,6 +104,17 @@
|
||||
<result column="function_id" property="functionId" jdbcType="INTEGER" />
|
||||
<result column="do_log" property="doLog" jdbcType="INTEGER" />
|
||||
<result column="cfg_type" property="cfgType" jdbcType="VARCHAR" />
|
||||
<result column="ver" property="ver" jdbcType="VARCHAR" />
|
||||
<result column="ihl" property="ihl" jdbcType="VARCHAR" />
|
||||
<result column="tos" property="tos" jdbcType="VARCHAR" />
|
||||
<result column="total_length" property="totalLength" jdbcType="VARCHAR" />
|
||||
<result column="flags" property="flags" jdbcType="VARCHAR" />
|
||||
<result column="fragment_offset" property="fragmentOffset" jdbcType="VARCHAR" />
|
||||
<result column="protocol" property="protocol" jdbcType="VARCHAR" />
|
||||
<result column="icmp_type" property="icmpType" jdbcType="VARCHAR" />
|
||||
<result column="icmp_code" property="icmpCode" jdbcType="VARCHAR" />
|
||||
<result column="icmp_identifier" property="icmpIdentifier" jdbcType="VARCHAR" />
|
||||
<result column="header_type" property="headerType" jdbcType="VARCHAR" />
|
||||
</resultMap>
|
||||
<!-- APP字符串类配置映射 -->
|
||||
<resultMap id="AppStringFeatureCfgMap" type="com.nis.domain.configuration.AppStringFeatureCfg" >
|
||||
@@ -191,7 +202,9 @@
|
||||
r.CREATOR_ID,r.CREATE_TIME,r.EDITOR_ID,r.EDIT_TIME,r.AUDITOR_ID,r.AUDIT_TIME,
|
||||
r.SERVICE_ID,r.REQUEST_ID,r.COMPILE_ID,r.IS_AREA_EFFECTIVE,r.CLASSIFY,
|
||||
r.ATTRIBUTE,r.LABLE,r.AREA_EFFECTIVE_IDS,r.FUNCTION_ID,r.CFG_TYPE,r.CFG_REGION_CODE,
|
||||
r.DISTRICT,r.CFG_KEYWORDS,r.EXPR_TYPE,r.MATCH_METHOD,r.IS_HEXBIN,r.DO_LOG
|
||||
r.DISTRICT,r.CFG_KEYWORDS,r.EXPR_TYPE,r.MATCH_METHOD,r.IS_HEXBIN,r.DO_LOG,
|
||||
r.ver,r.ihl,r.tos,r.total_length,r.flags,r.fragment_offset,r.protocol,r.icmp_type,r.icmp_code,r.icmp_identifier,
|
||||
r.header_type
|
||||
</sql>
|
||||
|
||||
<sql id="AppStringFeatureCfg_Column" >
|
||||
@@ -526,14 +539,18 @@
|
||||
CREATOR_ID,CREATE_TIME,EDITOR_ID,EDIT_TIME,AUDITOR_ID,AUDIT_TIME,
|
||||
SERVICE_ID,REQUEST_ID,COMPILE_ID,IS_AREA_EFFECTIVE,CLASSIFY,
|
||||
ATTRIBUTE,LABLE,AREA_EFFECTIVE_IDS,FUNCTION_ID,CFG_TYPE,CFG_REGION_CODE,
|
||||
DISTRICT,CFG_KEYWORDS,EXPR_TYPE,MATCH_METHOD,IS_HEXBIN,DO_LOG,user_region1,user_region2,user_region3,user_region4,user_region5
|
||||
DISTRICT,CFG_KEYWORDS,EXPR_TYPE,MATCH_METHOD,IS_HEXBIN,DO_LOG,user_region1,user_region2,user_region3,user_region4,user_region5,
|
||||
ver,ihl,tos,total_length,flags,fragment_offset,protocol,icmp_type,icmp_code,icmp_identifier,header_type
|
||||
)values (
|
||||
<include refid="AppCommonCfg_Value_List" />,
|
||||
#{cfgType,jdbcType=VARCHAR},#{cfgRegionCode,jdbcType=INTEGER},
|
||||
#{district,jdbcType=VARCHAR},#{cfgKeywords,jdbcType=VARCHAR},
|
||||
#{exprType,jdbcType=INTEGER},#{matchMethod,jdbcType=INTEGER},#{isHexbin,jdbcType=INTEGER},
|
||||
#{doLog,jdbcType=INTEGER},#{userRegion1,jdbcType=VARCHAR},#{userRegion2,jdbcType=VARCHAR},
|
||||
#{userRegion3,jdbcType=VARCHAR},#{userRegion4,jdbcType=VARCHAR},#{userRegion5,jdbcType=VARCHAR}
|
||||
#{userRegion3,jdbcType=VARCHAR},#{userRegion4,jdbcType=VARCHAR},#{userRegion5,jdbcType=VARCHAR},
|
||||
#{ver,jdbcType=VARCHAR},#{ihl,jdbcType=VARCHAR},#{tos,jdbcType=VARCHAR},#{totalLength,jdbcType=VARCHAR},
|
||||
#{flags,jdbcType=VARCHAR},#{fragmentOffset,jdbcType=VARCHAR},#{protocol,jdbcType=VARCHAR},#{icmpType,jdbcType=VARCHAR},
|
||||
#{icmpCode,jdbcType=VARCHAR},#{icmpIdentifier,jdbcType=VARCHAR},#{headerType,jdbcType=VARCHAR}
|
||||
)
|
||||
</insert>
|
||||
<!-- 新增APP字符串类特征子配置 -->
|
||||
|
||||
@@ -105,8 +105,51 @@ public class AppMultiFeatureCfgService extends BaseService {
|
||||
}
|
||||
if(entity.getComplexList()!=null){
|
||||
for(AppComplexFeatureCfg cfg:entity.getComplexList()){
|
||||
if(StringUtils.isNotBlank(cfg.getCfgKeywords())){
|
||||
if(StringUtils.isNotBlank(cfg.getDistrict()) && cfg.getDistrict().equals("L3_header")){
|
||||
BeanUtils.copyProperties(entity, cfg,new String[]{"cfgRegionCode","cfgType"});
|
||||
cfg.setIsHex(1);
|
||||
cfg.setIsCaseInsenstive(0);
|
||||
cfg.setExprType(0);
|
||||
String keyword = "";
|
||||
if(cfg.getHeaderType().equals("IP_header")){
|
||||
if(StringUtils.isNoneBlank(cfg.getVer())){
|
||||
keyword += "0-3:"+cfg.getVer()+"***and***";
|
||||
}
|
||||
if(StringUtils.isNotBlank(cfg.getIhl())){
|
||||
keyword += "4-7:"+cfg.getIhl()+"***and***";
|
||||
}
|
||||
if(StringUtils.isNotBlank(cfg.getTos())){
|
||||
keyword += "8-15:"+cfg.getTos()+"***and***";
|
||||
}
|
||||
if(StringUtils.isNotBlank(cfg.getTotalLength())){
|
||||
keyword += "16-31:"+cfg.getTotalLength()+"***and***";
|
||||
}
|
||||
if(StringUtils.isNotBlank(cfg.getFlags())){
|
||||
keyword += "48-50:"+cfg.getFlags()+"***and***";
|
||||
}
|
||||
if(StringUtils.isNotBlank(cfg.getFragmentOffset())){
|
||||
keyword += "56-63:"+cfg.getFragmentOffset()+"***and***";
|
||||
}
|
||||
if(StringUtils.isNotBlank(cfg.getProtocol())){
|
||||
keyword += "72-79:"+cfg.getProtocol()+"***and***";
|
||||
}
|
||||
}else{
|
||||
if(StringUtils.isNoneBlank(cfg.getIcmpType())){
|
||||
keyword += "0-7:"+cfg.getIcmpType()+"***and***";
|
||||
}
|
||||
if(StringUtils.isNotBlank(cfg.getIcmpCode())){
|
||||
keyword += "8-15:"+cfg.getIcmpCode()+"***and***";
|
||||
}
|
||||
if(StringUtils.isNotBlank(cfg.getIcmpIdentifier())){
|
||||
keyword += "32-47:"+cfg.getIcmpIdentifier()+"***and***";
|
||||
}
|
||||
}
|
||||
keyword=keyword.substring(0,keyword.lastIndexOf("***and***"));
|
||||
cfg.setCfgKeywords(keyword);
|
||||
appMultiFeatureCfgDao.insertAppComplexFeatureCfg(cfg);
|
||||
}else if(StringUtils.isNotBlank(cfg.getCfgKeywords())){
|
||||
BeanUtils.copyProperties(entity, cfg,new String[]{"cfgRegionCode","cfgType"});
|
||||
cfg.setHeaderType(null);
|
||||
appMultiFeatureCfgDao.insertAppComplexFeatureCfg(cfg);
|
||||
}
|
||||
|
||||
@@ -155,9 +198,52 @@ public class AppMultiFeatureCfgService extends BaseService {
|
||||
}
|
||||
if(entity.getComplexList()!=null){
|
||||
for(AppComplexFeatureCfg cfg:entity.getComplexList()){
|
||||
if(StringUtils.isNotBlank(cfg.getCfgKeywords())){
|
||||
BeanUtils.copyProperties(entity, cfg,new String[]{"cfgRegionCode","cfgType"});
|
||||
appMultiFeatureCfgDao.insertAppComplexFeatureCfg(cfg);
|
||||
if(StringUtils.isNotBlank(cfg.getDistrict()) && cfg.getDistrict().equals("L3_header")){
|
||||
BeanUtils.copyProperties(entity, cfg,new String[]{"cfgRegionCode","cfgType"});
|
||||
cfg.setIsHex(1);
|
||||
cfg.setIsCaseInsenstive(0);
|
||||
cfg.setExprType(0);
|
||||
String keyword = "";
|
||||
if(cfg.getHeaderType().equals("IP_header")){
|
||||
if(StringUtils.isNoneBlank(cfg.getVer())){
|
||||
keyword += "0-3:"+cfg.getVer()+"***and***";
|
||||
}
|
||||
if(StringUtils.isNotBlank(cfg.getIhl())){
|
||||
keyword += "4-7:"+cfg.getIhl()+"***and***";
|
||||
}
|
||||
if(StringUtils.isNotBlank(cfg.getTos())){
|
||||
keyword += "8-15:"+cfg.getTos()+"***and***";
|
||||
}
|
||||
if(StringUtils.isNotBlank(cfg.getTotalLength())){
|
||||
keyword += "16-31:"+cfg.getTotalLength()+"***and***";
|
||||
}
|
||||
if(StringUtils.isNotBlank(cfg.getFlags())){
|
||||
keyword += "48-50:"+cfg.getFlags()+"***and***";
|
||||
}
|
||||
if(StringUtils.isNotBlank(cfg.getFragmentOffset())){
|
||||
keyword += "56-63:"+cfg.getFragmentOffset()+"***and***";
|
||||
}
|
||||
if(StringUtils.isNotBlank(cfg.getProtocol())){
|
||||
keyword += "72-79:"+cfg.getProtocol()+"***and***";
|
||||
}
|
||||
}else{
|
||||
if(StringUtils.isNoneBlank(cfg.getIcmpType())){
|
||||
keyword += "0-7:"+cfg.getIcmpType()+"***and***";
|
||||
}
|
||||
if(StringUtils.isNotBlank(cfg.getIcmpCode())){
|
||||
keyword += "8-15:"+cfg.getIcmpCode()+"***and***";
|
||||
}
|
||||
if(StringUtils.isNotBlank(cfg.getIcmpIdentifier())){
|
||||
keyword += "32-47:"+cfg.getIcmpIdentifier()+"***and***";
|
||||
}
|
||||
}
|
||||
keyword=keyword.substring(0,keyword.lastIndexOf("***and***"));
|
||||
cfg.setCfgKeywords(keyword);
|
||||
appMultiFeatureCfgDao.insertAppComplexFeatureCfg(cfg);
|
||||
}else if(StringUtils.isNotBlank(cfg.getCfgKeywords())){
|
||||
BeanUtils.copyProperties(entity, cfg,new String[]{"cfgRegionCode","cfgType"});
|
||||
cfg.setHeaderType(null);
|
||||
appMultiFeatureCfgDao.insertAppComplexFeatureCfg(cfg);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1409,4 +1409,8 @@ desc=Desc
|
||||
unique_num=Unique
|
||||
import_limit_is=The maximum import size is
|
||||
upload_limit_is=The limitation of file uplaod is
|
||||
count=Count
|
||||
count=Count
|
||||
do_blacklist=Blacklist Option
|
||||
l3_header_error=Only four attribute values are allowed to be entered at most
|
||||
IP_HEADER=IP Header
|
||||
ICMP_HEADER=ICMP Header
|
||||
@@ -1413,4 +1413,8 @@ desc=Desc
|
||||
unique_num=Unique
|
||||
import_limit_is=The maximum import size is
|
||||
upload_limit_is=The limitation of file uplaod is
|
||||
count=Count
|
||||
count=Count
|
||||
do_blacklist=Blacklist Option
|
||||
l3_header_error=Only four attribute values are allowed to be entered at most
|
||||
IP_HEADER=IP Header
|
||||
ICMP_HEADER=ICMP Header
|
||||
@@ -1409,4 +1409,8 @@ desc=Desc
|
||||
unique_num=Unique
|
||||
import_limit_is=\u5BFC\u5165\u9650\u5236\u6700\u5927\u6761\u6570
|
||||
upload_limit_is=\u6587\u4EF6\u4E0A\u4F20\u4E2A\u6570\u9650\u5236
|
||||
count=\u6570\u91CF
|
||||
count=\u6570\u91CF
|
||||
do_blacklist=Blacklist Option
|
||||
l3_header_error=Only four attribute values are allowed to be entered at most
|
||||
IP_HEADER=IP Header
|
||||
ICMP_HEADER=ICMP Header
|
||||
11
src/main/resources/sql/20181222/add_app_feature_column
Normal file
11
src/main/resources/sql/20181222/add_app_feature_column
Normal file
@@ -0,0 +1,11 @@
|
||||
ALTER TABLE `app_complex_feature_cfg` ADD COLUMN `header_type` varchar(16) NULL DEFAULT '' AFTER `user_region5`;
|
||||
ALTER TABLE `app_complex_feature_cfg` ADD COLUMN `ver` varchar(4) NULL DEFAULT '' AFTER `header_type`;
|
||||
ALTER TABLE `app_complex_feature_cfg` ADD COLUMN `ihl` varchar(4) NULL DEFAULT '' AFTER `ver`;
|
||||
ALTER TABLE `app_complex_feature_cfg` ADD COLUMN `tos` varchar(8) NULL DEFAULT '' AFTER `ihl`;
|
||||
ALTER TABLE `app_complex_feature_cfg` ADD COLUMN `total_length` varchar(16) NULL DEFAULT '' AFTER `tos`;
|
||||
ALTER TABLE `app_complex_feature_cfg` ADD COLUMN `flags` varchar(3) NULL DEFAULT '' AFTER `total_length`;
|
||||
ALTER TABLE `app_complex_feature_cfg` ADD COLUMN `fragment_offset` varchar(8) NULL DEFAULT '' AFTER `flags`;
|
||||
ALTER TABLE `app_complex_feature_cfg` ADD COLUMN `protocol` varchar(8) NULL DEFAULT '' AFTER `fragment_offset`;
|
||||
ALTER TABLE `app_complex_feature_cfg` ADD COLUMN `icmp_type` varchar(8) NULL DEFAULT '' AFTER `protocol`;
|
||||
ALTER TABLE `app_complex_feature_cfg` ADD COLUMN `icmp_code` varchar(8) NULL DEFAULT '' AFTER `icmp_type`;
|
||||
ALTER TABLE `app_complex_feature_cfg` ADD COLUMN `icmp_identifier` varchar(16) NULL DEFAULT '' AFTER `icmp_code`;
|
||||
@@ -8,6 +8,41 @@ $(function(){
|
||||
$(".action").on("change", function() {
|
||||
$("#serviceId").val($(this).attr("serviceId"));
|
||||
});
|
||||
$(".district").on("change", function() {
|
||||
if($(this).val()=='L3_header'){
|
||||
$(this).parents(".boxSolid").find(".keywords").addClass("hidden");
|
||||
$(this).parents(".boxSolid").find(".L3_header").removeClass("hidden");
|
||||
$(this).parents(".boxSolid").find(".matchMethod").addClass("hidden");
|
||||
$(this).parents(".boxSolid").find(".exprType").addClass("hidden");
|
||||
$(this).parents(".boxSolid").find("input:radio[name$='isHex'][value=1]").prop("checked",true);
|
||||
$(this).parents(".boxSolid").find("input:radio[name$='isCaseSenstive'][value=0]").prop("checked",true);
|
||||
$(this).parents(".boxSolid").find("input:radio[name$='isHex']").attr("disabled",true);
|
||||
$(this).parents(".boxSolid").find("input:radio[name$='isCaseSenstive']").attr("disabled",true);
|
||||
$(this).parents(".boxSolid").find(".headerType").change();
|
||||
}else{
|
||||
$(this).parents(".boxSolid").find(".keywords").removeClass("hidden");
|
||||
$(this).parents(".boxSolid").find(".L3_header").addClass("hidden");
|
||||
$(this).parents(".boxSolid").find(".matchMethod").removeClass("hidden");
|
||||
$(this).parents(".boxSolid").find(".exprType").removeClass("hidden");
|
||||
$(this).parents(".boxSolid").find(".IP_header").addClass("hidden");
|
||||
$(this).parents(".boxSolid").find(".ICMP_header").addClass("hidden");
|
||||
$(this).parents(".boxSolid").find("input:radio[name$='isHex']").attr("disabled",false);
|
||||
$(this).parents(".boxSolid").find("input:radio[name$='isCaseSenstive']").attr("disabled",false);
|
||||
}
|
||||
});
|
||||
|
||||
$(".headerType").on("change", function() {
|
||||
if($(this).val()=='IP_header'){
|
||||
$(this).parents(".boxSolid").find(".ICMP_header").addClass("hidden");
|
||||
$(this).parents(".boxSolid").find(".IP_header").removeClass("hidden");
|
||||
}else{
|
||||
$(this).parents(".boxSolid").find(".IP_header").addClass("hidden");
|
||||
$(this).parents(".boxSolid").find(".ICMP_header").removeClass("hidden");
|
||||
}
|
||||
});
|
||||
$(".boxSolid:visible").find(".district").each(function(){
|
||||
$(this).change();
|
||||
});
|
||||
$("#serviceId").val($(".action:checked").attr("serviceId"));
|
||||
$("#cfgFrom").validate({
|
||||
errorPlacement: function(error,element){
|
||||
@@ -25,21 +60,35 @@ $(function(){
|
||||
return;
|
||||
}
|
||||
$(".boxSolid:visible").find("input[name$='cfgKeywords']").each(function(){
|
||||
|
||||
if($(this).val()==''){
|
||||
$(this).parents(".form-group").find(
|
||||
"div[for='"
|
||||
+ $(this).attr("name")
|
||||
+ "']").html("<label id=\"cfgKeywordsError\" class=\"error\">"+$("#keywordError").text()+"</label>");
|
||||
flag = false;
|
||||
var length = 0;
|
||||
$(this).parents(".boxSolid").find(".l3_header_prop").each(function(){
|
||||
if($(this).val()!=''){
|
||||
length += 1;
|
||||
}
|
||||
})
|
||||
if(length==0){
|
||||
$(this).parents(".form-group").find(
|
||||
"div[for='"
|
||||
+ $(this).attr("name")
|
||||
+ "']").html("<label id=\"cfgKeywordsError\" class=\"error\">"+$("#keywordError").text()+"</label>");
|
||||
flag = false;
|
||||
}else if(length>4){
|
||||
$(this).parents(".boxSolid").find(
|
||||
"div[class='l3_header_tips']").html("<label id=\"l3_header_error\" class=\"error\">"+$("#l3_header_error").text()+"</label>");
|
||||
flag = false;
|
||||
}
|
||||
|
||||
}
|
||||
})
|
||||
});
|
||||
//keywords非空校验完成校验二进制字符串
|
||||
$(".boxSolid:visible").find("select[name$='isHexbin']").each(function(){
|
||||
var isHexbin=$(this).val();
|
||||
if(isHexbin == 1){ //十六进制
|
||||
var keywords=$("input[name$='"+$(this).attr("name").replace("isHexbin","cfgKeywords")+"']").val();
|
||||
keywords=keywords.replace("***and***","")
|
||||
if(keywords != ''){
|
||||
keywords=keywords.replace("***and***","");
|
||||
if(keywords != ''){
|
||||
if(!(/^([0-9|a-f|A-F]*)$/.test(keywords))){
|
||||
$(this).parents(".boxSolid").find(
|
||||
"div[for='"
|
||||
@@ -109,6 +158,8 @@ var delContent = function(contentClassName, addBtnClassName) {
|
||||
code="required"></spring:message></span>
|
||||
<span id="tagsinputTip" style="display:none"><spring:message
|
||||
code="multiple_keywords_tip"></spring:message></span>
|
||||
<span id="l3_header_error" style="display:none"><spring:message
|
||||
code="l3_header_error"></spring:message></span>
|
||||
<div class="page-content">
|
||||
<c:forEach items="${serviceList}" var="service">
|
||||
<c:if test="${cfg.functionId eq service.functionId}">
|
||||
@@ -143,6 +194,7 @@ var delContent = function(contentClassName, addBtnClassName) {
|
||||
<input type="hidden" id="appCode" name="appCode" value="${_cfg.appCode}">
|
||||
<input type="hidden" id="behavCode" name="behavCode" value="${_cfg.behavCode}">
|
||||
<input type="hidden" id="doLog" name="doLog" value="2">
|
||||
<c:set var="serviceId" value="${_cfg.serviceId}" />
|
||||
<!-- 配置域类型 -->
|
||||
<div class="form-body">
|
||||
<div class="row">
|
||||
@@ -191,6 +243,7 @@ var delContent = function(contentClassName, addBtnClassName) {
|
||||
<spring:message code="${dict.itemValue }" />
|
||||
</c:if>
|
||||
</c:forEach>
|
||||
<c:set var="serviceId" value="${service.serviceId}" />
|
||||
</c:if>
|
||||
</label>
|
||||
</c:forEach>
|
||||
|
||||
@@ -256,13 +256,89 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-8">
|
||||
<div class="form-group">
|
||||
<label class="keyword-disinline"><spring:message code='keywords' />: ${fn:replace(cfg.cfgKeywords, "***and***", " ")}</label>
|
||||
<c:if test="${cfg.serviceId eq 1025 }">
|
||||
<c:if test="${cfg.headerType eq 'IP_header' }">
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='VER' />: ${cfg.ver}</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='IHL' />: ${cfg.ihl}</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='TOS' />: ${cfg.tos}</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='Total Length' />: ${cfg.totalLength}</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='Flags' />: ${cfg.flags}</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='fragment offset' />: ${cfg.fragmentOffset}</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='Protocol' />: ${cfg.protocol}</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</c:if>
|
||||
<c:if test="${cfg.headerType eq 'ICMP_header' }">
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='ICMP type' />: ${cfg.icmpType}</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='ICMP code' />: ${cfg.icmpCode}</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='ICMP identifier' />: ${cfg.icmpIdentifier}</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</c:if>
|
||||
<c:if test="${empty cfg.headerType}">
|
||||
<div class="row">
|
||||
<div class="col-md-8">
|
||||
<div class="form-group">
|
||||
<label class="keyword-disinline"><spring:message code='keywords' />: ${fn:replace(cfg.cfgKeywords, "***and***", " ")}</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</c:if>
|
||||
</c:if>
|
||||
<c:if test="${cfg.serviceId ne 1025 }">
|
||||
<div class="row">
|
||||
<div class="col-md-8">
|
||||
<div class="form-group">
|
||||
<label class="keyword-disinline"><spring:message code='keywords' />: ${fn:replace(cfg.cfgKeywords, "***and***", " ")}</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</c:if>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-8">
|
||||
<div class="form-group">
|
||||
|
||||
@@ -49,7 +49,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</c:if>
|
||||
<div class="row">
|
||||
<div class="row keywords">
|
||||
<c:if test="${isP2pHashCfg}">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
@@ -108,8 +108,127 @@
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="row">
|
||||
<c:if test="${serviceId eq 1025}">
|
||||
<div class="row L3_header hidden">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><spring:message code="headerType"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="${cfgName}.headerType" class="selectpicker show-tick form-control headerType">
|
||||
<option value="IP_header" <c:if test="${cfg.headerType eq 'IP_header'}">selected</c:if> ><spring:message code="IP_HEADER"/></option>
|
||||
<option value="ICMP_header" <c:if test="${cfg.headerType eq 'ICMP_header'}">selected</c:if> ><spring:message code="ICMP_HEADER"/></option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="l3_header_tips"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row IP_header hidden">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><spring:message code="VER" /> </label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control l3_header_prop hexCheck" minlength="4" maxlength="4" type="text" name="${cfgName}.ver" value="${cfg.ver}"><font color="red">4 bit</font>
|
||||
</div>
|
||||
<div for="${cfgName}.ver"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><spring:message code="IHL" /> </label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control l3_header_prop hexCheck" minlength="4" maxlength="4" type="text" name="${cfgName}.ihl" value="${cfg.ihl}"><font color="red">4 bit</font>
|
||||
</div>
|
||||
<div for="${cfgName}.ihl"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row IP_header hidden">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><spring:message code="TOS" /> </label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control l3_header_prop hexCheck" minlength="8" maxlength="8" type="text" name="${cfgName}.tos" value="${cfg.tos}"><font color="red">8 bit</font>
|
||||
</div>
|
||||
<div for="${cfgName}.tos"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><spring:message code="Total Length" /> </label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control l3_header_prop hexCheck" minlength="16" maxlength="16" type="text" name="${cfgName}.totalLength" value="${cfg.totalLength}"><font color="red">16 bit</font>
|
||||
</div>
|
||||
<div for="${cfgName}.totalLength"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row IP_header hidden">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><spring:message code="Flags" /> </label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control l3_header_prop hexCheck" minlength="3" maxlength="3" type="text" name="${cfgName}.flags" value="${cfg.flags}"><font color="red">3 bit</font>
|
||||
</div>
|
||||
<div for="${cfgName}.flags"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><spring:message code="fragment offset" /> </label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control l3_header_prop hexCheck" minlength="8" maxlength="8" type="text" name="${cfgName}.fragmentOffset" value="${cfg.fragmentOffset}"><font color="red">8 bit</font>
|
||||
</div>
|
||||
<div for="${cfgName}.fragmentOffset"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row IP_header hidden">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><spring:message code="Protocol" /> </label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control l3_header_prop hexCheck" minlength="8" maxlength="8" type="text" name="${cfgName}.protocol" value="${cfg.protocol}"><font color="red">8 bit</font>
|
||||
</div>
|
||||
<div for="${cfgName}.protocol"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row ICMP_header hidden">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><spring:message code="ICMP type" /> </label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control l3_header_prop hexCheck" minlength="8" maxlength="8" type="text" name="${cfgName}.icmpType" value="${cfg.icmpType}"><font color="red">8 bit</font>
|
||||
</div>
|
||||
<div for="${cfgName}.icmpType"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><spring:message code="ICMP code" /> </label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control l3_header_prop hexCheck" minlength="8" maxlength="8" type="text" name="${cfgName}.icmpCode" value="${cfg.icmpCode}"><font color="red">8 bit</font>
|
||||
</div>
|
||||
<div for="${cfgName}.icmpCode"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row ICMP_header hidden">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><spring:message code="ICMP identifier" /> </label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control l3_header_prop" minlength="16" maxlength="16" type="text" name="${cfgName}.icmpIdentifier" value="${cfg.icmpIdentifier}"><font color="red">16 bit</font>
|
||||
</div>
|
||||
<div for="${cfgName}.icmpIdentifier"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</c:if>
|
||||
<div class="row">
|
||||
<div class="col-md-6 exprType">
|
||||
<div class="form-group">
|
||||
|
||||
<label class="control-label col-md-3"><font color="red">*</font>
|
||||
@@ -152,13 +271,13 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md-6">
|
||||
<div class="col-md-6 matchMethod">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font>
|
||||
<spring:message code="match_method" /></label>
|
||||
<div class="col-md-6">
|
||||
<select name="${cfgName}.matchMethod"
|
||||
class="selectpicker select2 form-control required">
|
||||
class="selectpicker select2 form-control required ">
|
||||
<c:if test="${!empty region.configMatchMethod}">
|
||||
<c:forEach var="matchMethod" items="${fn:split(region.configMatchMethod,',')}">
|
||||
<c:forEach items="${fns:getDictList('MATCH_METHOD')}" var="matchMethodC">
|
||||
|
||||
Reference in New Issue
Block a user