Mail archive
alpine-user

[alpine-user] Re: YAML in Awall

From: Williams, Gareth <gareth_at_garethwilliams.me.uk>
Date: Fri, 11 May 2018 08:26:44 +0100

Hi,

A little bit of self-help has worked I think.

It seems that line 116 of /usr/share/lua/5.2/awall/policy.lua has:

yaml = { mod="lyaml", func="load" },


After changing it to:

yaml = { mod="yaml", func="load" },


everything works as expected. Whether that change has any
side-effects is beyond my understanding of Awall, but it seems to do
the trick.


I've raised bug 8874 for this - https://bugs.alpinelinux.org/issues/8874


Kind regards,


Gareth



On 10 May 2018 at 09:20, Williams, Gareth <gareth_at_garethwilliams.me.uk>
wrote:

> Hi all,
>
> Hopefully a very quick question - is YAML usable for awall rules in Alpine
> 3.7? I've tried and get an error:
>
> ------------------------------->8---------------------------------------
>
> /usr/local/share/lua/5.2/awall/policy.lua:128: module 'lyaml' not found:
> no field package.preload['lyaml']
> no file '/usr/local/share/lua/5.2/lyaml.lua'
> no file '/usr/local/share/lua/5.2/lyaml/init.lua'
> no file '/usr/share/lua/5.2/lyaml.lua'
> no file '/usr/share/lua/5.2/lyaml/init.lua'
> no file '/usr/local/lib/lua/5.2/lyaml.lua'
> no file '/usr/local/lib/lua/5.2/lyaml/init.lua'
> no file './lyaml.lua'
> no file '/usr/lib/lua/5.2/lyaml.lua'
> no file '/usr/lib/lua/5.2/lyaml/init.lua'
> no file './lyaml.lua'
> no file '/usr/local/lib/lua/5.2/lyaml.so'
> no file '/usr/local/lib/lua/5.2/loadall.so'
> no file '/usr/lib/lua/5.2/lyaml.so'
> no file '/usr/lib/lua/5.2/loadall.so'
> no file './lyaml.so'
> stack traceback:
> /usr/local/share/lua/5.2/awall/uerror.lua:25: in function
> </usr/local/share/lua/5.2/awall/uerror.lua:21>
> [C]: in function 'require'
> /usr/local/share/lua/5.2/awall/policy.lua:128: in function 'init'
> /usr/local/share/lua/5.2/awall/class.lua:31: in function
> </usr/local/share/lua/5.2/awall/class.lua:29>
> (...tail calls...)
> /usr/sbin/awall:163: in function 'f'
> /usr/local/share/lua/5.2/awall/uerror.lua:20: in function
> </usr/local/share/lua/5.2/awall/uerror.lua:20>
> [C]: in function 'xpcall'
> /usr/local/share/lua/5.2/awall/uerror.lua:19: in function 'call'
> /usr/sbin/awall:156: in main chunk
> [C]: in ?
>
> ---------------------------------------->8------------------
> ---------------
>
> I've installed the lua yaml packages.Searching the Alpine packages website
> for lyaml.lua or */lyaml/* yields nothing useful.
>
> Kind regards,
>
> Gareth
>



---
Unsubscribe:  alpine-user+unsubscribe_at_lists.alpinelinux.org
Help:         alpine-user+help_at_lists.alpinelinux.org
---
Received on Fri May 11 2018 - 08:26:44 GMT