Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixing compilation issues and tests for recent Luna client. #11

Merged
merged 1 commit into from
Jan 7, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion pkcs11_luna/ext/generate_constants.rb
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ def start!
next if constants_hash[const_name].nil?
const_group_def = constants_hash[const_name][0]
const_value = constants_hash[const_name][1]
fd_const.puts "#{const_group_def}(#{const_name}); /* #{const_value} */"
fd_const.puts "#{const_group_def}(#{const_name}); // #{const_value} "
constants_hash[const_name] = nil
end
end
Expand Down
1 change: 1 addition & 0 deletions pkcs11_luna/ext/pk11l.c
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ static VALUE aCK_MECHANISM_INFO_members;
static VALUE cCK_SESSION_INFO;
static VALUE aCK_SESSION_INFO_members;
static VALUE cCK_MECHANISM;
static VALUE cCK_ATTRIBUTE;

static VALUE vOBJECT_CLASSES;
static VALUE vATTRIBUTES;
Expand Down
2 changes: 1 addition & 1 deletion pkcs11_luna/test/test_pkcs11_luna.rb
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ def test_init_token
pkcs11 = @pk
slot = Slot.new(pkcs11, @slot)

assert_raises(Luna::CKR_OPERATION_NOT_ALLOWED, CKR_USER_TYPE_INVALID) {
assert_raises(Luna::CKR_OPERATION_NOT_ALLOWED, CKR_DATA_LEN_RANGE, CKR_USER_TYPE_INVALID) {
slot.init_token("anypin", "new_label")
}
end
Expand Down
2 changes: 1 addition & 1 deletion pkcs11_luna/test/test_pkcs11_luna_crypt.rb
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ def test_generate_rsa_key_pair
destroy_object(@session, priv_label)

pub_attr = {ENCRYPT: true, VERIFY: true,
MODULUS_BITS: 2048, TOKEN: true, WRAP: true, LABEL: pub_label}
MODULUS_BITS: 2048, TOKEN: true, WRAP: true, LABEL: pub_label, PUBLIC_EXPONENT: [0x01, 0x00, 0x01].pack('C*')}
priv_attr = {DECRYPT: true, SIGN: true, SENSITIVE: true, PRIVATE: true,
TOKEN: true, UNWRAP: true, LABEL: priv_label}

Expand Down