strongswan: Function not implemented with chacha20poly1305
Nobody has claimed this yet.
- Dominant language
- Makefile
- Stars
- 4.6k
- Forks
- 4k
- Avg merge
- 3d 12h
- Merged PRs (30d)
- 134
Description
Maintainer: @pprindeville @Thermi (find it by checking history of the package Makefile)
Environment: Linksys E8450 (aarch64)/Linksys WRT1900ACS (armv7), OpenWrt 22.03-rc6
Description:
@xwang1498 in #18192 and openwrt/openwrt#9951, together with @pprindeville in #18654 implemented support for chacha20poly1305 in master. The kmod change and was backported to 22.03-rc5 (openwrt/openwrt@3cfe050c4a683ecef25d6ded05b1d240921a121a), but not #18654. Regardless of #18654 being backported, it should be sufficient to manually install kmod-crypto-chacha20poly1305:
$ opkg list-installed | grep cha
kmod-crypto-chacha20poly1305 - 5.10.134-1
kmod-crypto-echainiv - 5.10.134-1
strongswan-charon - 5.9.5-8
strongswan-mod-chapoly - 5.9.5-8
However, when trying to negotiate chacha20poly1305, the kernel still returns Function not implemented:
Sun Aug 28 09:21:08 2022 daemon.info ipsec: 16[KNL] received netlink error: Function not implemented (38)
Sun Aug 28 09:21:08 2022 daemon.info ipsec: 16[KNL] unable to add SAD entry with SPI XXXXXXXX (FAILED)
Sun Aug 28 09:21:09 2022 daemon.info ipsec: 16[KNL] received netlink error: Function not implemented (38)
Sun Aug 28 09:21:09 2022 daemon.info ipsec: 16[KNL] unable to add SAD entry with SPI YYYYYYYY (FAILED)
Sun Aug 28 09:21:09 2022 daemon.info ipsec: 16[IKE] unable to install inbound and outbound IPsec SA (SAD) in kernel
Sun Aug 28 09:21:09 2022 daemon.info ipsec: 16[IKE] failed to establish CHILD_SA, keeping IKE_SA
Sun Aug 28 09:21:09 2022 daemon.info ipsec: 16[ENC] generating CREATE_CHILD_SA response 0 [ N(NO_PROP) ]
I'm not sure if this is a problem with my config or if it's a problem elsewhere:
/var/swanctl/swanctl.conf:
...
children {
.... {
....
esp_proposals = chacha20poly1305-curve448,aes256gcm128-curve448,aes256gcm128-modp4096
....
}
}
...
Removing esp_chacha20poly1305_curve448 does allow phase2 to be negotiated and the tunnel is set up (using aes). Did I miss anything here?
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the strongSwan package Makefile history and the OpenWrt 22.03-rc6 package and kernel-module versions listed in the report. Reproduce the chacha20poly1305 negotiation using the shown swanctl.conf and inspect the netlink errors. Done means identifying whether the failure is in the package, kernel module, or configuration and documenting the required correction.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- linux
- Domain
- networking
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100