Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Fixes support for OpenBSD (6.1+)#282

Merged
brianmay merged 2 commits into
sshuttle:masterfrom
vieira:openbsd-63-fixes
Oct 22, 2018
Merged

Fixes support for OpenBSD (6.1+)#282
brianmay merged 2 commits into
sshuttle:masterfrom
vieira:openbsd-63-fixes

Conversation

@vieira
Copy link
Copy Markdown
Contributor

@vieira vieira commented Oct 21, 2018

New versions of OpenBSD ship with a different pfioc_rule struct. This commit adjusts the offset to match the new struct.

Should fix #219.

For reference, used the following C program to compute the new size.

#include <stdio.h>
#include <sys/types.h>
#include <sys/socket.h>
#include <net/if.h>
#include <net/pfvar.h>

int main() {
        int size = sizeof(struct pfioc_rule);
        printf("Size: %d\n", size);
        return 0;
}

As reported in sshuttle#219, new versions of OpenBSD ship with a different
pfioc_rule struct. This commit adjusts the offset to match the new struct.
@brianmay
Copy link
Copy Markdown
Member

Will this break previous versions of OpenBSD? Does this matter if it does?

2 similar comments
@brianmay
Copy link
Copy Markdown
Member

Will this break previous versions of OpenBSD? Does this matter if it does?

@brianmay
Copy link
Copy Markdown
Member

Will this break previous versions of OpenBSD? Does this matter if it does?

@brianmay
Copy link
Copy Markdown
Member

brianmay commented Oct 22, 2018 via email

@vieira
Copy link
Copy Markdown
Contributor Author

vieira commented Oct 22, 2018

Hello @brianmay

It will break older versions and it would be nice to state so in the release notes of the next release. Older versions of OpenBSD can continue to run older versions of sshutle.

Maybe in the future we can have some other way of interacting with pf that is more robust but for now this will allow the 4 most recent versions to work

@brianmay brianmay merged commit 7a54d12 into sshuttle:master Oct 22, 2018
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

Successfully merging this pull request may close these issues.

OpenBSD 6.1, 6.2, 6.3 client fails with IOError: [Errno 19] Operation not supported by device

2 participants