To be more precise, this is my little game: r...@dell:~# cat /usr/local/bin/augtool_shell #!/bin/sh /usr/bin/augtool -r$HOME
r...@dell:~# getent passwd raphink raphink:x:1001:1001:Raphael Pinson:/home/raphink:/usr/local/bin/augtool_shell r...@dell:~# find /home/raphink/ /home/raphink/ /home/raphink/etc /home/raphink/etc/hosts /home/raphink/etc/services /home/raphink/.cache /home/raphink/.cache/motd.legal-displayed r...@dell:~# login raphink Password: Last login: Fri Nov 19 00:39:52 CET 2010 on pts/1 Linux dell 2.6.32-25-generic #45-Ubuntu SMP Sat Oct 16 19:48:22 UTC 2010 i686 GNU/Linux Ubuntu 10.04.1 LTS Welcome to Ubuntu! * Documentation: https://help.ubuntu.com/ *** System restart required *** augtool> print /files/etc/hosts/3 /files/etc/hosts/3 /files/etc/hosts/3/ipaddr = "::1" /files/etc/hosts/3/canonical = "localhost" /files/etc/hosts/3/alias[1] = "ip6-localhost" /files/etc/hosts/3/alias[2] = "ip6-loopback" augtool> set /files/etc/hosts/3/alias[last()+1] "localhost-ipv6" augtool> save Saved 1 file(s) augtool> quit r...@dell:~# grep "^::1" /home/raphink/etc/hosts ::1 localhost ip6-localhost ip6-loopback localhost-ipv6 Upon thinking about it a bit, I can see some great potential in this actually, to prevent providing web interfaces or such things to people who only need to modify a few conf files on a machine and don't need a full shell access. Raphael 2010/11/19 Raphaël Pinson <[email protected]> > Hi guys, > > Just for fun, I tried using /usr/bin/augtool as a shell for a user. It > works, I just can't think of a use case that would be practical, maybe > providing an interface of a maintenance team to only modify some conffiles > and do nothing else. > > I just thought I'd share this in case it inspires some of you :-) > > > Raphael >
_______________________________________________ augeas-devel mailing list [email protected] https://www.redhat.com/mailman/listinfo/augeas-devel
