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

It never returns error on my machine #7

Closed
hellodword opened this issue Aug 22, 2022 · 0 comments
Closed

It never returns error on my machine #7

hellodword opened this issue Aug 22, 2022 · 0 comments

Comments

@hellodword
Copy link

	err := ipset.Init()
	if err != nil {
		panic(err)
	}

	err = ipset.Create("scanner-ip-set")
	if err != nil {
		panic(err)
	}
$ ipset --version
ipset v7.15, protocol version: 7

$ uname -r
5.15.0-46-generic

$ go build -o test .

# not panic without capabilities
$ ./test

# create the set
$ sudo ipset create scanner-ip-set hash:ip

# create the set again via cli
$ sudo ipset create scanner-ip-set hash:ip
ipset v7.15: Set cannot be created: set with the same name already exists

# not panic
$ sudo ./test

Any idea about this?

Thank you!

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

1 participant