diff --git a/doc/management-notes.txt b/doc/management-notes.txt index 1a5c311c..86b74f33 100644 --- a/doc/management-notes.txt +++ b/doc/management-notes.txt @@ -492,6 +492,10 @@ Command examples: version 2 -- Change management version of client to 2 (default = 1) version -- Show the version of OpenVPN and its Management Interface +Note: Until version 3, no response was generated when client sets its +version. This was fixed starting version 4: clients should expect +"SUCCESS: .. " message only when setting the version to >= 4. + COMMAND -- auth-retry --------------------- diff --git a/src/openvpn/manage.c b/src/openvpn/manage.c index 37ae6b38..03ff5b37 100644 --- a/src/openvpn/manage.c +++ b/src/openvpn/manage.c @@ -1333,6 +1333,15 @@ set_client_version(struct management *man, const char *version) if (version) { man->connection.client_version = atoi(version); + /* Prior to version 3, we missed to respond to this command. Acknowledge only if version >= 4 */ + if (man->connection.client_version >= 4) + { + msg(M_CLIENT, "SUCCESS: Management client version set to %d", man->connection.client_version); + } + } + else + { + msg(M_CLIENT, "ERROR: Invalid value specified for management client version"); } }