ArchLinux: 201709-21: openvpn: arbitrary code execution
Summary
The bounds check in the read_key() function in OpenVPN before 2.4.4 and 2.3.18 was performed after using the value, instead of before. If 'key-method 1' is used, this allowed an attacker to send a malformed packet to trigger a stack buffer overflow. Note that 'key-method 1' has been replaced by 'key method 2' as the default in OpenVPN 2.0 (released on 2005-04-17), and explicitly deprecated in 2.4 and marked for removal in 2.5. This should limit the amount of users impacted by this issue.
Resolution
Upgrade to 2.4.4-1.
# pacman -Syu "openvpn>=2.4.4-1"
The problem has been fixed upstream in version 2.4.4.
References
https://community.openvpn.net/openvpn/wiki/CVE-2017-12166 https://github.com/OpenVPN/openvpn/commit/3b1a61e9fb27213c46f76312f4065816bee8ed01 https://security.archlinux.org/CVE-2017-12166
Workaround
Ensure 'key-method 2' is used (default value).