gssapi 1.1.1 → 1.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.1.1
1
+ 1.1.2
@@ -308,6 +308,9 @@ module GSSAPI
308
308
  # Remember to free the allocated output_message_buffer with gss_release_buffer
309
309
  attach_function :gss_unwrap, [:pointer, :pointer, :pointer, :pointer, :pointer, :pointer], :OM_uint32
310
310
 
311
+ # OM_uint32 gss_get_mic(OM_uint32 * minor_status, const gss_ctx_id_t context_handle, gss_qop_t qop_req, const gss_buffer_t input_message_buffer, gss_buffer_t output_message_buffer)
312
+ attach_function :gss_get_mic, [:pointer, :pointer, :OM_uint32, :pointer, :pointer], :OM_uint32
313
+
311
314
  # OM_uint32 gss_delete_sec_context(OM_uint32 * minor_status, gss_ctx_id_t * context_handle, gss_buffer_t output_token);
312
315
  attach_function :gss_delete_sec_context, [:pointer, :pointer, :pointer], :OM_uint32
313
316
 
@@ -131,6 +131,20 @@ module GSSAPI
131
131
  out_tok.length > 0 ? out_tok.value : true
132
132
  end
133
133
 
134
+
135
+ def get_mic(token)
136
+
137
+ min_stat = FFI::MemoryPointer.new :OM_uint32
138
+ qop_req = GSSAPI::LibGSSAPI::GSS_C_QOP_DEFAULT
139
+ in_buff = GSSAPI::LibGSSAPI::UnManagedGssBufferDesc.new
140
+ in_buff.value = token
141
+ out_buff = GSSAPI::LibGSSAPI::ManagedGssBufferDesc.new
142
+ maj_stat = GSSAPI::LibGSSAPI.gss_get_mic(min_stat, @context, qop_req, in_buff.pointer, out_buff.pointer)
143
+ raise GssApiError.new(maj_stat, min_stat), "Failed to gss_get_mic" if maj_stat != 0
144
+ out_buff.value
145
+ end
146
+
147
+
134
148
  # Get textual representation of internal GSS name
135
149
  # @return [String] textual representation of internal GSS name
136
150
  def display_name
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gssapi
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.1
4
+ version: 1.1.2
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,11 +9,11 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-05-09 00:00:00.000000000 Z
12
+ date: 2012-11-05 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: ffi
16
- requirement: &6301300 !ruby/object:Gem::Requirement
16
+ requirement: !ruby/object:Gem::Requirement
17
17
  none: false
18
18
  requirements:
19
19
  - - ! '>='
@@ -21,7 +21,12 @@ dependencies:
21
21
  version: 1.0.1
22
22
  type: :runtime
23
23
  prerelease: false
24
- version_requirements: *6301300
24
+ version_requirements: !ruby/object:Gem::Requirement
25
+ none: false
26
+ requirements:
27
+ - - ! '>='
28
+ - !ruby/object:Gem::Version
29
+ version: 1.0.1
25
30
  description: ! " A FFI wrapper around the system GSSAPI library. Please make sure
26
31
  and read the\n Yard docs or standard GSSAPI documentation if you have any questions.\n
27
32
  \ \n There is also a class called GSSAPI::Simple that wraps many of the common
@@ -76,7 +81,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
76
81
  version: '0'
77
82
  requirements: []
78
83
  rubyforge_project:
79
- rubygems_version: 1.8.17
84
+ rubygems_version: 1.8.24
80
85
  signing_key:
81
86
  specification_version: 3
82
87
  summary: A FFI wrapper around the system GSSAPI library.