Apple - Auval and Auvaltool not working through SSH

This is a long shot, but I once had to install tmux with brew install tmux (and I already had https://brew.sh set up and ready to run) so that I could graphically log in and establish a terminal session for the user in question.

With fast user switching, you can then return to the log in screen - leaving that one user console session blessed with full GPU and full graphical console permissions and then ssh in to attach to the existing TMUX sessions.

Hopefully someone has a more direct answer, but after several days of bounties and some great comments trying to back into the answer, I wanted to get on the record that a graphical log in does have higher powers and permissions and you just might need that for now if no-one has a better fix for this.


I found another workaround which is still not pretty, but less invasive. I implemented a small python-http server which expects the auval arguments as url-get parameters. If this python-server now is started using a non-ssh session, it is possible to validate all plugins using the http-get call. Below is the code for the small server.

from http.server import HTTPServer, BaseHTTPRequestHandler
import subprocess
from urllib.parse import urlparse, parse_qs

import traceback


def run_auval(params):
    arguments = ["auval", "-v", params["type"], params["subtype"], params["manufactor"]]
    print("Running AUVal: {}".format(arguments))
    process_return = subprocess.run(arguments, capture_output=True)
    return process_return.stdout + process_return.stderr, process_return.returncode


class SimpleHTTPRequestHandler(BaseHTTPRequestHandler):
    def do_GET(self):
        raw_params = parse_qs(urlparse(self.path).query)
        params = {}
        for key, value in raw_params.items():
            params[key] = value[0]

        try:
            output, return_code = run_auval(params)
        except:
            self.send_response(500)
            self.end_headers()
            self.wfile.write(str.encode(traceback.format_exc()))
            return

        self.send_response(200)
        self.end_headers()
        self.wfile.write(output)


if __name__ == "__main__":
    httpd = HTTPServer(("0.0.0.0", 8000), SimpleHTTPRequestHandler)
    httpd.serve_forever()

You can then use wget or an equivalent from an SSH session to get the result of au validation.

With the server running, output goes to auval_log.txt where you can search for FAILURE or SUCCESS:

wget "http://localhost:8000?type=aufx&subtype=Abcd&manufactor=Dlby" -O auval_log.txt

This is equivalent to running

auval -v aufx Abcd Dlby

but without the SSH issues

Tags:

Ssh

Audio

Mojave