All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] checkpolicy: Treat invalid characters as an error
@ 2020-03-10 14:41 Daniel Burgener
  2020-03-10 19:19 ` James Carter
  0 siblings, 1 reply; 3+ messages in thread
From: Daniel Burgener @ 2020-03-10 14:41 UTC (permalink / raw)
  To: selinux

Previously the behavior was to warn, discard the character and proceed. Now the build will halt upon encountering an expected character.

Signed-off-by: Daniel Burgener <dburgener@linux.microsoft.com>
---
 checkpolicy/policy_scan.l | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/checkpolicy/policy_scan.l b/checkpolicy/policy_scan.l
index e2f676e4..8c100f3d 100644
--- a/checkpolicy/policy_scan.l
+++ b/checkpolicy/policy_scan.l
@@ -290,7 +290,7 @@ GLBLUB				{ return(GLBLUB); }
 "]" |
 "~" |
 "*"				{ return(yytext[0]); } 
-.                               { yywarn("unrecognized character");}
+.                               { yyerror("unrecognized character");}
 %%
 int yyerror(const char *msg)
 {
-- 
2.24.1


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] checkpolicy: Treat invalid characters as an error
  2020-03-10 14:41 [PATCH] checkpolicy: Treat invalid characters as an error Daniel Burgener
@ 2020-03-10 19:19 ` James Carter
  2020-03-11 18:18   ` James Carter
  0 siblings, 1 reply; 3+ messages in thread
From: James Carter @ 2020-03-10 19:19 UTC (permalink / raw)
  To: Daniel Burgener; +Cc: SElinux list

On Tue, Mar 10, 2020 at 10:42 AM Daniel Burgener
<dburgener@linux.microsoft.com> wrote:
>
> Previously the behavior was to warn, discard the character and proceed. Now the build will halt upon encountering an expected character.
>
> Signed-off-by: Daniel Burgener <dburgener@linux.microsoft.com>

Acked-by: James Carter <jwcart2@gmail.com>


> ---
>  checkpolicy/policy_scan.l | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/checkpolicy/policy_scan.l b/checkpolicy/policy_scan.l
> index e2f676e4..8c100f3d 100644
> --- a/checkpolicy/policy_scan.l
> +++ b/checkpolicy/policy_scan.l
> @@ -290,7 +290,7 @@ GLBLUB                              { return(GLBLUB); }
>  "]" |
>  "~" |
>  "*"                            { return(yytext[0]); }
> -.                               { yywarn("unrecognized character");}
> +.                               { yyerror("unrecognized character");}
>  %%
>  int yyerror(const char *msg)
>  {
> --
> 2.24.1
>

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] checkpolicy: Treat invalid characters as an error
  2020-03-10 19:19 ` James Carter
@ 2020-03-11 18:18   ` James Carter
  0 siblings, 0 replies; 3+ messages in thread
From: James Carter @ 2020-03-11 18:18 UTC (permalink / raw)
  To: Daniel Burgener; +Cc: SElinux list

On Tue, Mar 10, 2020 at 3:19 PM James Carter <jwcart2@gmail.com> wrote:
>
> On Tue, Mar 10, 2020 at 10:42 AM Daniel Burgener
> <dburgener@linux.microsoft.com> wrote:
> >
> > Previously the behavior was to warn, discard the character and proceed. Now the build will halt upon encountering an expected character.
> >
> > Signed-off-by: Daniel Burgener <dburgener@linux.microsoft.com>
>
> Acked-by: James Carter <jwcart2@gmail.com>
>
>

Thanks, applied.
Jim

> > ---
> >  checkpolicy/policy_scan.l | 2 +-
> >  1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/checkpolicy/policy_scan.l b/checkpolicy/policy_scan.l
> > index e2f676e4..8c100f3d 100644
> > --- a/checkpolicy/policy_scan.l
> > +++ b/checkpolicy/policy_scan.l
> > @@ -290,7 +290,7 @@ GLBLUB                              { return(GLBLUB); }
> >  "]" |
> >  "~" |
> >  "*"                            { return(yytext[0]); }
> > -.                               { yywarn("unrecognized character");}
> > +.                               { yyerror("unrecognized character");}
> >  %%
> >  int yyerror(const char *msg)
> >  {
> > --
> > 2.24.1
> >

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2020-03-11 18:17 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-03-10 14:41 [PATCH] checkpolicy: Treat invalid characters as an error Daniel Burgener
2020-03-10 19:19 ` James Carter
2020-03-11 18:18   ` James Carter

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.