[Openvpn-devel] [PATCH 1/2] options: Fix failing inline tls-auth/crypt with persist-key

2020-05-08 Thread David Sommerseth
A configuration file using --persist-key and with inlined --tls-auth or --tls-crypt files was failing in check_file_access(). The file argument to check_file_access() contained the key file and not the file name. This was because check_file_access_inline() which calls check_file_access() if the f

[Openvpn-devel] [PATCH 2/2] options: Restore --tls-crypt-v2 inline file capability

2020-05-08 Thread David Sommerseth
Commit cb2e9218f2bc73f re-factored the internal file handling, but somehow overlooked the --tls-crypt-v2 option processing. It was no longer possible to load a configuration file with this key file inlined. There where two issues here. First was that the OPT_P_INLINE flag was not set, so the opt

Re: [Openvpn-devel] [PATCH 1/2] options: Fix failing inline tls-auth/crypt with persist-key

2020-05-08 Thread Antonio Quartulli
Hi, On 08/05/2020 13:42, David Sommerseth wrote: > A configuration file using --persist-key and with inlined --tls-auth or > --tls-crypt files was failing in check_file_access(). The file argument > to check_file_access() contained the key file and not the file name. > > This was because check_f

Re: [Openvpn-devel] [PATCH 2/2] options: Restore --tls-crypt-v2 inline file capability

2020-05-08 Thread Antonio Quartulli
Hi, On 08/05/2020 13:44, David Sommerseth wrote: > Commit cb2e9218f2bc73f re-factored the internal file handling, but > somehow overlooked the --tls-crypt-v2 option processing. It was no > longer possible to load a configuration file with this key file inlined. > maybe tls-crypt-v2 was not yet

[Openvpn-devel] [PATCH] options: fix inlining auth-gen-token-secret file

2020-05-08 Thread Antonio Quartulli
With commit ("convert *_inline attributes to bool") the logic for signaling when a certain option is inline has been changed. Due to an overlook, the auth-gen-token-secret was not converted, thus making it impossible to be inlined. Fix parsing logic and allow auth-gen-token-secret to be inlined as

[Openvpn-devel] [PATCH] get rid of TAG_FILE_INLINE constant

2020-05-08 Thread Antonio Quartulli
Now that the whole inline logic has been converted to using bool flags, the TAG_FILE_INLINE constant is not useful anymore. Get rid of the constant as it's now unused and to prevent any future developer from mistakenly use it again. Signed-off-by: Antonio Quartulli --- to be applied after all o

Re: [Openvpn-devel] [PATCH] get rid of TAG_FILE_INLINE constant

2020-05-08 Thread Antonio Quartulli
I managed to totally revert the name of the constant in the commit subject and commit message.. may somebody fix this upon merge? :-) It should be: INLINE_FILE_TAG Cheers, On 08/05/2020 23:23, Antonio Quartulli wrote: > Now that the whole inline logic has been converted to using bool flags, > t

[Openvpn-devel] [PATCH applied] Re: options: Fix failing inline tls-auth/crypt with persist-key

2020-05-08 Thread Gert Doering
Your patch has been applied to the master branch. Have not done any testing, but the code change looks very reasonable and exactly like it would fix the bug :-) commit e8e410fdc6fb91451d8119b129bac7be00ff81df Author: David Sommerseth Date: Fri May 8 13:42:43 2020 +0200 options: Fix failin

[Openvpn-devel] [PATCH applied] Re: options: Restore --tls-crypt-v2 inline file capability

2020-05-08 Thread Gert Doering
Your patch has been applied to the master branch. Not done any testing either, but this is very similar to the other hunks, so makes sense. Patch lingered for too long, new inline-capable options added :-( commit 7ae8dbb7c4a2ca4a23efae7b08222a8db0efc529 Author: David Sommerseth Date: Fri May 8