Handle “already closed” errors properly.
Fix broken plist ref.
Misc fixes

Fix runtime errors due to missing setMode.
Clean up message handling a little - still want to do a big refactor.
Put requires challenge behind a flag.