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

add utun for darwin #16

Open
wants to merge 7 commits into
base: master
Choose a base branch
from
Open

Conversation

majestrate
Copy link
Contributor

add support for apple's non standard utun network interace creation mechanism.

@tleguern
Copy link
Member

Call for testing: @chipot or @ntnmrndn 😃

if(fd == -1)
return -1;

struct ctl_info info;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Variable declarations should respect ANSI C and thus be at the top of the current block.

@ntnmrndn
Copy link
Member

ntnmrndn commented Jan 30, 2019

Hi, sorry for the delay, I'm starting to review the PR.

It doesn't compile on my computer:

libtuntap/tuntap-unix-darwin.c:63:39: error: use of undeclared identifier 'errno'

Adding the include #include <sys/errno.h> solves the issue
As for the tests, we went from

14 - tuntap.test14 (Failed)
16 - tuntap.test18 (Failed)

to

2 - tuntap.test02 (Failed)
6 - tuntap.test06 (Failed)
8 - tuntap.test08 (Failed)
10 - tuntap.test10 (Failed)
12 - tuntap.test12 (Failed)
14 - tuntap.test14 (Failed)
16 - tuntap.test18 (Failed)
18 - tuntap.test22 (Failed)
20 - tuntap.test24 (Failed)
22 - tuntap.test26 (Failed)

@tleguern
Copy link
Member

@ntnmrndn: It is clear every tun operations are failing. Can you run the failing regress tests individually and share the output please ?

@ntnmrndn
Copy link
Member

"Can't get interface values"

@tleguern
Copy link
Member

tleguern commented Oct 9, 2019

I think the code needs to be split a bit further than this as the traditional ioctl calls are not going to work on utun interfaces. The code is currently able to create an utun device of unspecified number but can't manipulate it yet.

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.

4 participants