Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GoFlow segfaults with bad input #118

Open
shruthij28 opened this issue Feb 21, 2023 · 3 comments
Open

GoFlow segfaults with bad input #118

shruthij28 opened this issue Feb 21, 2023 · 3 comments

Comments

@shruthij28
Copy link

I was trying to run goflow to capture netflow data and push into Kafka, but I've been running into a segfault:

panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x0 pc=0x7d139e]

goroutine 26 [running]:
github.com/cloudflare/goflow/v3/utils.UDPRoutine({0x930fa4, 0x7}, 0xc00009e4e0, 0x1, {0x7fffb2e366be, 0x9}, 0x807, 0x0, {0x9e8e38, 0xc00019c000})
	/home/ubuntu/goflow-3.4.4/utils/utils.go:291 +0x75e
github.com/cloudflare/goflow/v3/utils.(*StateNetFlow).FlowRoutine(0xc000074c00, 0x4?, {0x7fffb2e366be, 0x9}, 0xc00020ae70?, 0x0?)
	/home/ubuntu/goflow-3.4.4/utils/netflow.go:358 +0x176
main.main.func2()
	/home/ubuntu/goflow-3.4.4/cmd/goflow/goflow.go:134 +0x1b9
created by main.main
	/home/ubuntu/goflow-3.4.4/cmd/goflow/goflow.go:129 +0x6ad

I've noticed that this is happening when I pass in a value for -nf.port that is already in use; however, I believe that the code should return some sort of error message here instead of just segfaulting.

@taktv6
Copy link
Contributor

taktv6 commented Feb 22, 2023

Hi, this issue is fixed in the master branch. I'll try to file a new release asap.

@gaby
Copy link

gaby commented Apr 28, 2023

@taktv6 Any chance of getting a new release and updated dependencies?

Thanks!

@gaby
Copy link

gaby commented May 8, 2023

@taktv6 Any update on this, we currently can't run goflow without doing a clone, and building locally using master. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants