Commit Graph

296 Commits

Author SHA1 Message Date
Conrado P. L. Gouvea 40da5cace2 pkcs11-tool: add --allow-sw flag that removes CKF_HW and allows using software tokens 2020-09-28 12:59:58 +02:00
Hans-Christoph Steiner 410012f100 add env vars to bash completion for PIN-related options 2020-09-22 22:48:00 +02:00
Hans-Christoph Steiner 644eae691d standardize <replaceable> PIN names in man pages
This makes all PIN-related options use the exact same term throughout the
man pages.
2020-09-22 22:48:00 +02:00
Peter Marschall 16c889cf7d spelling fixes
Fix various spelling errors, mostly in comments but also in texts displayed.

Errors found & interactively fixed using 'codespell', with additional manual
checks after the fixes.
2020-08-30 10:35:14 +02:00
Ludovic Rousseau 8ada99b4d3 Fix spelling error
Thanks to Debian lintian:
I: opensc: typo-in-manual-page usr/share/man/man5/opensc.conf.5.gz
developement development
2020-08-29 23:30:32 +02:00
Ludovic Rousseau a70b082a09 Fix spelling error
Thanks to Debian lintian:
I: opensc: spelling-error-in-binary usr/bin/egk-tool arguement argument
2020-08-29 23:14:49 +02:00
Peter Marschall 4dbfc77eba opensc-explorer: extend do_asn1() to accept offsets
Have do_asn1() accept an optional parameter indicating an offset.
If this is given then start ASN.1-decoding the file/record at this offset.
2020-08-23 22:46:26 +02:00
Peter Marschall 45e7039940 opensc-explorer: extend do_asn1() to decode records
Have do_asn1() accept an optional parameter indicating a record number.
If this is given and the file is a record-oriented file, then ASN.1-decode
the record requested.
2020-08-23 22:46:26 +02:00
Peter Marschall d345c65a5d opensc-explorer: extend do_cat()
Have do_cat() accept an optional second parameter indicating a record number.
If this is given and the file is a record-oriented file, only print the record
requested.
2020-08-23 22:46:26 +02:00
Jakub Jelen 0defebfe05 doc: Recommend pin caching in combination with pin_cache_ignore_user_consent configuration option 2020-07-03 17:55:24 +02:00
Peter Marschall 5714dbfa08 opensc-explorer: add function 'get_record' 2020-06-05 14:48:08 +02:00
Piotr Majkrzak d4a9405bf4
Initial support for Polish eID card (e-dowód, eDO) (#2023) 2020-05-19 14:05:13 +02:00
Jakub Jelen 797414be05 Create missing man pages (goid needs some work) 2020-05-07 02:34:12 +02:00
Jakub Jelen b091165595 doc: Drop trailing comma 2020-05-07 02:34:12 +02:00
Frank Morgner c212776f45 fixed dashes 2020-02-27 23:12:54 +01:00
Frank Morgner 261e0b6b0d unified documentation of handling PIN/PUK on CLI 2020-02-27 23:12:54 +01:00
Frank Morgner 6b1770e7ad pkcs15-init: removed --options-file
use an environment variable to pass a hidden PIN code instead of the
options file

fixes 13814 Resource leak as reported by Coverity Scan
2020-02-27 23:12:54 +01:00
Frank Morgner 0cd19b59e1 pkcs11-tool: add --usage-wrap (disabled by default)
fixes https://github.com/OpenSC/OpenSC/issues/1913
2020-02-01 22:29:35 +01:00
Peter Marschall a0adbc9ef2 dnie-tool: cleanup
- remove command line option '--card-driver';
- instead force driver 'dnie' and fail if card is not a DNIe card
- overhaul option parsing
  - remove unused variable 'long_optind'
  - bail out with usage message on all unknown/unhandled args
  - correctly terminate option parsing (no infinite loop)
- slight refactoring
  - avoid magic constant '0x0f'
  - make variable 'tries_left' more local
  - move dependent code into if block
2020-01-12 09:42:09 +01:00
Peter Marschall 58ecb4aba2 cardos-tool: cleanup
- remove command line option '--card-driver';
- instead force driver 'cardos' and fail if card is not a CardOS card
- overhaul option parsing
      - remove unused variable 'long_optind'
      - bail out with usage message on all unknown/unhandled args
      - correctly terminate option parsing (no infinite loop)
2020-01-12 09:40:54 +01:00
Peter Marschall 04f4f589a1 piv-tool: cleanup
- remove command line option '--card-driver';
- instead force driver 'PIV-II' and fail if card is not a PIV card
- overhaul option parsing
  - remove unused variable 'long_optind'
  - make work option '--reader' ( "r:" was missing in the optstring!!!)
  - bail out with usage message on all unknown/unhandled args
  - correctly terminate option parsing (no infinite loop)
2020-01-12 09:40:53 +01:00
Peter Marschall 5514a0529f dnie-tool: rename option '--driver' to '--card-driver'
Rename option '--driver' to '--card-driver' for increased consistency.

In addition, extend it the same way opensc-explorer was extended. I.e.
treat the question mark given as argument to option '--card-driver'
special: list all available drivers instead of stupidly bailing out.

In contrast to opensc-tool and opensc-explorer, which are card-agnostic,
I am not sure whether the option '--card-driver' makes sense on this
card-specific tool.
2020-01-12 09:36:49 +01:00
Peter Marschall a10368769c cardos-tool: make '--card-driver ?' list all available drivers
Extend cardos-tool the same way opensc-explorer was extended. I.e.
treat the question mark given as argument to option '--card-driver'
special: list all available drivers instead of stupidly bailing out.

In contrast to opensc-tool and opensc-explorer, which are card-agnostic,
I am not sure whether the option '--card-driver' makes sense on this
card-specific tool.
2020-01-12 09:36:49 +01:00
Peter Marschall 30fdc7de4a piv-tool: make '--card-driver ?' list all available drivers
Extend piv-tool the same way opensc-explorer was extended. I.e.
treat the question mark given as argument to option '--card-driver'
special: list all available drivers instead of stupidly bailing out.

In contrast to opensc-tool and opensc-explorer, which are card-agnostic,
I am not sure whether the option '--card-driver' makes sense on this
card-specific tool.
2020-01-12 09:36:49 +01:00
Peter Marschall 94288b438e opensc-tool: make '--card-driver ?' list all available drivers
Extend opensc-tool the same way opensc-explorer was extended. I.e.
treat the question mark given as argument to option '--card-driver'
special: list all available drivers instead of stupidly bailing out.
2020-01-12 09:36:49 +01:00
Peter Marschall 5da40bf027 opensc-explorer: make '--card-driver ?' list all available drivers
Make opensc-explorer a bit more user friendly by treating the question mark
given as argument to option '--card-driver' special: list all available
drivers instead of stupidly bailing out.
2020-01-12 09:36:49 +01:00
Arnout Engelen a3ee8cefc8 Generate consistent docbook id's 2019-11-01 14:23:40 +01:00
Vicente Jimenez Aguilar d4a97c6959 [DOC] dnie-tool -a option includes sw version 2019-09-16 13:50:10 +02:00
Peter Popovec 426772298a pkcs15-tool: inconsistent -r option fix
Option -r is used in other opensc tools to specify card reader.  pkcs15-tool
uses -r to specify cerfificate.  This fix intorduces warning message if -r
is used, and for future versions of pkcs15-tool -r is used to specify
reader.
2019-08-05 01:14:35 +02:00
Jakub Jelen 368563ddd6 doc: Fix the description of switch in manual page (copy&paste error) 2019-06-17 12:49:11 +02:00
Raul Metsma 3a192e2c87 pkcs11-tool: Add extractable option to key import
Signed-off-by: Raul Metsma <raul@metsma.ee>
2019-06-03 10:59:58 +02:00
Raul Metsma 91a1dd9af4 Option to delete object by index
Signed-off-by: Raul Metsma <raul@metsma.ee>
2019-04-17 14:38:40 +02:00
Jakub Jelen fc4d600634 pkcs11-tool: Allow to set CKA_ALLOWED_MECHANISMS when creating an objects
Also list them in the attributes listing
2019-04-08 11:15:19 +02:00
Frank Morgner 71b85d15e4 opensc.conf: Configure handling of private_certificate
possible choices: ignore, protect, declassify

fixes https://github.com/OpenSC/OpenSC/issues/1430
2019-03-13 21:18:57 +01:00
opensignature 84f0a88edb Remove postecert and infocamere support because no longer issued (#1584)
* Remove postecert and infocamere support because no longer issued

* Remove wrong changes

* reset NEWS

* EC_POINT_set_affine_coordinates_GFp and EC_POINT_get_affine_coordinates_GFp are
deprecated, use EC_POINT_set_affine_coordinates and EC_POINT_get_affine_coordinates

* If OPENSSL API version is < 3 use old functions EC_POINT_[sg]et_affine_coordinates_GFp

* Move the OpenSSL compatibility stuff to src/libopensc/sc-ossl-compat.h
2019-01-30 22:01:24 +01:00
Jakub Jelen f161c3a178 Remove repeated words from manual pages 2019-01-23 20:41:01 +01:00
Mat e19fe680c4 Add object type "secrkey" to help of --type switch in pkcs11-tool (#1575)
* Add object type "secrkey" to help of --type switch in pkcs11-tool

Reading an object with pkcs11-tool requires the `--type` switch. The help for that switch is currently incomplete as it is missing the (not very friendly named" *secrkey* option used to read out a secret key object.

I have added this information to the help description.

* Update man page

Describe secrkey option of pkcs11-tool's --type switch in man page
2019-01-15 07:32:41 +01:00
Frank Morgner 1eda4c1795 sc-hsm-tool: add support for initializing biometry 2019-01-15 07:31:20 +01:00
Frank Morgner b11cc3871e tools: harmonize card initialization 2018-12-18 14:50:45 +01:00
Jakub Jelen 8fb611bb1c Move the test into separate directory
Signed-off-by: Jakub Jelen <jjelen@redhat.com>
2018-12-06 09:27:50 +01:00
Hannu Honkanen 9e5a324903 Edited according to PR review: CKA_ALWAYS_AUTHENTICATE only associated with private keys. Defined a custom attribute to achieve same functionality with secret keys. Updated man pages. 2018-12-05 12:10:42 +01:00
Frank Morgner b01ca2dcc9
added support for colors (#1534)
because everyone loves colors
2018-11-25 22:08:36 +01:00
Peter Marschall 85258f2951 openpgp-tool: use key type to indicate key to generate
Instead of only expecting a key length, and implicitly assuming RSA
as the key algorithm, introduce option --key-type to pass the key type
as a string.

When generating the key determine key algorithm and attributes based on
the key type passed.

If no key was given, default to "rsa2048".
2018-11-06 12:41:19 +01:00
Peter Marschall c9f5e05aca openpgp-tool: new option --key-info to display key info 2018-11-06 12:41:19 +01:00
Peter Marschall 1866c3e930 openpgp-tool: new option --card-info to display card info 2018-11-06 12:41:19 +01:00
Jakub Jelen 9a853176b8 pkcs11-tool: Support for signature verification
Signed-off-by: Jakub Jelen <jjelen@redhat.com>
2018-09-30 21:23:27 +02:00
Jakub Jelen fb94b639bc doc: Fix the pkcs11-tool example
Signed-off-by: Jakub Jelen <jjelen@redhat.com>
2018-09-30 21:23:27 +02:00
Peter Marschall f471048ef7 remove source-less doc/tools/files.html
The current version, which gets re-generated from XML source, is in doc/files/.
2018-09-30 18:40:55 +02:00
Peter Marschall 9616ad4d94 opensc-explorer: fix&clarify handling of interactive mode
* make 'interactive' a global variable
* set it when opensc was called with the SCRIPT argument
* document the behaviour in the manual page

Make interactive a global variable and set it in main.
2018-09-24 00:03:13 +02:00
Peter Marschall c9db3f7385 opensc-explorer: allow arguments for 'help'
When arguments are given, compare them like ambguous_match() does,
and show the matching ones only.

Add documentation of the 'help' command to the manual page.

In main loop on multiple matches, show help on matching commands only.
2018-09-24 00:03:13 +02:00