Re: [Openvpn-devel] [PATCH 2.3] Fix compilation in pedantic mode

2016-10-05 Thread Daniel Hunsaker
On Wednesday, October 5, 2016 12:43, David Sommerseth wrote:
On 05/10/16 20:34, Steffan Karger wrote:
> On 5 October 2016 at 20:25, David Sommerseth
>  wrote:
>> The Hackathon in Munich 2014 [1] decided on the the Allmann style
>> [2]. The only thing I'm not sure we agreed upon is the indent
>> size (4 or 8 spaces), in addition to the line length which is not
>> that explicitly agreed upon.
>
> I seem to remember we agreed on 4 spaces.  (8 would really not
> work with the current code and a 80-chars-per-line limit.)

Fair point!  I remember we discussed both, but as we never truly
documented any result here I have forgotten it.  And it is aligned
what Gert claims too.

Also, 8 spaces is a terrible idea anyway.  Even the most ancient printing 
presses (after indentation was initially used) only went as far as (the 
equivalent of) 5 - and their fonts were proportional.

That said, I will always prefer \t over \x20*.

Daniel Hunsaker
QA / Automation
OpenVPN Technologies, Inc

irc://irc.freenode.net: danhunsaker
--
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
___
Openvpn-devel mailing list
Openvpn-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openvpn-devel


Re: [Openvpn-devel] [PATCH 2.3] Fix compilation in pedantic mode

2016-10-05 Thread Gert Doering
Hi,

On Wed, Oct 05, 2016 at 08:25:51PM +0200, David Sommerseth wrote:
> The Hackathon in Munich 2014 [1] decided on the the Allmann style [2].
>  The only thing I'm not sure we agreed upon is the indent size (4 or 8
> spaces), in addition to the line length which is not that explicitly
> agreed upon.

/me claims "it was 4" :)

gert
-- 
USENET is *not* the non-clickable part of WWW!
   //www.muc.de/~gert/
Gert Doering - Munich, Germany g...@greenie.muc.de
fax: +49-89-35655025g...@net.informatik.tu-muenchen.de


signature.asc
Description: PGP signature
--
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot___
Openvpn-devel mailing list
Openvpn-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openvpn-devel


Re: [Openvpn-devel] [PATCH 2.3] Fix compilation in pedantic mode

2016-10-05 Thread David Sommerseth
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On 05/10/16 17:29, Lev Stipakov wrote:
> Hi,
> 
> 
> I am, and the first version is what we do in (most?) other places, 
> so I'll change that on the fly.
> 
> 
> Got it.
> 
> 
> Also, the patch introduces spurious tab<->whitespace changes "close
> to comments" in a few places - will undo those, too.
> 
> 
> I noticed that in few places indentation is a bit off - like 8 
> whitespaces instead of tab so I decided to "fix" it.
> 
> Should I just ignore those things or do it in separate PR?

Currently I think we can leave them.  Before the release of 2.4-RC we
will do a lot of coding style fixes to the whole source tree, so that
we have one unified coding style over the whole code base in both the
new releases/2.4 and master branch.

The Hackathon in Munich 2014 [1] decided on the the Allmann style [2].
 The only thing I'm not sure we agreed upon is the indent size (4 or 8
spaces), in addition to the line length which is not that explicitly
agreed upon.

[1] 
[2] 


- -- 
kind regards,

David Sommerseth
OpenVPN Technologies, Inc

-BEGIN PGP SIGNATURE-
Version: GnuPG v2.0.22 (GNU/Linux)

