jasonking3 / macipgw

https://github.com/zero2sixd/macipgw/wiki
Other
44 stars 6 forks source link

Doesn't work with Linux kernels compiled with the "ipddp" module #3

Closed aseering closed 8 years ago

aseering commented 8 years ago

Linux has an existing "ipddp" module that appears to be intended to implement some subset of the functionality of this program. When the "ipddp" module is built, even as a module that's not loaded, all DDP packets of protocol type 22 (DDPTYPE_MACIP) get redirected in the kernel into code that's intended to handle ipddp packets. (This happens here.) As a result, those packets never reach the macipgw application, so are not handled by it.

I don't know that macipgw itself can do much about this. But it is a limitation. Likely workaround (I haven't tested) is to recompile the kernel with both CONFIG_IPDDP and CONFIG_IPDDP_MODULE disabled.

jasonking3 commented 8 years ago

Sorry, yes, ipddp needs to be disabled when the AppleTalk module is built, otherwise the kernel will eat the ipddp packets. I have been meaning to update the readme with that little tidbit.

Sent from my iPhone

On Jan 3, 2016, at 3:12 PM, Adam Seering notifications@github.com wrote:

Linux has an existing "ipddp" module that appears to be intended to implement some subset of the functionality of this program. When the "ipddp" module is built, even as a module that's not loaded, all DDP packets of protocol type 22 (DDPTYPE_MACIP) get redirected in the kernel into code that's intended to handle ipddp packets. (This happens here.) As a result, those packets never reach the macipgw application, so are not handled by it.

I don't know that macipgw itself can do much about this. But it is a limitation. Likely workaround (I haven't tested) is to recompile the kernel with both CONFIG_IPDDP and CONFIG_IPDDP_MODULE disabled.

— Reply to this email directly or view it on GitHub.

jasonking3 commented 8 years ago

I saw the same thing as you when I looked at the appletalk kernel module code. It automatically eats type 22 DDP packets when IPDDP is enabled and does so in a very static fashion (i.e. no way to turn it off at runtime). This came up when I was helping the A2SERVER maintainers integrate macipgw with their code base. They run a generic debian kernel that has IPDDP enabled by default. I didn't see it in the original porting work because I was using Raspbian and it wasn't enabled in the appletalk module I was using.

Anyway, I am going to close this issue since the requirement to disable IPDDP is now in the README and there is nothing to be done within the macipgw code base to fix it. We can re-open it later if something changes.

(One thought I had was to go after the macgated implementation as well since it uses the built-in IPDDP functionality of Linux. I think somewhere I found a relatively recent working version but I didn't bookmark it. However, my motivation to do that is pretty low since macipgw is working fine.)