[Bug 255892] sysutils/zfs-stats [patch] facilitate use with ssh

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Sat May 15 03:17:41 UTC 2021


https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=255892

            Bug ID: 255892
           Summary: sysutils/zfs-stats [patch] facilitate use with ssh
           Product: Ports & Packages
           Version: Latest
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Only Me
          Priority: ---
         Component: Individual Port(s)
          Assignee: mm at FreeBSD.org
          Reporter: david at catwhisker.org
             Flags: maintainer-feedback?(mm at FreeBSD.org)
          Assignee: mm at FreeBSD.org

Created attachment 224956
  --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=224956&action=edit
patch to allow zfs-stats to make use of ssh-agent

zfs-stats is a Perl script, and is invoked using /usr/bin/env; it also clears
the environment in the process, which is generally a Good Thing.

However, it also clears the SSH_AUTH_SOCK environment variable in the process,
which causes each invocation that is intended to use ssh to also request
authentication... which rather defeats a lot of the purpose of using (e.g.)
public key authentication.

The attached patch causes the script to clear all but the SSH_AUTH_SOCK
environment variable; the resulting script thus Just works when told to use
ssh.

If there's another (better) way to do this, I'm fine with that.  Having set
things up so I only need to enter my authentication information when I login to
my laptop, and can then ssh to other machines freely, it seemed a bit ...
undesirable ... to suddenly get requests to re-enter the information for each
query.

While I was here, I also inserted a "-x" flag in the ssh invocation: zfs-stats
certainly has no need to forward X11 for its statistics-gathering.

-- 
You are receiving this mail because:
You are the assignee for the bug.


More information about the freebsd-ports-bugs mailing list