iQIcBAEBAgAGBQJX9UWvAAoJEIbPlEyWcf3ytj4P/iuXf+htHtFjQfE9/QSWY/Ui
+jpF1kqlAKac6eS1t0cN1OYVUmXZwNkZjGNKYl8vi9zVSciZf2rFslTAhaaRLuWW
LMtL1MxGJbADvLpKkHPfvSNk3ITXxhnMKjgXqzxnPY2WeyV7f48jKOUeBma3RY1R
m4hT8Hg0Im2cqVmU9XRDvEc3u0EqTKzA/NP6sKO1dWut05ZwKlIyUknsJfLoZyEx
OPghZaTgFmz0YZKQqam0cenkL2g3cYuz60GQw8Lpio6GFLQMMbjV9fRpdIJ4d36W
qIdulNh+idXDvuSe3bFFQqYItdUIIgaBvz8dUDCubz47OR6vkTD+/+KR0f4F5C/9
HHt1CW4GAs5AEvFpF9BhPoxajQHNjoZsrWOL+YgumVKcTUclgd/iUoRTBusSF87H
fYp/b7XjLO1cr1QPprK0szzNQB4HMFx3aVxZlvhC8WePN+uO8a6X55g08pnuy7kS
PQ5nrfOywwQsqhl9p9E5lFV2HoeIfxGkwjoq4xztGI9xyV3jFroaqn4cN9314+aF
RREgmCYInDEZzVXjqFCC/0isgEXOYdC/p6Hpy6EWzCecFf8fm1Gs4CQnhodR7Min
QyKZhhC/yAXgOKuEKCPw+NY+eulE1VwRmIBEJujKgeVBNVIoaQc43wEARIYhTdcO
SrffianKpvhWJiPjLRUd
=TF/Z
-END PGP SIGNATURE-

--
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
___
Openvpn-devel mailing list
Openvpn-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openvpn-devel


Re: [Openvpn-devel] [PATCH 2.3] Fix compilation in pedantic mode

2016-10-05 Thread Gert Doering
Hi,

On Wed, Oct 05, 2016 at 05:29:46PM +0200, Lev Stipakov wrote:
> I noticed that in few places indentation is a bit off - like 8 whitespaces
> instead of tab so I decided to "fix" it.
> 
> Should I just ignore those things or do it in separate PR?

Please do not intermix whitespace changes with "other changes" - this
makes it harder to track what really changed in a patch.

We are planning to do a massive re-indentation before 2.4 release
(right when we branch off the release/2.4 branch, or so) - so I'd not
bother right now.

If you do actual code changes to a line that has funny whitespace, of
course feel free to fix that as well ;-)

gert

-- 
USENET is *not* the non-clickable part of WWW!
   //www.muc.de/~gert/
Gert Doering - Munich, Germany g...@greenie.muc.de
fax: +49-89-35655025g...@net.informatik.tu-muenchen.de


signature.asc
Description: PGP signature
--
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot___
Openvpn-devel mailing list
Openvpn-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openvpn-devel


Re: [Openvpn-devel] [PATCH 2.3] Fix compilation in pedantic mode

2016-10-05 Thread Lev Stipakov
Hi,


I am, and the first version is what we do in (most?) other places, so I'll
> change that on the fly.
>

Got it.


> Also, the patch introduces spurious tab<->whitespace changes "close to
> comments" in a few places - will undo those, too.


I noticed that in few places indentation is a bit off - like 8 whitespaces
instead of tab so I decided to "fix" it.

Should I just ignore those things or do it in separate PR?

-- 
-Lev
--
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot___
Openvpn-devel mailing list
Openvpn-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openvpn-devel


Re: [Openvpn-devel] [PATCH] man page: Update the --cipher section to reflect recommendations after SWEET32

2016-10-05 Thread Gert Doering
Hi,

On Wed, Oct 05, 2016 at 02:48:01PM +0200, David Sommerseth wrote:
> We should no longer make users believe Blowfish is a 'very secure' cipher.
> Update this section to reflect our recommendations after the SWEET32
> announcement.

NAK, as it conflicts with 

commit 5a1daf533ae283e258732260c96461e820e61fe6
Author: Steffan Karger 
Date:   Sun Sep 11 16:50:31 2016 +0200

Update cipher-related man page text

As reported in trac #732, the man page text for --cipher is no longer
accurate.  Update the text to represent current knowledge, about NCP and
SWEET32.


gert
-- 
USENET is *not* the non-clickable part of WWW!
   //www.muc.de/~gert/
