[augeas-devel] PAM SSHD put error

David Lutterkort lutter at redhat.com
Mon Jul 19 20:17:43 UTC 2010


[ Forgot to cc augeas-devel ]

On Mon, 2010-07-19 at 12:26 -0600, Erinn Looney-Triggs wrote:
> Can someone break this down for me, what went wrong here?
> 
> /augeas/files/etc/pam.d/sshd/error = "put_failed"
> /augeas/files/etc/pam.d/sshd/error/path = "/files/etc/pam.d/sshd/01"
> /augeas/files/etc/pam.d/sshd/error/lens =
> "/usr/share/augeas/lenses/dist/pam.aug:29.17-37.16:"
> /augeas/files/etc/pam.d/sshd/error/message = "Failed to match \n    {
> /optional/ }?{ /type/ = /auth|session|account|password/ }{ /control/ =
> /\\\\[[^]\\001-\\004\\n#]*\\\\]|[^\\001-\\004\\t [][^\\001-\\004\\t ]*/
> }{ /module/ = /[^\\001-\\004\\t\\n #]+/ }{ /argument/ =
> /[^\\001-\\004\\t\\n #]+/ }*({ /#comment/ = /[^\\001-\\004\\t\\n
> ][^\\001-\\004\\n]*[^\\001-\\004\\t\\n ]|[^\\001-\\004\\t\\n ]/ } |
> ())\n  with tree\n    { \"type\" = \"auth\" } { \"control\" =
> \"required\" } { \"module\" = \"pam_tally2.so\" } { \"arguement\" =
> \"deny=5\" } { \"argument\" = \"onerr=fail\" }"

It's augeas' way to say that the tree you tried to save does not match
the tree it expected. The first bunch of stuff (before the "with tree")
in slightly better formatting is

        { /optional/ }?
        { /type/ = /auth|session|account|password/ }
        { /control/ = /\\\\[[^]\\001-\\004\\n#]*\\\\]|[^\\001-\\004\\t [][^\\001-\\004\\t ]*/}
        { /module/ = /[^\\001-\\004\\t\\n #]+/ }
        { /argument/ =/[^\\001-\\004\\t\\n #]+/ }*
        ({ /#comment/ = /[^\\001-\\004\\t\\n][^\\001-\\004\\n]*[^\\001-\\004\\t\\n ]|[^\\001-\\004\\t\\n ]/ } |())
        
Each of the { l = v } should match on tree node, with l matching the
label of the node, and v the value. Those nodes should be siblings.

You had (the stuff after 'with tree'):

        { "type" = "auth" }
        { "control" = "required" }
        { "module\" = \"pam_tally2.so\" }
        { \"arguement\" =\"deny=5\" }          # <--- there's your problem; you misspelled 'argument'
        { \"argument\" = \"onerr=fail\" }
        
David

        
        





More information about the augeas-devel mailing list