mirror of https://github.com/daffainfo/nuclei.git
Misc linter related changes
parent
a60b10afca
commit
53164c3f3e
|
@ -63,8 +63,8 @@ type AttackTypeHolder struct {
|
|||
func (holder AttackTypeHolder) JSONSchemaType() *jsonschema.Type {
|
||||
gotType := &jsonschema.Type{
|
||||
Type: "string",
|
||||
Title: "type of the protocol",
|
||||
Description: "Type of the protocol",
|
||||
Title: "type of the attack",
|
||||
Description: "Type of the attack",
|
||||
}
|
||||
for _, types := range GetSupportedAttackTypes() {
|
||||
gotType.Enum = append(gotType.Enum, types.String())
|
||||
|
|
|
@ -134,7 +134,7 @@ func TestMakeRequestFromRawWithPayloads(t *testing.T) {
|
|||
"username": []string{"admin"},
|
||||
"password": []string{"admin", "guest", "password", "test", "12345", "123456"},
|
||||
},
|
||||
AttackType: generators.AttackTypeHolder{generators.ClusterbombAttack},
|
||||
AttackType: generators.AttackTypeHolder{Value: generators.ClusterbombAttack},
|
||||
Raw: []string{`GET /manager/html HTTP/1.1
|
||||
Host: {{Hostname}}
|
||||
User-Agent: Nuclei - Open-source project (github.com/projectdiscovery/nuclei)
|
||||
|
@ -173,7 +173,7 @@ func TestMakeRequestFromRawPayloadExpressions(t *testing.T) {
|
|||
"username": []string{"admin"},
|
||||
"password": []string{"admin", "guest", "password", "test", "12345", "123456"},
|
||||
},
|
||||
AttackType: generators.AttackTypeHolder{generators.ClusterbombAttack},
|
||||
AttackType: generators.AttackTypeHolder{Value: generators.ClusterbombAttack},
|
||||
Raw: []string{`GET /manager/html HTTP/1.1
|
||||
Host: {{Hostname}}
|
||||
User-Agent: Nuclei - Open-source project (github.com/projectdiscovery/nuclei)
|
||||
|
|
|
@ -23,7 +23,7 @@ func TestHTTPCompile(t *testing.T) {
|
|||
"username": []string{"admin"},
|
||||
"password": []string{"admin", "guest", "password", "test", "12345", "123456"},
|
||||
},
|
||||
AttackType: generators.AttackTypeHolder{generators.ClusterbombAttack},
|
||||
AttackType: generators.AttackTypeHolder{Value: generators.ClusterbombAttack},
|
||||
Raw: []string{`GET /manager/html HTTP/1.1
|
||||
Host: {{Hostname}}
|
||||
User-Agent: Nuclei - Open-source project (github.com/projectdiscovery/nuclei)
|
||||
|
|
|
@ -29,7 +29,7 @@ func TestRequestGeneratorClusterBombSingle(t *testing.T) {
|
|||
|
||||
req := &Request{
|
||||
Payloads: map[string]interface{}{"username": []string{"admin", "tomcat", "manager"}, "password": []string{"password", "test", "secret"}},
|
||||
AttackType: generators.AttackTypeHolder{generators.ClusterbombAttack},
|
||||
AttackType: generators.AttackTypeHolder{Value: generators.ClusterbombAttack},
|
||||
Raw: []string{`GET /{{username}}:{{password}} HTTP/1.1`},
|
||||
}
|
||||
catalogInstance := catalog.New("")
|
||||
|
@ -53,7 +53,7 @@ func TestRequestGeneratorClusterBombMultipleRaw(t *testing.T) {
|
|||
|
||||
req := &Request{
|
||||
Payloads: map[string]interface{}{"username": []string{"admin", "tomcat", "manager"}, "password": []string{"password", "test", "secret"}},
|
||||
AttackType: generators.AttackTypeHolder{generators.ClusterbombAttack},
|
||||
AttackType: generators.AttackTypeHolder{Value: generators.ClusterbombAttack},
|
||||
Raw: []string{`GET /{{username}}:{{password}} HTTP/1.1`, `GET /{{username}}@{{password}} HTTP/1.1`},
|
||||
}
|
||||
catalogInstance := catalog.New("")
|
||||
|
|
Loading…
Reference in New Issue