Skip to content

Commit

Permalink
Merge pull request #49 from vjardin/fix_openScv1
Browse files Browse the repository at this point in the history
Fix OpenSC v1
  • Loading branch information
gamringer committed Feb 13, 2021
2 parents e0a62bd + d852d70 commit 1d4bffb
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 4 deletions.
3 changes: 2 additions & 1 deletion tests/0270-oasis_Random.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,8 @@ $rv = $module->C_OpenSession($s[0], Pkcs11\CKF_SERIAL_SESSION, null, null, $sess
// TBC $session = new Pkcs11\Session($module, $s[0], Pkcs11\CKF_SERIAL_SESSION); # aka C_OpenSession()

$rv = $module->C_SeedRandom($session, '1603soixantedix8');
if ($rv === Pkcs11\CKR_RANDOM_SEED_NOT_SUPPORTED)
if (($rv === Pkcs11\CKR_RANDOM_SEED_NOT_SUPPORTED) ||
($rv === Pkcs11\CKR_FUNCTION_NOT_SUPPORTED))
$rv = 0; # XXX fake, ignore any smart cards that do not support SeedRandom
var_dump($rv);

Expand Down
2 changes: 1 addition & 1 deletion tests/0280-oasis_FindObjects.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ int(0)
int(0)
object(Pkcs11\Session)#2 (2) {
["hSession"]=>
int(1)
int(%d)
["slotID"]=>
int(%d)
}
Expand Down
2 changes: 1 addition & 1 deletion tests/0290-oasis_FindObjects.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ int(0)
int(0)
object(Pkcs11\Session)#2 (2) {
["hSession"]=>
int(1)
int(%d)
["slotID"]=>
int(%d)
}
Expand Down
2 changes: 1 addition & 1 deletion tests/0291-oasis_FindObjects.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ int(0)
int(0)
object(Pkcs11\Session)#2 (2) {
["hSession"]=>
int(1)
int(%d)
["slotID"]=>
int(%d)
}
Expand Down

0 comments on commit 1d4bffb

Please sign in to comment.