Skip to content

add utun for darwin#16

Open
majestrate wants to merge 7 commits into
BouleDeFeu:masterfrom
majestrate:darwin-utun
Open

add utun for darwin#16
majestrate wants to merge 7 commits into
BouleDeFeu:masterfrom
majestrate:darwin-utun

Conversation

@majestrate

Copy link
Copy Markdown
Contributor

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

@tleguern

Copy link
Copy Markdown
Contributor

Call for testing: @chipot or @ntnmrndn 😃

Comment thread tuntap-unix-darwin.c Outdated
if(fd == -1)
return -1;

struct ctl_info info;

Copy link
Copy Markdown
Contributor

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

ntnmrndn commented Jan 30, 2019

Copy link
Copy Markdown
Contributor

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
Copy Markdown
Contributor

@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
Copy Markdown
Contributor

"Can't get interface values"

@tleguern

tleguern commented Oct 9, 2019

Copy link
Copy Markdown
Contributor

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