-
Notifications
You must be signed in to change notification settings - Fork 4
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
Quesion: AX.25 socket data corruption #9
Comments
I wonder if this has to do with SSH rekeying. Try running debugging on the SSH client and server to see what might be going on there. Beyond that, I believe this would be better asked on the Linux Hams linux-hams@vger.kernel.org list as this probably has nothing to do with AX.25. --David |
Hello, David, Thanks for your suggestion.
Now it is obvious that there is not only a data duplication, but data truncation as well. Ivan, |
I'm going to recommend that this issue be taken up with the official source (which this is not). If there are patches to correct this behaviour, that is where they need to be applied, and they will get pulled in here in due time. |
Hello, A small update. I used the 'call' utility for checking if there a same problem there as well. And it looks (at least for me) that there is indeed a problem in linux's system buffer during write(). During debugging of my proxy.c I was adding some 10—100 ms usleep() delays between each write() into SOCK_SEQPACKET socket and it helped on the fast AXUDP Ethernet link. I doubt it would help to maintain consistency on slower links. I've recorded a small video: https://youtu.be/K4vhCXLK1b0 and updated linux-hams mailing list as well. It also looks like noone is using connected mode anymore, at least I've got no replies to my message on linux-hams mailing list. Ivan |
Hello Ivan, --David |
Hello, David, Thanks for the legacy kernel mention. I'll check out what's going on in that department in a VirtaulBox environment. As I understand, there is a complication with keeping AX.25 code in sync with the current kernel state. May be I should look at that side of user-level stacks. Thanks, |
Are you sure this is not a kernel bug? |
If the belief this is a real kernel issue, it would best to create a new email thread at: Thomas Osterried, who maintains the official AX.25 repo for user space code, is also on that list just in case this might be a kernel+userspace interaction issue. |
Kernel or upstream issue. Not fixing it in our source. |
Hello,
I'm writting a proxy programme to pass-through raw binary data between AX.25 socket and a TCP socket.
In fact, to not to reinvent the wheel, I took a simple TCP proxy source and converted the server TCP socket to AX.25 socket on one side and a client TCP socket to AX.25 socket on another side of AX.25 link.
Here is the snippet of the programme:
On one side of AX.25 link it accepts TCP connections on port 6789 and initiates an AX.25 connection to UR5VIB-8. On the other side of the link proxy accepts AX.25 connections on UR5VIB-8 and forwards data to local TCP port 22.
It generally works. For a while. You can log in by SSH (or telnet) via proxied link to the remote site. The overal interactivity (reaction on packet loss) is far better than in IP encapsulation mode. But after a while you've got a connection reset from SSH with message:
(For telnet connection you will just get a connection reset.)
I tried to figure out what is the problem with axlisten and tcpdump, and I'm not 100% sure, but I think I found that there is data duplication in the middle of the transfer. The inserted data makes SSH confused.
May be someone can shed a light on what am I missing here?
I though it should be starighforward to pass the data between two reliable sequential sockets.
Thanks!
Ivan,
UR5VIB
The text was updated successfully, but these errors were encountered: