Steve Jacobson's "MPTCP support in FreeBSD" Page


Does FreeBSD support the MPTCP protocol?

This investigation is an attempt to answer the question: Does FreeBSD support the MPTCP (multipath TCP) protocol?

This page is being updated in November, 2024, to reflect recent work done on FreeBSD 13.1. Earlier information regarding an implementation on FreeBSD 11.0 is still found below.

Current work done by Shiva Raj Pokhrel et al., at Swinburne University of Technology, Melbourne, Australia:

  • An article published October, 2024, written by Shiva Raj Pokhrel, et al., titled: "Multipath TCP implementation under FreeBSD-13 for pluggable machine learning models," describes an MPTCP implementation on FreeBSD 13.1. The article is available in html and as a .pdf.

  • The GitHUB software repository for the project. Apparently related information: GitHUB software repository for the project. Also the GitHUB FreeBSD source code repository

    Older work done by Nigel Williams et al., at Swinburne University of Technology, Melbourne, Australia:

  • An August, 2014 academic paper written by Nigel Williams, et al. regarding their work on developing MPTCP support for FreeBSD. Describes their v0.4 release.

  • BSDCan2013, 17 May 2013: Nigel Williams' 58 minute video presentation of Multipath TCP for FreeBSD (2013). Believed to be his first MPTCP presentation to the FreeBSD community.

  • IETF, Berlin, July 28, 2013: Nigel Williams' slides: Multipath TCP for FreeBSD: WG Update. IETF Transport Area working group.

  • BSDCan2015, 13 June 2015: Nigel Williams' 47 minute video presentation of Multipath TCP for FreeBSD (2015). Presentation of his imminent v0.5 release of MPTCP for FreeBSD.

  • IETF, 21 July, 2015: Nigel Williams' slides: Multipath TCP for FreeBSD: WG Update. IETF MPTCP working group. Discusses current (v0.5) patch.

  • Nigel Williams' October 24, 2016 Master of Engineering thesis, Implementing a Multipath Transmission Control Protocol (MPTCP) stack for FreeBSD with pluggable congestion and scheduling control.

  • Swinburne University of Technology Centre for Advanced Internet Architectures (CAIA) Multipath TCP home page. Somewhat stale, but still contains important information and links.

  • This pfSense Feature #4632 web page claims that the last commit to the Swinburne CAIA BitBucket Repository was on 2019-12-12. This implies that work continued for several years after Nigel Williams' last patch release. The link is now dead. Does anyone know the new location of this repository? Or, where a tar file of this updated code might exist? Note that the bitbucket repository link is from the CAIA Multipath TCP web page, above.

  • freebsd-net@freebsd.org mailing list posting from Nigel Williams, MPTCP for FreeBSD repository on BitBucket/v0.51 update, confirmining use of the Swinburne CAIA BitBucket Repository and Swinburne CAIA BitBucket wiki. (both now dead links). Post initiated on 2015-10-19.

  • Related repository to the above, Swinburne CAIA BitBucket files Repository (now a dead link). This web page: says the above repository had vanished as of 2021-07-29.

  • Software Heritage web page, which links to what are believed to be archives of the Swinburne CAIA BitBucket Mercurial repository and metadata.

  • Resurrection of the Swinburne CAIA BitBucket Mercurial MPTCP on FreeBSD repository.

    Nigel Williams' MPTCP patches, readmes, changelogs and other information:

  • A collection of patches, readme files, changelogs, etc. for releases v0.2 - v0.51. v0.4 dated 11th July, 2014; v0.3 dated 16th April 2013; v0.2 dated 15th March 2013.

  • Patch, readme, changelog, kernel, etc. for release v0.5. Dated 1st September, 2015.

  • Readme, changelog, kernel, etc. for release v0.51. Unfortunately, no patch file. Dated 15 October, 2015.

    Other information about MPTCP support in FreeBSD:

  • FreeBSD Forums: Non-answer regarding the status of multipath TCP support on FreeBSD 12+

  • FreeBSD Foundation: Status report on Multipath TCP for FreeBSD. States that the project is complete, or at least met the stated goals. References the Swinburne CAIA MPTCP project.

    Other FreeBSD MPTCP work:

  • Ray Guo's GitHub repository: Port of Swinburne CAIA v0.5 MPTCP patch to FreeBSD-13.

    Searching for FreeBSD MPTCP support: Analyzing FreeBSD source code with cscope:

    cscope was used to search new and old FreeBSD source code for the strings "MPTCP" and "mptcp". Results for FreeBSD HEAD and FreeBSD 8.4 are shown below. Except for the added tcpdump files, the prevalence of these strings has scarcely changed.

    References to MPTCP/mptcp in the SCTP source code predates FreeBSD 8.4. Examining the file copyright headers, one can speculate that it originated with the work done by Cisco Systems. It is unclear (at least to me) if the strings have alternate meanings in the SCTP context.

    FreeBSD HEAD software, pulled from git 02/18/23:

    Text string: MPTCP
    
      File                Line
    0 print-mptcp.c        35 /* \summary: Multipath TCP (MPTCP) printer */
    1 print-mptcp.c        51 #define MPTCP_SUB_CAPABLE       0x0
    2 print-mptcp.c        52 #define MPTCP_SUB_JOIN          0x1
    3 print-mptcp.c        53 #define MPTCP_SUB_DSS           0x2
    4 print-mptcp.c        54 #define MPTCP_SUB_ADD_ADDR      0x3
    5 print-mptcp.c        55 #define MPTCP_SUB_REMOVE_ADDR   0x4
    6 print-mptcp.c        56 #define MPTCP_SUB_PRIO          0x5
    7 print-mptcp.c        57 #define MPTCP_SUB_FAIL          0x6
    8 print-mptcp.c        58 #define MPTCP_SUB_FCLOSE        0x7
    9 print-mptcp.c        66 #define MPTCP_OPT_SUBTYPE(sub_etc)      (((sub_etc) >>
                              4) & 0xF)
    a print-mptcp.c       442 subtype = min(MPTCP_OPT_SUBTYPE(opt->sub_etc),
                              MPTCP_SUB_FCLOSE + 1);
    b print-tcp.c         133 { TCPOPT_MPTCP, "mptcp" },
    c print-tcp.c         592 case TCPOPT_MPTCP:
    d tcp.h                88 #define TCPOPT_MPTCP  30 /* MPTCP options */
    e sctp.h              302 #define SCTP_CMT_MPTCP          4
    f sctp.h              303 #define SCTP_CMT_MAX            SCTP_CMT_MPTCP
    g sctp_cc_functions.c  53 #define SHIFT_MPTCP_MULTI_N 40
    h sctp_cc_functions.c  54 #define SHIFT_MPTCP_MULTI_Z 16
    i sctp_cc_functions.c  55 #define SHIFT_MPTCP_MULTI 8
    j sctp_cc_functions.c 708 (stcb->asoc.sctp_cmt_on_off == SCTP_CMT_MPTCP)) {
    k sctp_cc_functions.c 718 t_path_mptcp += (((uint64_t)net->cwnd) <<
                              SHIFT_MPTCP_MULTI_Z) /
    l sctp_cc_functions.c 720 tmp = (((uint64_t)net->cwnd) << SHIFT_MPTCP_MULTI_N) /
    m sctp_cc_functions.c 882 case SCTP_CMT_MPTCP:
    n sctp_cc_functions.c 886 SHIFT_MPTCP_MULTI);
    o sctp_cc_functions.c 889 SHIFT_MPTCP_MULTI);
    p sctp_cc_functions.c 962 case SCTP_CMT_MPTCP:
    q sctp_cc_functions.c 965 SHIFT_MPTCP_MULTI);
    r sctp.h              304 #define SCTP_CMT_MPTCP          4
    s sctp.h              305 #define SCTP_CMT_MAX            SCTP_CMT_MPTCP
    
    ---
    
    Text string: mptcp
    
      File                Line
    0 netdissect.h        551 extern int mptcp_print(netdissect_options *, const
                              u_char *, u_int, u_char);
    1 print-mptcp.c        60 struct mptcp_option {
    2 print-mptcp.c       419 } mptcp_options[] = {
    3 print-mptcp.c       432 mptcp_print(netdissect_options *ndo,
    4 print-mptcp.c       435 const struct mptcp_option *opt;
    5 print-mptcp.c       441 opt = (const struct mptcp_option *) cp;
    6 print-mptcp.c       444 ND_PRINT((ndo, " %s", mptcp_options[subtype].name));
    7 print-mptcp.c       445 return mptcp_options[subtype].print(ndo, cp, len,
                              flags);
    8 print-tcp.c         133 { TCPOPT_MPTCP, "mptcp" },
    9 print-tcp.c         595 if (!mptcp_print(ndo, cp-2, len, flags))
    a sctp_cc_functions.c 696 uint64_t t_path_mptcp;
    b sctp_cc_functions.c 697 uint64_t mptcp_like_alpha;
    c sctp_cc_functions.c 704 t_path_mptcp = 0;
    d sctp_cc_functions.c 705 mptcp_like_alpha = 1;
    e sctp_cc_functions.c 718 t_path_mptcp += (((uint64_t)net->cwnd) <<
                              SHIFT_MPTCP_MULTI_Z) /
    f sctp_cc_functions.c 727 if (t_path_mptcp > 0) {
    g sctp_cc_functions.c 728 mptcp_like_alpha = max_path / (t_path_mptcp *
                              t_path_mptcp);
    h sctp_cc_functions.c 730 mptcp_like_alpha = 1;
    i sctp_cc_functions.c 884 mptcp_like_alpha *
    j sctp_cc_functions.c 888 mptcp_like_alpha) >>
    k sctp_cc_functions.c 963 incr = (uint32_t)((mptcp_like_alpha *
    
    
    FreeBSD 8.4 release software:
    Text string: MPTCP
    
      File                Line
    0 sctp.h              291 #define SCTP_CMT_MPTCP          4
    1 sctp.h              292 #define SCTP_CMT_MAX            SCTP_CMT_MPTCP
    2 sctp_cc_functions.c  51 #define SHIFT_MPTCP_MULTI_N 40
    3 sctp_cc_functions.c  52 #define SHIFT_MPTCP_MULTI_Z 16
    4 sctp_cc_functions.c  53 #define SHIFT_MPTCP_MULTI 8
    5 sctp_cc_functions.c 683 (stcb->asoc.sctp_cmt_on_off == SCTP_CMT_MPTCP)) {
    6 sctp_cc_functions.c 694 t_path_mptcp += (((uint64_t) net->cwnd) <<
                              SHIFT_MPTCP_MULTI_Z) /
    7 sctp_cc_functions.c 696 tmp = (((uint64_t) net->cwnd) << SHIFT_MPTCP_MULTI_N)
                              /
    8 sctp_cc_functions.c 859 case SCTP_CMT_MPTCP:
    9 sctp_cc_functions.c 863 SHIFT_MPTCP_MULTI);
    a sctp_cc_functions.c 866 SHIFT_MPTCP_MULTI);
    b sctp_cc_functions.c 938 case SCTP_CMT_MPTCP:
    c sctp_cc_functions.c 941 SHIFT_MPTCP_MULTI);
    d sctp.h              291 #define SCTP_CMT_MPTCP          4
    e sctp.h              292 #define SCTP_CMT_MAX            SCTP_CMT_MPTCP
    
    ---
    
    Text string: mptcp
    
      File                Line
    0 sctp_cc_functions.c 670 uint64_t t_path_mptcp;
    1 sctp_cc_functions.c 671 uint64_t mptcp_like_alpha;
    2 sctp_cc_functions.c 679 t_path_mptcp = 0;
    3 sctp_cc_functions.c 680 mptcp_like_alpha = 1;
    4 sctp_cc_functions.c 694 t_path_mptcp += (((uint64_t) net->cwnd) <<
                              SHIFT_MPTCP_MULTI_Z) /
    5 sctp_cc_functions.c 703 if (t_path_mptcp > 0) {
    6 sctp_cc_functions.c 704 mptcp_like_alpha = max_path / (t_path_mptcp *
                              t_path_mptcp);
    7 sctp_cc_functions.c 706 mptcp_like_alpha = 1;
    8 sctp_cc_functions.c 861 mptcp_like_alpha *
    9 sctp_cc_functions.c 865 mptcp_like_alpha) >>
    a sctp_cc_functions.c 939 incr = (uint32_t) ((mptcp_like_alpha *
    
    

    Conclusions:

    MPTCP is not supported by production releases of FreeBSD.

    Recent MPTCP changes to FreeBSD 13.1 from Swinburne University of Technology should be close to being able to work on FreeBSD HEAD. The MPTCP software is not currently production quality per the team that developed it.

    Earlier MPTCP work on FreeBSD 11.0 from the Swinburne CAIA project is no longer supported, and can no longer be patched into recent FreeBSD source code without extensive work.

    More information:

  • Resurrecting the Swinburne CAIA MPTCP repository

  • General MPTCP links