Skip to content
This repository was archived by the owner on Apr 18, 2024. It is now read-only.
This repository was archived by the owner on Apr 18, 2024. It is now read-only.

Websocket on MPTCP keep raising warning: getsockopt: Bad Address. #489

@ArthurCChen

Description

@ArthurCChen

Hi, My MPTCP pair: AWS EC2(as the server) & PC(as the client) (Both Ubuntu18.04 and Linux 4.19.234) works correctly according to the Wireshark. However, after adding the module:

  struct mptcp_info minfo;
  struct mptcp_meta_info meta_info;
  struct tcp_info initial;
  struct tcp_info *others; // increase it if needed
  struct mptcp_sub_info others_info[3]; // same
  socklen_t len;
  len = sizeof(minfo);
  minfo.tcp_info_len = sizeof(struct tcp_info);
  minfo.sub_len = sizeof(others);
  minfo.meta_len = sizeof(struct mptcp_meta_info);
  minfo.meta_info = &meta_info;
  minfo.initial = &initial;
  minfo.subflows = others;
  minfo.sub_info_len = sizeof(struct mptcp_sub_info);
  minfo.total_sub_info_len = sizeof(others_info);
  minfo.subflow_info = others_info;

  cout << 'Before getting the MPTCP_INFO, minfo: ' << minfo.total_sub_info_len << endl;

  #define MPTCP_INFO_FLAG_SAVE_MASTER 0x01
  int val = MPTCP_INFO_FLAG_SAVE_MASTER;
  CheckSystemCall( "setsockopt", ::setsockopt( fd_num(), IPPROTO_TCP, MPTCP_INFO,
                                                 &val, sizeof( val ) ) );

  getsockopt(<fd num>, IPPROTO_TCP, MPTCP_INFO, &minfo &len);

it now continuously closes my WebSocket connection and reconnect. Exactly at this line:
getsockopt(<fd num>, IPPROTO_TCP, MPTCP_INFO, &minfo &len);

  • How did you install it?
    A: I downloaded MPTCP-V0.95 from the home page of MPTCP.(git clone) Then I make menuconfig and compile it and change the kernel according to the instruction

  • Which command are you using to compile this code?
    A: All the process is here:

git clone --depth=1 git://github.com/multipath-tcp/mptcp.git
cd mptcp
sudo make menuconfig
sudo make
sudo make modules_install
sudo make install
  • All the previous setsockopt here were OK?
    A: Yes.

  • The return value of this getsockopt?
    A: It's not -1.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions