Re: [SSSD] [PATCH] sssd: incorrect checks on length values during packet, decoding

2015-08-31 Thread Jakub Hrozek
On Fri, Aug 21, 2015 at 04:20:15PM +0200, Petr Cech wrote: > On 07/23/2015 02:44 PM, Michal Židek wrote: > >Hi, > > > >see the attached patch for ticket > >https://fedorahosted.org/sssd/ticket/1697 > > > >I think this is a candidate to include in our > >coding guidelines. > > > I agree. It is a

Re: [SSSD] [PATCH] sssd: incorrect checks on length values during packet, decoding

2015-08-21 Thread Petr Cech
On 07/23/2015 02:44 PM, Michal Židek wrote: Hi, see the attached patch for ticket https://fedorahosted.org/sssd/ticket/1697 I think this is a candidate to include in our coding guidelines. I agree. It is a candidate. Thanks, Michal ___

[SSSD] [PATCH] sssd: incorrect checks on length values during packet, decoding

2015-07-23 Thread Michal Židek
?= mzi...@redhat.com Date: Wed, 22 Jul 2015 16:35:35 +0200 Subject: [PATCH] sssd: incorrect checks on length values during packet decoding https://fedorahosted.org/sssd/ticket/1697 It is safer to isolate the checked (unknown/untrusted) value on the left hand side in the conditions to avoid