[Bug 1659358] [NEW] /etc/auto.sb is not directly usable in yakkety

Alexander Lelyakin Alexander.Lelyakin at googlemail.com
Wed Jan 25 16:53:16 UTC 2017


Public bug reported:

lsb_release -rd
Description:	Ubuntu 16.10
Release:	16.10
apt-cache policy autofs
autofs:
  Installed: 5.1.1-1ubuntu3
  Candidate: 5.1.1-1ubuntu3
  Version table:
 *** 5.1.1-1ubuntu3 500
        500 http://de.archive.ubuntu.com/ubuntu yakkety/main amd64 Packages
        100 /var/lib/dpkg/status

Package autofs ships with shell script installed as /etc/auto.smb

This script is not directly usable (at least in yakkety)
It has following issues:

1. Shell variables ${UID} and ${GID} will be 0 when script is called from automounter.
   Correct variables should be ${AUTOFS_UID} and ${AUTOFS_GID}.

2. Default location of kerberos cache file (at least if created by pam_krb5.so) 
   is not /tmp/krb5cc_<UID> but /tmp/krb5cc_<UID>_<random>

So instead of 
----
    if [ -f /tmp/krb5cc_$uid ] && klist -s /tmp/krb5cc_$uid; then
            cache=/tmp/krb5cc_$uid
            return
    fi
----
should be something like that
----
    for krbc in /tmp/krb5cc_$uid_*; do
        if klist -s $krbc; then
            cache=$krbc
            return
        fi
    done
----

** Affects: autofs (Ubuntu)
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to autofs in Ubuntu.
https://bugs.launchpad.net/bugs/1659358

Title:
  /etc/auto.sb is not directly usable in yakkety

Status in autofs package in Ubuntu:
  New

Bug description:
  lsb_release -rd
  Description:	Ubuntu 16.10
  Release:	16.10
  apt-cache policy autofs
  autofs:
    Installed: 5.1.1-1ubuntu3
    Candidate: 5.1.1-1ubuntu3
    Version table:
   *** 5.1.1-1ubuntu3 500
          500 http://de.archive.ubuntu.com/ubuntu yakkety/main amd64 Packages
          100 /var/lib/dpkg/status

  Package autofs ships with shell script installed as /etc/auto.smb

  This script is not directly usable (at least in yakkety)
  It has following issues:

  1. Shell variables ${UID} and ${GID} will be 0 when script is called from automounter.
     Correct variables should be ${AUTOFS_UID} and ${AUTOFS_GID}.

  2. Default location of kerberos cache file (at least if created by pam_krb5.so) 
     is not /tmp/krb5cc_<UID> but /tmp/krb5cc_<UID>_<random>

  So instead of 
  ----
      if [ -f /tmp/krb5cc_$uid ] && klist -s /tmp/krb5cc_$uid; then
              cache=/tmp/krb5cc_$uid
              return
      fi
  ----
  should be something like that
  ----
      for krbc in /tmp/krb5cc_$uid_*; do
          if klist -s $krbc; then
              cache=$krbc
              return
          fi
      done
  ----

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/autofs/+bug/1659358/+subscriptions



More information about the foundations-bugs mailing list