Hide Forgot
Description of problem: smardcard support doesn't work Version-Release number of selected component (if applicable): spice-client-0.8.0-2.el6.x86_64 How reproducible: spicec -h localhost -p 5900 --smartcard --smartcard-db /home/kraxel/projects/ccid/db/ --smartcard-cert fedora,test1,test2 Actual results: get an error message: Error: unhandled exception: cmd line error Expected results: Works. Additional info: Tried to build from latest spice git tree instead. spicec accepts the command line then, but crashes.
script which creates the certificate db: #!/bin/sh DB="$(pwd)/db" echo "### reinit $DB" rm -rf "$DB" mkdir "$DB" set -ex certutil -d "$DB" -N certutil -d "$DB" -t "CT,C,C" -n test1 -S -s "CN=test1" -x -v 24 certutil -d "$DB" -t "CT,C,C" -n test2 -S -s "CN=test2" -x -v 24 certutil -d "$DB" -t "CT,C,C" -n test3 -S -s "CN=test3" -x -v 24 certutil -d "$DB" -t "CT,C,C" -n fedora -A -i ~/.fedora.cert certutil -d "$DB" -L
Fixed by upstream commit e1ec222. commit e1ec222e8bdf4b02f511666656ce1d6bd60d0988 Author: Alon Levy <alevy> Date: Fri Mar 4 09:36:49 2011 +0200 client/smartcard: handle the --smartcard-db option diff --git a/client/application.cpp b/client/application.cpp index ea88dc5..9257eb2 100644 --- a/client/application.cpp +++ b/client/application.cpp @@ -2271,7 +2271,7 @@ bool Application::process_cmd_line(int argc, char** argv, bool &full_screen) parser.add(SPICE_OPT_SMARTCARD_CERT, "smartcard-cert", "Use virtual reader+card with given cert(s)", "smartcard-cert", true); parser.set_multi(SPICE_OPT_SMARTCARD_CERT, ','); - parser.add(SPICE_OPT_SMARTCARD_DB, "smartcard-db", "Use given db for smartcard certs"); + parser.add(SPICE_OPT_SMARTCARD_DB, "smartcard-db", "Use given db for smartcard certs", "smartcard-db", true); #endif for (int i = SPICE_CHANNEL_MAIN; i < SPICE_END_CHANNEL; i++) { @@ -2395,6 +2395,9 @@ bool Application::process_cmd_line(int argc, char** argv, bool &full_screen) _smartcard_options->certs.end(), std::string(val)); } while ((val=parser.next_argument())); break; + case SPICE_OPT_SMARTCARD_DB: + _smartcard_options->dbname = val; + break; #endif case CmdLineParser::OPTION_HELP: parser.show_help();
VERIFIED in spice-client-0.8.2-7.el6.x86_64
Technical note added. If any revisions are required, please edit the "Technical Notes" field accordingly. All revisions will be proofread by the Engineering Content Services team. New Contents: Cause The --smartcard-db client command line option was not handled. Consequence Using --smartcard-db on the client results in an error message Error: unhandled exception: cmd line error. Fix Handle the --smartcard-db option Result "--smartcard-db" is now handled.
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. http://rhn.redhat.com/errata/RHBA-2011-1518.html