michaelrsweet / hp-printer-app

Example printer application for HP PCL printers using PAPPL.
Apache License 2.0
35 stars 7 forks source link

Saving Printer Configuration Causes Dropped HTTPS Connection #9

Closed sjoubani closed 2 years ago

sjoubani commented 3 years ago

Describe the bug When saving a printer's configuration (POST to /config), the server-side connection is dropped, though the process itself doesn't terminate.

To Reproduce Steps to reproduce the behavior:

  1. Built on macOS (10.15, libpng 1.6.37, libusb 1.0.24, libjpeg 9d, PAPPL 1.0.3, h-p-a 66aba65)
  2. Launch with "server" command
  3. Browse in Safari and add a printer
  4. Edit the printer's configuration (location, contact, etc)
  5. Save changes

Expected behavior POST succeeds and redirects to configuration page

Screenshots

Screen Shot 2021-08-23 at 5 00 10 PM

System Information:

Additional context This seems to be the only POST with this behavior, at least in this build

michaelrsweet commented 3 years ago

@sjoubani Can you provide a debug log from this? I suspect the issue is in how Apple has changed keychain security in macOS, and that the self-signed certificate is not accessible to the printer application, causing this failure.

sjoubani commented 3 years ago

@michaelrsweet The SSL connection works fine, and I've deliberately set HOME to a special location for the creation of .cups/ ssl.keychain. I've also set log-file and log-level as you requested to capture this: hp-printer-app.log

michaelrsweet commented 2 years ago

This seems to be fixed now.