package
0.0.0-20240704015121-d68ab2b17a03
Repository: https://github.com/ghosttroops/go-utils.git
Documentation: pkg.go.dev
# Functions
从szIndexs拷贝到szIndexd.
form index copy to other index.
No description provided by the author
No description provided by the author
创建 Handle.
创建索引
curl 'https://127.0.0.1:8081/api/classInfo' \
-X 'PUT' \
-H 'Accept: application/json, text/plain' \
-H 'Content-Type: application/json;charset=utf-8' \
-H 'Origin: https://127.0.0.1:8081' \
-H 'Cookie: 51pwn4ssh=s%3AEIw15tP5XD_wvn7cnc5E9I0OD8LbDODZ.ffjTn31urO8WPINViwiLu62SpuywsXZltTj4kMA7PGI; ss=MTY2NzA1MDc4MHxEdi1CQkFFQ180SUFBUkFCRUFBQV9nRTNfNElBQVFaemRISnBibWNNQndBRmRHOXJaVzRHYzNSeWFXNW5EUDRCR0FELUFSUmxlVXBvWWtkamFVOXBTa2xWZWswMFRrTkpjMGx1VWpWalEwazJTV3R3V0ZaRFNqa3VaWGxLZWxwWFZtdEphbTlwVGxSVk1FNVVhM2xOUkZFMFRrUm5OVTFFUVhkT1JGVXpUbmxKYzBsdFJqRmFRMGsyU1cxR2EySlhiSFZKYVhkcFdsaG9kMGxxYjNoT2Fsa3pUVlJOTTAxVVozZE1RMHB4WkVkcmFVOXBTWGhKYVhkcFlWZEdNRWxxYjNoT2Fsa3pUVVJWZDA1NlozZE1RMHB3WXpOTmFVOXBTVEZOV0VJelltazFhbUl5TUdsTVEwcDZaRmRKYVU5cFNURk5XRUl6WW10Qk1VMVlRak5pYVRWcVlqSXdhV1pSTGtkdVlsbzBObUpVZGtvNWNGYzJiVEEwUlVvelUwcDRWVEZEWVZsSlRGUmZaVEJCZGtaR1psUk5RV04wWHpoZk5rOW5VVk5NUmxjMmNVRm5TMHBCWXpNPXyHSm4pk58Q6_JDEPGEOjRB1PzKrMn3GOeChY_Zs17IRA==; mysession=MTY2NzA0OTkyNnxEdi1CQkFFQ180SUFBUkFCRUFBQV9nRTNfNElBQVFaemRISnBibWNNQndBRmRHOXJaVzRHYzNSeWFXNW5EUDRCR0FELUFSUmxlVXBvWWtkamFVOXBTa2xWZWswMFRrTkpjMGx1VWpWalEwazJTV3R3V0ZaRFNqa3VaWGxLZWxwWFZtdEphbTlwVDBSSk1VMUVUVEpOVkZrMVQxUk5OVTlFUlhwUFJGRjNUbE5KYzBsdFJqRmFRMGsyU1cxR2EySlhiSFZKYVhkcFdsaG9kMGxxYjNoT2Fsa3pUVlJOTWsxNlNUSk1RMHB4WkVkcmFVOXBTWGhKYVhkcFlWZEdNRWxxYjNoT2Fsa3pUVVJSTlU5VVNUSk1RMHB3WXpOTmFVOXBTVEZOV0VJelltazFhbUl5TUdsTVEwcDZaRmRKYVU5cFNURk5XRUl6WW10Qk1VMVlRak5pYVRWcVlqSXdhV1pSTG01NGVubG5XRXBETVVseWJWWTVSRmN3YUZkc1Yzb3dhVFk1VERkWmIxQkJTbnBUY1ROR1VUQmFSM2RwV0RCMWIwdElRVE54TkZCUk1ERlBabXhtU2pJPXwPXOhkJ6Qdcuvofa8lFQxCof8fKUP0pfJ2OpoIexbGiw==' \
-H 'Content-Length: 273' \
-H 'Host: 127.0.0.1:8081' \
-H 'User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/16.1 Safari/605.1.15' \
-H 'Referer: https://127.0.0.1:8081/indexes/_new' \
--data-binary '{"default_mapping":{"enabled":true,"display_order":"0"},"type_field":"_type","default_type":"_default","default_analyzer":"standard","default_datetime_parser":"dateTimeOptional","default_field":"_all","byte_array_converter":"json","store_dynamic":true,"index_dynamic":true}'
*/.
No description provided by the author
No description provided by the author
索引数据处理.
删除匹配条件,且回调返回true的数据
blevExp.Delete4Query(blevExp.DefaulIndexName, "type:uncover", func(m *search.DocumentMatch) bool {
return -1 < strings.Index(m.ID, "float") || -1 == strings.Index(m.ID, "uncover")
})
go blevExp.Delete4Query(blevExp.DefaulIndexName, "tools:nuclei", func(match *search.DocumentMatch) bool {
return true
})
*/.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
初始化搜索引擎.
No description provided by the author
在所有索引中查询 id.
在所有索引中查询 url ,内部会将url进行 sha1编码作为id进行查询.
No description provided by the author
查询指定索引、指定id的 doc.
获取body中的图片,并返回base64的编码.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
初始化索引库.
从szIndex 移动 到 szIndexd.
解析额日期.
No description provided by the author
if x := pkg.Query4Key("sploitus", "RCE"); nil != x {
log.Println(x)
}
IncludeLocations 用于设置是否包含位置信息在搜索结果中。如果设置为 true,搜索结果中会包含每个结果的位置信息。如果设置为 false,搜索结果中将不包含位置信息。
的Explain属性是一个布尔类型,表示是否需要为每条搜索结果返回其匹配原因。当该值为true时,搜索结果会包含一个详细的分析,说明每条结果为什么被认为与查询匹配。这对于理解查询和调试查询非常有用。
{"size":10,"from":0,"explain":true,"highlight":{},"query":{"boost":1,"query":"WebLogicFilterConfig"},"fields":["*"]}
*/.
No description provided by the author
Explain属性是一个布尔类型,表示是否需要为每条搜索结果返回其匹配原因。当该值为true时,搜索结果会包含一个详细的分析,说明每条结果为什么被认为与查询匹配。这对于理解查询和调试查询非常有用。 IncludeLocations 用于设置是否包含位置信息在搜索结果中。如果设置为 true,搜索结果中会包含每个结果的位置信息。如果设置为 false,搜索结果中将不包含位置信息。.
No description provided by the author
保存爬到到文章
坑:json的strutc首字母必须大写,且设置json.
并发 默认 16,thread 配置,fnCbk 在成功保存.
批量保存,并发限制16.
No description provided by the author
No description provided by the author
# Variables
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
var DataDir = flag.String("DataDir", "/Volumes/Home/data", "data directory").
No description provided by the author
# Structs
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
# Interfaces
No description provided by the author