Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 490140 - sys-process/fcron - fcrontab invokes pam_mount with insufficient privileges when pam_mount is enabled in /etc/pam.d/system-auth
Summary: sys-process/fcron - fcrontab invokes pam_mount with insufficient privileges w...
Status: RESOLVED NEEDINFO
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: AMD64 Linux
: Normal normal (vote)
Assignee: Thomas Deutschmann (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-11-02 15:01 UTC by James Dominy
Modified: 2022-04-12 07:25 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
emerge --info (file_490140.txt,5.51 KB, text/plain)
2013-11-02 15:01 UTC, James Dominy
Details

Note You need to log in before you can comment on or make changes to this bug.
Description James Dominy 2013-11-02 15:01:40 UTC
Created attachment 362426 [details]
emerge --info

I am using pam_mount and LUKS for an encrypted home partition. Various invocations of frcontab as root (-e, -l) work, but a warning is issued about pam_mount being invoked with insufficient priviliges.

root@server ~$ fcrontab -l
2013-11-02 16:54:09  INFO listing root's fcrontab
# for fcron 
# $Header: /var/cvsroot/gentoo-x86/sys-process/fcron/files/crontab,v 1.3 2013/03/03 16:28:06 wschlich Exp $

# fcron:
# This is NOT the system crontab! fcron does not support a system crontab.
# to get /etc/cron.{hourly|daily|weekly|montly} working with fcron run
# crontab /etc/crontab
# as root.
# NOTE: This will REPLACE root's current crontab!!

# Global variables
SHELL=/bin/bash
PATH=/sbin:/bin:/usr/sbin:/usr/bin
MAILTO=root
HOME=/

# check scripts in cron.hourly, cron.daily, cron.weekly and cron.monthly
59  *  * * *    rm -f /var/spool/cron/lastrun/cron.hourly
9  3  * * *     rm -f /var/spool/cron/lastrun/cron.daily
19 4  * * 6     rm -f /var/spool/cron/lastrun/cron.weekly
29 5  1 * *     rm -f /var/spool/cron/lastrun/cron.monthly
*/10  *  * * *  test -x /usr/sbin/run-crons && /usr/sbin/run-crons

(pam_mount.c:538): *** PAM_MOUNT WAS INVOKED WITH INSUFFICIENT PRIVILEGES. (euid=101)
(pam_mount.c:539): *** THIS IS A BUG OF THE CALLER. CONSULT YOUR DISTRO.
(pam_mount.c:540): *** Also see bugs.txt in the pam_mount source tarball/website documentation.

Reproducible: Always
Comment 1 Thomas Deutschmann (RETIRED) gentoo-dev 2016-11-17 22:24:51 UTC
> [...] but a warning is issued about pam_mount being invoked with insufficient
> priviliges

Do you get this warning on every command (like "fcrondyn -u root -l") from a fcron instance running as root?

And please retry with latest sys-process/fcron-3.2.1.
Comment 2 James Dominy 2017-08-20 10:55:10 UTC
Nope, just for fcron itself; see below.

root@server ~ # fcrondyn -x ls
ID   |USER     |SCHEDULE        |CMD
2    |root     |2017-08-20 12:50|test -x /usr/sbin/run-crons && /usr/sbin/run-crons
6    |root     |2017-08-20 12:59|rm -f /var/spool/cron/lastrun/cron.hourly
5    |root     |2017-08-21 03:09|rm -f /var/spool/cron/lastrun/cron.daily
4    |root     |2017-08-26 04:19|rm -f /var/spool/cron/lastrun/cron.weekly
3    |root     |2017-09-01 05:29|rm -f /var/spool/cron/lastrun/cron.monthly
connection closed by fcron
root@server ~ # crontab -l
2017-08-20 12:44:12  INFO listing root's fcrontab
# for fcron
# $Header: /var/cvsroot/gentoo-x86/sys-process/fcron/files/crontab,v 1.3 2013/03/03 16:28:06 wschlich Exp $

# fcron:
# This is NOT the system crontab! fcron does not support a system crontab.
# to get /etc/cron.{hourly|daily|weekly|montly} working with fcron run
# crontab /etc/crontab
# as root.
# NOTE: This will REPLACE root's current crontab!!

# Global variables
SHELL=/bin/bash
PATH=/sbin:/bin:/usr/sbin:/usr/bin
MAILTO=root
HOME=/

# check scripts in cron.hourly, cron.daily, cron.weekly and cron.monthly
59  *  * * *    rm -f /var/spool/cron/lastrun/cron.hourly
9  3  * * *     rm -f /var/spool/cron/lastrun/cron.daily
19 4  * * 6     rm -f /var/spool/cron/lastrun/cron.weekly
29 5  1 * *     rm -f /var/spool/cron/lastrun/cron.monthly
*/10  *  * * *  test -x /usr/sbin/run-crons && /usr/sbin/run-crons

@mail(false) 12h /sbin/fstrim
(pam_mount.c:538): *** PAM_MOUNT WAS INVOKED WITH INSUFFICIENT PRIVILEGES. (euid=101)
(pam_mount.c:539): *** THIS IS A BUG OF THE CALLER. CONSULT YOUR DISTRO.
(pam_mount.c:540): *** Also see bugs.txt in the pam_mount source tarball/website documentation.


also, I'm using 3.2.1-r2