Gert Doering - Munich, Germany g...@greenie.muc.de
fax: +49-89-35655025g...@net.informatik.tu-muenchen.de


signature.asc
Description: PGP signature
--
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot___
Openvpn-devel mailing list
Openvpn-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openvpn-devel


Re: [Openvpn-devel] [PATCH v2] Exclude peer-id from pulled options digest

2016-10-05 Thread Steffan Karger
On 04-10-16 22:20, Lev Stipakov wrote:
> v2:
>  - Move digest update to separate method
> 
> Peer-id might change on restart and this should not trigger reopening
> tun.
> 
> Trac #649
> ---
>  src/openvpn/push.c | 45 ++---
>  1 file changed, 30 insertions(+), 15 deletions(-)
> 
> diff --git a/src/openvpn/push.c b/src/openvpn/push.c
> index a1b999e..c0c78a0 100644
> --- a/src/openvpn/push.c
> +++ b/src/openvpn/push.c
> @@ -597,6 +597,20 @@ process_incoming_push_request (struct context *c)
>  }
>  #endif
>  
> +static void
> +push_update_digest(md_ctx_t *ctx, struct buffer *buf)
> +{
> +  char line[OPTION_PARM_SIZE];
> +  while (buf_parse (buf, ',', line, sizeof (line)))
> +{
> +  /* peer-id might change on restart and this should not trigger 
> reopening tun */
> +  if (strstr (line, "peer-id ") != line)
> + {
> +   md_ctx_update (ctx, (const uint8_t *) line, strlen(line));
> + }
> +}
> +}
> +
>  int
>  process_incoming_push_msg (struct context *c,
>  const struct buffer *buffer,
> @@ -636,21 +650,22 @@ process_incoming_push_msg (struct context *c,
> permission_mask,
> option_types_found,
> c->c2.es))
> - switch (c->options.push_continuation)
> -   {
> -   case 0:
> -   case 1:
> - md_ctx_update (>c2.pulled_options_state, BPTR(_orig), 
> BLEN(_orig));
> - md_ctx_final (>c2.pulled_options_state, 
> c->c2.pulled_options_digest.digest);
> - md_ctx_cleanup (>c2.pulled_options_state);
> - c->c2.pulled_options_md5_init_done = false;
> - ret = PUSH_MSG_REPLY;
> - break;
> -   case 2:
> - md_ctx_update (>c2.pulled_options_state, BPTR(_orig), 
> BLEN(_orig));
> - ret = PUSH_MSG_CONTINUATION;
> - break;
> -   }
> + {
> +   push_update_digest (>c2.pulled_options_state, _orig);
> +   switch (c->options.push_continuation)
> + {
> +   case 0:
> +   case 1:
> + md_ctx_final (>c2.pulled_options_state, 
> c->c2.pulled_options_digest.digest);
> + md_ctx_cleanup (>c2.pulled_options_state);
> + c->c2.pulled_options_md5_init_done = false;
> + ret = PUSH_MSG_REPLY;
> + break;
> +   case 2:
> + ret = PUSH_MSG_CONTINUATION;
> + break;
> + }
> + }
>   }
>else if (ch == '\0')
>   {
> 

ACK

-Steffan

--
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
___
Openvpn-devel mailing list
Openvpn-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openvpn-devel


Re: [Openvpn-devel] hello

2016-10-05 Thread Samuli Seppänen
Il 05/10/2016 06:05, FELEX BANDUNG suppliers and agent electrical tools 
ha scritto:
>
>
> can i be member for openvpn devel group?
> i need to modification my server
>

Hi,

You don't need to be "member" to modify your OpenVPN server code. Just 
make the changes. If you distribute the modified server version to 
others, you need publish your changes according to the GPLv2 license[1].

Best regards,

-- 
Samuli Seppänen
Community Manager
OpenVPN Technologies, Inc

irc freenode net: mattock

[1] 

--
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
___
Openvpn-devel mailing list
Openvpn-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openvpn-devel