Seems this is a dormant thread. However, I recently started running into the same -9923 error when attempting to scan via AirPrint. Scanning like this (from multiple Macs running macOS 10.11+) had worked fine for as long as I've owned the LaserJet M277dw — at least 12 months. I tried all these solutions mentioned but no joy.
What solved it for me was turning the firewall OFF on the printer. Via the printer's web interface, go to the "Networking" tab, select "Firewall" in the left column list (was at the bottom of the list for me), remove the check mark in "Enable Firewall", then "Apply".
What's daft about this is the printer's firewall was ON for the last 12+ months and scanning worked fine!