MCPcopy Create free account

hub / github.com/AdaLogics/go-fuzz-headers / functions

Functions60 in github.com/AdaLogics/go-fuzz-headers

↓ 20 callersMethodGetInt
()
consumer.go:367
↓ 13 callersMethodGetString
()
consumer.go:484
↓ 9 callersMethodGetBool
()
consumer.go:513
↓ 8 callersFunctionNewConsumer
(fuzzData []byte)
consumer.go:60
↓ 6 callersMethodGetUint32
()
consumer.go:415
↓ 6 callersMethodUint64
()
bytesource/bytesource.go:41
↓ 5 callersMethodGetBytes
()
consumer.go:455
↓ 5 callersMethodGetNBytes
(numberOfBytes int)
consumer.go:385
↓ 2 callersMethodGenerateStruct
(targetStruct interface{})
consumer.go:116
↓ 2 callersMethodGenerateStruct
(targetStruct interface{})
funcs.go:56
↓ 2 callersMethodGetByte
()
consumer.go:376
↓ 2 callersMethodGetSQLString
GetSQLString is the API that users interact with. Usage: f := NewConsumer(data) sqlString, err := f.GetSQLString()
sql.go:538
↓ 2 callersFunctionIsDivisibleBy
(n int, divisibleby int)
consumer.go:56
↓ 2 callersMethodconsumeUint64
consumeUint64 reads 8 bytes from the input and convert them to a uint64. It assumes that the the bytes reader is not empty.
bytesource/bytesource.go:67
↓ 2 callersFunctioncontainsString
Simple utility function to check if a string slice contains a string.
sql.go:38
↓ 2 callersMethodcreateTarFileBody
()
consumer.go:616
↓ 2 callersMethodfuzzStruct
(e reflect.Value, customFunctions bool)
consumer.go:158
↓ 2 callersMethodgetTarFilename
getTarFileName is similar to GetString(), but creates string based on the length of f.data to reduce the likelihood of overflowing f.data.
consumer.go:652
↓ 2 callersFunctionsetTarHeaderFormat
(hdr *tar.Header, f *ConsumeFuzzer)
consumer.go:551
↓ 2 callersFunctionsetTarHeaderTypeflag
(hdr *tar.Header, f *ConsumeFuzzer)
consumer.go:570
↓ 1 callersMethodGenerateWithCustom
(targetStruct interface{})
funcs.go:51
↓ 1 callersMethodGetFloat32
()
consumer.go:924
↓ 1 callersMethodGetFloat64
()
consumer.go:941
↓ 1 callersMethodGetUint
()
consumer.go:438
↓ 1 callersMethodGetUint16
()
consumer.go:400
↓ 1 callersMethodGetUint64
()
consumer.go:423
↓ 1 callersMethodInt63
()
bytesource/bytesource.go:56
↓ 1 callersFunctionchooseToken
(tokens []string, f *ConsumeFuzzer)
sql.go:345
↓ 1 callersFunctioncreateAlterTableStmt
Creates an 'alter table' statement. 'alter table' is an exception in that it has its own function. The majority of statements are created by 'createSt
sql.go:310
↓ 1 callersFunctioncreateQuery
Creates a semi-structured query. It creates a string that is a combination of the keywords and random strings.
sql.go:496
↓ 1 callersFunctioncreateStmt
(f *ConsumeFuzzer)
sql.go:401
↓ 1 callersFunctioncreateStmtArgs
Creates the arguments of a statements. In a select statement that would be everything after "select".
sql.go:439
↓ 1 callersFunctiongetKeyword
returns a keyword by index
sql.go:23
↓ 1 callersMethodsetCustom
(v reflect.Value)
consumer.go:121
MethodAddFuncs
(fuzzFuncs []interface{})
funcs.go:26
MethodAllowNonUTF8Strings
()
consumer.go:108
MethodAllowUnexportedFields
()
consumer.go:100
MethodCreateFiles
CreateFiles creates pseudo-random files in rootDir. It creates subdirs and places the files there. It is the callers responsibility to ensure that roo
consumer.go:815
MethodCreateSlice
(targetSlice interface{})
consumer.go:958
MethodDisallowNonUTF8Strings
()
consumer.go:112
MethodDisallowUnexportedFields
()
consumer.go:104
MethodFuzzMap
(m interface{})
consumer.go:526
MethodGenerateStructWithCustom
(targetStruct interface{})
funcs.go:60
MethodGetRune
()
consumer.go:916
MethodGetStringArray
()
consumer.go:341
MethodGetStringFrom
GetStringFrom returns a string that can only consist of characters included in possibleChars. It returns an error if the created string does not have
consumer.go:901
FunctionNew
New returns a new ByteSource from a given slice of bytes.
bytesource/bytesource.go:30
MethodSeed
(seed int64)
bytesource/bytesource.go:60
FunctionSetMaxTotalLen
(newLen uint32)
consumer.go:39
MethodSplit
(minCalls, maxCalls int)
consumer.go:69
MethodTarBytes
TarBytes returns valid bytes for a tar archive
consumer.go:688
MethodTarFiles
This is similar to TarBytes, but it returns a series of files instead of raw tar bytes. The advantage of this api is that it is cheaper in terms of cp
consumer.go:762
FunctionTestGeBytes1
(t *testing.T)
consumer_test.go:151
FunctionTestGeBytes2
(t *testing.T)
consumer_test.go:177
FunctionTestGeBytes3
(t *testing.T)
consumer_test.go:203
FunctionTestGetUint32
*func TestTarBytes(t *testing.T) { data := []byte{ 0x01, // number of files 0x00, 0x00, 0x00, 0x08, // Length of first file nam
consumer_test.go:134
FunctionTestSQLAPI
(t *testing.T)
sql_test.go:21
FunctionTestStruct_fuzzing1
(t *testing.T)
consumer_test.go:30
FunctionTestStruct_fuzzing2
Tests that we can create long byte slices in structs
consumer_test.go:58
FunctionreturnTarBytes
(buf []byte)
consumer.go:530