ruby_smb 2.0.3 → 2.0.8

Sign up to get free protection for your applications and to get access to all the features.
Files changed (70) hide show
  1. checksums.yaml +4 -4
  2. checksums.yaml.gz.sig +0 -0
  3. data.tar.gz.sig +1 -2
  4. data/.github/workflows/verify.yml +56 -0
  5. data/README.md +0 -1
  6. data/examples/delete_file.rb +0 -0
  7. data/examples/net_share_enum_all.rb +0 -0
  8. data/examples/pipes.rb +0 -0
  9. data/examples/rename_file.rb +0 -0
  10. data/lib/ruby_smb.rb +3 -2
  11. data/lib/ruby_smb/client.rb +12 -8
  12. data/lib/ruby_smb/client/authentication.rb +5 -10
  13. data/lib/ruby_smb/client/echo.rb +2 -4
  14. data/lib/ruby_smb/client/negotiation.rb +4 -6
  15. data/lib/ruby_smb/client/tree_connect.rb +2 -4
  16. data/lib/ruby_smb/client/utils.rb +16 -10
  17. data/lib/ruby_smb/client/winreg.rb +1 -1
  18. data/lib/ruby_smb/compression.rb +7 -0
  19. data/lib/ruby_smb/compression/lznt1.rb +164 -0
  20. data/lib/ruby_smb/dcerpc.rb +3 -1
  21. data/lib/ruby_smb/dcerpc/ndr.rb +97 -0
  22. data/lib/ruby_smb/dcerpc/netlogon.rb +101 -0
  23. data/lib/ruby_smb/dcerpc/netlogon/netr_server_authenticate3_request.rb +37 -0
  24. data/lib/ruby_smb/dcerpc/netlogon/netr_server_authenticate3_response.rb +26 -0
  25. data/lib/ruby_smb/dcerpc/netlogon/netr_server_password_set2_request.rb +37 -0
  26. data/lib/ruby_smb/dcerpc/netlogon/netr_server_password_set2_response.rb +23 -0
  27. data/lib/ruby_smb/dcerpc/netlogon/netr_server_req_challenge_request.rb +32 -0
  28. data/lib/ruby_smb/dcerpc/netlogon/netr_server_req_challenge_response.rb +24 -0
  29. data/lib/ruby_smb/dcerpc/request.rb +6 -0
  30. data/lib/ruby_smb/dcerpc/winreg.rb +2 -2
  31. data/lib/ruby_smb/dispatcher/socket.rb +1 -1
  32. data/lib/ruby_smb/error.rb +21 -5
  33. data/lib/ruby_smb/generic_packet.rb +11 -1
  34. data/lib/ruby_smb/smb1/file.rb +8 -15
  35. data/lib/ruby_smb/smb1/packet/trans2/find_first2_response.rb +0 -1
  36. data/lib/ruby_smb/smb1/packet/trans2/find_next2_response.rb +0 -1
  37. data/lib/ruby_smb/smb1/packet/trans2/open2_response.rb +1 -2
  38. data/lib/ruby_smb/smb1/packet/trans2/set_file_information_response.rb +1 -13
  39. data/lib/ruby_smb/smb1/pipe.rb +8 -8
  40. data/lib/ruby_smb/smb1/tree.rb +13 -9
  41. data/lib/ruby_smb/smb2/file.rb +8 -16
  42. data/lib/ruby_smb/smb2/packet/compression_transform_header.rb +4 -0
  43. data/lib/ruby_smb/smb2/pipe.rb +8 -8
  44. data/lib/ruby_smb/smb2/tree.rb +12 -8
  45. data/lib/ruby_smb/version.rb +1 -1
  46. data/spec/lib/ruby_smb/client_spec.rb +17 -12
  47. data/spec/lib/ruby_smb/compression/lznt1_spec.rb +32 -0
  48. data/spec/lib/ruby_smb/dcerpc/netlogon/netr_server_authenticate3_request_spec.rb +69 -0
  49. data/spec/lib/ruby_smb/dcerpc/netlogon/netr_server_authenticate3_response_spec.rb +53 -0
  50. data/spec/lib/ruby_smb/dcerpc/netlogon/netr_server_password_set2_request_spec.rb +69 -0
  51. data/spec/lib/ruby_smb/dcerpc/netlogon/netr_server_password_set2_response_spec.rb +37 -0
  52. data/spec/lib/ruby_smb/dcerpc/netlogon/netr_server_req_challenge_request_spec.rb +45 -0
  53. data/spec/lib/ruby_smb/dcerpc/netlogon/netr_server_req_challenge_response_spec.rb +37 -0
  54. data/spec/lib/ruby_smb/dcerpc/winreg_spec.rb +12 -0
  55. data/spec/lib/ruby_smb/error_spec.rb +34 -5
  56. data/spec/lib/ruby_smb/generic_packet_spec.rb +7 -0
  57. data/spec/lib/ruby_smb/smb1/file_spec.rb +2 -4
  58. data/spec/lib/ruby_smb/smb1/packet/trans2/find_first2_response_spec.rb +0 -1
  59. data/spec/lib/ruby_smb/smb1/packet/trans2/find_next2_response_spec.rb +0 -1
  60. data/spec/lib/ruby_smb/smb1/packet/trans2/open2_response_spec.rb +0 -5
  61. data/spec/lib/ruby_smb/smb1/packet/trans2/set_file_information_response_spec.rb +0 -6
  62. data/spec/lib/ruby_smb/smb1/pipe_spec.rb +23 -5
  63. data/spec/lib/ruby_smb/smb1/tree_spec.rb +22 -0
  64. data/spec/lib/ruby_smb/smb2/file_spec.rb +1 -3
  65. data/spec/lib/ruby_smb/smb2/pipe_spec.rb +2 -5
  66. data/spec/lib/ruby_smb/smb2/tree_spec.rb +23 -0
  67. data/spec/spec_helper.rb +1 -1
  68. metadata +42 -19
  69. metadata.gz.sig +0 -0
  70. data/.travis.yml +0 -6
@@ -0,0 +1,37 @@
1
+ RSpec.describe RubySMB::Dcerpc::Netlogon::NetrServerReqChallengeResponse do
2
+ subject(:packet) { described_class.new }
3
+
4
+ it { is_expected.to respond_to :server_challenge }
5
+ it { is_expected.to respond_to :error_status }
6
+
7
+ it 'is little endian' do
8
+ expect(described_class.fields.instance_variable_get(:@hints)[:endian]).to eq :little
9
+ end
10
+
11
+ describe '#server_challenge' do
12
+ it 'is a NetlogonCredential structure' do
13
+ expect(packet.server_challenge).to be_a RubySMB::Dcerpc::Netlogon::NetlogonCredential
14
+ end
15
+ end
16
+
17
+ describe '#error_status' do
18
+ it 'is a 32-bit unsigned integer' do
19
+ expect(packet.error_status).to be_a BinData::Uint32le
20
+ end
21
+ end
22
+
23
+ describe '#initialize_instance' do
24
+ it 'sets #opnum to NETR_SERVER_REQ_CHALLENGE constant' do
25
+ expect(packet.opnum).to eq(RubySMB::Dcerpc::Netlogon::NETR_SERVER_REQ_CHALLENGE)
26
+ end
27
+ end
28
+
29
+ it 'reads its own binary representation and outputs the same packet' do
30
+ packet = described_class.new(
31
+ server_challenge: "\x00" * 8,
32
+ error_status: rand(0xffffffff)
33
+ )
34
+ binary = packet.to_binary_s
35
+ expect(described_class.read(binary)).to eq(packet)
36
+ end
37
+ end
@@ -669,6 +669,12 @@ RSpec.describe RubySMB::Dcerpc::Winreg do
669
669
  expect(winreg).to have_received(:close_key).with(root_key_handle)
670
670
  end
671
671
 
672
+ it 'only closes the key once when there is no subkey' do
673
+ winreg.enum_registry_key(root_key)
674
+ expect(winreg).to have_received(:close_key).once
675
+ expect(winreg).to have_received(:close_key).with(root_key_handle)
676
+ end
677
+
672
678
  it 'returns the expected array of enumerated keys' do
673
679
  key1 = 'key1'
674
680
  key2 = 'key2'
@@ -742,6 +748,12 @@ RSpec.describe RubySMB::Dcerpc::Winreg do
742
748
  expect(winreg).to have_received(:close_key).with(root_key_handle)
743
749
  end
744
750
 
751
+ it 'only closes the key once when there is no subkey' do
752
+ winreg.enum_registry_values(root_key)
753
+ expect(winreg).to have_received(:close_key).once
754
+ expect(winreg).to have_received(:close_key).with(root_key_handle)
755
+ end
756
+
745
757
  it 'returns the expected array of enumerated keys' do
746
758
  value1 = 'value1'
747
759
  value2 = 'value2'
@@ -9,16 +9,45 @@ RSpec.describe RubySMB::Error::InvalidPacket do
9
9
  end
10
10
 
11
11
  context 'with a Hash' do
12
- it 'outputs the expected error message' do
13
- ex = described_class.new(
12
+ let(:ex) do
13
+ described_class.new(
14
14
  expected_proto: RubySMB::SMB1::SMB_PROTOCOL_ID,
15
15
  expected_cmd: RubySMB::SMB1::Packet::NegotiateResponseExtended::COMMAND,
16
16
  expected_custom: "extended_security=1",
17
- received_proto: RubySMB::SMB2::SMB2_PROTOCOL_ID,
18
- received_cmd: RubySMB::SMB2::Packet::NegotiateResponse::COMMAND,
17
+ packet: packet,
19
18
  received_custom: "extended_security=0"
20
19
  )
21
- expect(ex.to_s).to eq('Expecting SMB1 protocol with command=114 (extended_security=1), got SMB2 protocol with command=0 (extended_security=0)')
20
+ end
21
+
22
+ context 'with an SMB2 packet' do
23
+ let(:packet) { RubySMB::SMB2::Packet::NegotiateResponse.new }
24
+
25
+ it 'outputs the expected error message' do
26
+ expect(ex.to_s).to eq('Expecting SMB1 protocol with command=114 (extended_security=1), got SMB2 protocol with command=0 (extended_security=0), Status: (0x00000000) STATUS_SUCCESS: The operation completed successfully.')
27
+ end
28
+ end
29
+
30
+ context 'with an SMB1 packet' do
31
+ let(:packet) { RubySMB::SMB1::Packet::ReadAndxRequest.new }
32
+
33
+ it 'outputs the expected error message' do
34
+ expect(ex.to_s).to eq('Expecting SMB1 protocol with command=114 (extended_security=1), got SMB1 protocol with command=46 (extended_security=0), Status: (0x00000000) STATUS_SUCCESS: The operation completed successfully.')
35
+ end
36
+ end
37
+
38
+ context 'without packet' do
39
+ let(:ex) do
40
+ described_class.new(
41
+ expected_proto: RubySMB::SMB1::SMB_PROTOCOL_ID,
42
+ expected_cmd: RubySMB::SMB1::Packet::NegotiateResponseExtended::COMMAND,
43
+ expected_custom: "extended_security=1",
44
+ received_custom: "extended_security=0"
45
+ )
46
+ end
47
+
48
+ it 'outputs the expected error message' do
49
+ expect(ex.to_s).to eq('Expecting SMB1 protocol with command=114 (extended_security=1), got ??? protocol with command=??? (extended_security=0)')
50
+ end
22
51
  end
23
52
  end
24
53
 
@@ -88,6 +88,13 @@ RSpec.describe RubySMB::GenericPacket do
88
88
  packet = RubySMB::SMB2::Packet::NegotiateResponse.read(smb2_error_packet.to_binary_s)
89
89
  expect(packet.original_command).to eq RubySMB::SMB2::Packet::NegotiateResponse::COMMAND
90
90
  end
91
+
92
+ context 'when the server returns an SMB1 error packet' do
93
+ let(:smb1_error_packet) { RubySMB::SMB1::Packet::EmptyPacket.new }
94
+ it 'returns the empty packet instead of the asked for class' do
95
+ expect(RubySMB::SMB2::Packet::NegotiateResponse.read(smb1_error_packet.to_binary_s)).to be_a RubySMB::SMB1::Packet::EmptyPacket
96
+ end
97
+ end
91
98
  end
92
99
  end
93
100
 
@@ -473,7 +473,7 @@ RSpec.describe RubySMB::SMB1::File do
473
473
  end
474
474
 
475
475
  it 'sets the File Information #rename_pending field of the packet' do
476
- expect(file.rename_packet(filename).data_block.trans2_data.info_level_struct.file_name).to eq filename.encode('utf-16le').force_encoding('ASCII-8BIT')
476
+ expect(file.rename_packet(filename).data_block.trans2_data.info_level_struct.file_name).to eq filename
477
477
  end
478
478
 
479
479
  it 'sets the Trans2 ParameterBlock fields' do
@@ -521,9 +521,7 @@ RSpec.describe RubySMB::SMB1::File do
521
521
 
522
522
  it 'raises an InvalidPacket exception if the response is not valid' do
523
523
  allow(response).to receive(:valid?).and_return(false)
524
- smb_header = double('SMB Header')
525
- allow(response).to receive(:smb_header).and_return(smb_header)
526
- allow(smb_header).to receive_messages(:protocol => nil, :command => nil)
524
+ allow(response).to receive(:packet_smb_version)
527
525
  expect { file.close }.to raise_error(RubySMB::Error::InvalidPacket)
528
526
  end
529
527
 
@@ -32,7 +32,6 @@ RSpec.describe RubySMB::SMB1::Packet::Trans2::FindFirst2Response do
32
32
  describe '#data_block' do
33
33
  subject(:data_block) { packet.data_block }
34
34
 
35
- it { is_expected.to respond_to :name }
36
35
  it { is_expected.to respond_to :trans2_parameters }
37
36
  it { is_expected.to respond_to :trans2_data }
38
37
 
@@ -32,7 +32,6 @@ RSpec.describe RubySMB::SMB1::Packet::Trans2::FindNext2Response do
32
32
  describe '#data_block' do
33
33
  subject(:data_block) { packet.data_block }
34
34
 
35
- it { is_expected.to respond_to :name }
36
35
  it { is_expected.to respond_to :trans2_parameters }
37
36
  it { is_expected.to respond_to :trans2_data }
38
37
 
@@ -35,16 +35,11 @@ RSpec.describe RubySMB::SMB1::Packet::Trans2::Open2Response do
35
35
  end
36
36
 
37
37
  it { is_expected.to respond_to :trans2_parameters }
38
- it { is_expected.to respond_to :trans2_data }
39
38
 
40
39
  it 'should keep #trans2_parameters 4-byte aligned' do
41
40
  expect(data_block.trans2_parameters.abs_offset % 4).to eq 0
42
41
  end
43
42
 
44
- it 'should keep #trans2_data 4-byte aligned' do
45
- expect(data_block.trans2_data.abs_offset % 4).to eq 0
46
- end
47
-
48
43
  describe '#trans2_parameters' do
49
44
  subject(:parameters) { data_block.trans2_parameters }
50
45
 
@@ -28,18 +28,12 @@ RSpec.describe RubySMB::SMB1::Packet::Trans2::SetFileInformationResponse do
28
28
  describe '#data_block' do
29
29
  subject(:data_block) { packet.data_block }
30
30
 
31
- it { is_expected.to respond_to :name }
32
31
  it { is_expected.to respond_to :trans2_parameters }
33
- it { is_expected.to respond_to :trans2_data }
34
32
 
35
33
  it 'should keep #trans2_parameters 4-byte aligned' do
36
34
  expect(data_block.trans2_parameters.abs_offset % 4).to eq 0
37
35
  end
38
36
 
39
- it 'should keep #trans2_data 4-byte aligned' do
40
- expect(data_block.trans2_data.abs_offset % 4).to eq 0
41
- end
42
-
43
37
  describe '#trans2_parameters' do
44
38
  subject(:parameters) { data_block.trans2_parameters }
45
39
 
@@ -80,9 +80,7 @@ RSpec.describe RubySMB::SMB1::Pipe do
80
80
 
81
81
  it 'raises an InvalidPacket exception if the response is not valid' do
82
82
  allow(response).to receive(:valid?).and_return(false)
83
- smb_header = double('SMB Header')
84
- allow(response).to receive(:smb_header).and_return(smb_header)
85
- allow(smb_header).to receive_messages(:protocol => nil, :command => nil)
83
+ allow(response).to receive(:packet_smb_version)
86
84
  expect { pipe.peek }.to raise_error(RubySMB::Error::InvalidPacket)
87
85
  end
88
86
 
@@ -149,6 +147,13 @@ RSpec.describe RubySMB::SMB1::Pipe do
149
147
  end
150
148
  end
151
149
 
150
+ context 'with \'\\srvsvc\' filename' do
151
+ it 'extends Srvsvc class' do
152
+ pipe = described_class.new(tree: tree, response: nt_create_andx_response, name: '\\srvsvc')
153
+ expect(pipe.respond_to?(:net_share_enum_all)).to be true
154
+ end
155
+ end
156
+
152
157
  context 'with \'winreg\' filename' do
153
158
  it 'extends Winreg class' do
154
159
  pipe = described_class.new(tree: tree, response: nt_create_andx_response, name: 'winreg')
@@ -156,12 +161,26 @@ RSpec.describe RubySMB::SMB1::Pipe do
156
161
  end
157
162
  end
158
163
 
164
+ context 'with \'\\winreg\' filename' do
165
+ it 'extends Winreg class' do
166
+ pipe = described_class.new(tree: tree, response: nt_create_andx_response, name: '\\winreg')
167
+ expect(pipe.respond_to?(:has_registry_key?)).to be true
168
+ end
169
+ end
170
+
159
171
  context 'with \'svcctl\' filename' do
160
172
  it 'extends svcctl class' do
161
173
  pipe = described_class.new(tree: tree, response: nt_create_andx_response, name: 'svcctl')
162
174
  expect(pipe.respond_to?(:query_service_config)).to be true
163
175
  end
164
176
  end
177
+
178
+ context 'with \'\\svcctl\' filename' do
179
+ it 'extends svcctl class' do
180
+ pipe = described_class.new(tree: tree, response: nt_create_andx_response, name: '\\svcctl')
181
+ expect(pipe.respond_to?(:query_service_config)).to be true
182
+ end
183
+ end
165
184
  end
166
185
 
167
186
  describe '#dcerpc_request' do
@@ -245,8 +264,7 @@ RSpec.describe RubySMB::SMB1::Pipe do
245
264
 
246
265
  context 'when the response is not a Trans packet' do
247
266
  it 'raises an InvalidPacket exception' do
248
- allow(trans_nmpipe_response).to receive_message_chain(:smb_header, :protocol)
249
- allow(trans_nmpipe_response).to receive_message_chain(:smb_header, :command)
267
+ allow(trans_nmpipe_response).to receive(:packet_smb_version)
250
268
  allow(trans_nmpipe_response).to receive(:valid?).and_return(false)
251
269
  expect { pipe.dcerpc_request(stub_packet, options) }.to raise_error(RubySMB::Error::InvalidPacket)
252
270
  end
@@ -492,4 +492,26 @@ RSpec.describe RubySMB::SMB1::Tree do
492
492
  end
493
493
  end
494
494
 
495
+ describe '#open_pipe' do
496
+ let(:opts) { { filename: 'test', write: true } }
497
+ before :example do
498
+ allow(tree).to receive(:open_file)
499
+ end
500
+
501
+ it 'calls #open_file with the provided options' do
502
+ opts[:filename] ='\\test'
503
+ expect(tree).to receive(:open_file).with(opts)
504
+ tree.open_pipe(opts)
505
+ end
506
+
507
+ it 'prepends the filename with \\ if needed' do
508
+ expect(tree).to receive(:open_file).with( { filename: '\\test', write: true } )
509
+ tree.open_pipe(opts)
510
+ end
511
+
512
+ it 'does not modify the original option hash' do
513
+ tree.open_pipe(opts)
514
+ expect(opts).to eq( { filename: 'test', write: true } )
515
+ end
516
+ end
495
517
  end
@@ -459,9 +459,7 @@ RSpec.describe RubySMB::SMB2::File do
459
459
 
460
460
  it 'raises an InvalidPacket exception if the response is not valid' do
461
461
  allow(response).to receive(:valid?).and_return(false)
462
- smb2_header = double('SMB2 Header')
463
- allow(response).to receive(:smb2_header).and_return(smb2_header)
464
- allow(smb2_header).to receive_messages(:protocol => nil, :command => nil)
462
+ allow(response).to receive(:packet_smb_version)
465
463
  expect { file.close }.to raise_error(RubySMB::Error::InvalidPacket)
466
464
  end
467
465
 
@@ -86,9 +86,7 @@ RSpec.describe RubySMB::SMB2::Pipe do
86
86
 
87
87
  it 'raises an InvalidPacket exception if the response is not valid' do
88
88
  allow(response).to receive(:valid?).and_return(false)
89
- smb2_header = double('SMB2 Header')
90
- allow(response).to receive(:smb2_header).and_return(smb2_header)
91
- allow(smb2_header).to receive_messages(:protocol => nil, :command => nil)
89
+ allow(response).to receive(:packet_smb_version)
92
90
  expect { pipe.peek }.to raise_error(RubySMB::Error::InvalidPacket)
93
91
  end
94
92
 
@@ -261,8 +259,7 @@ RSpec.describe RubySMB::SMB2::Pipe do
261
259
 
262
260
  context 'when the response is not an IoctlResponse packet' do
263
261
  it 'raises an InvalidPacket exception' do
264
- allow(ioctl_response).to receive_message_chain(:smb2_header, :protocol)
265
- allow(ioctl_response).to receive_message_chain(:smb2_header, :command)
262
+ allow(ioctl_response).to receive(:packet_smb_version)
266
263
  allow(ioctl_response).to receive(:valid?).and_return(false)
267
264
  expect { pipe.ioctl_send_recv(dcerpc_request, options) }.to raise_error(RubySMB::Error::InvalidPacket)
268
265
  end
@@ -531,4 +531,27 @@ RSpec.describe RubySMB::SMB2::Tree do
531
531
  end
532
532
  end
533
533
  end
534
+
535
+ describe '#open_pipe' do
536
+ let(:opts) { { filename: '\\test', write: true } }
537
+ before :example do
538
+ allow(tree).to receive(:open_file)
539
+ end
540
+
541
+ it 'calls #open_file with the provided options' do
542
+ opts[:filename] ='test'
543
+ expect(tree).to receive(:open_file).with(opts)
544
+ tree.open_pipe(opts)
545
+ end
546
+
547
+ it 'remove the leading \\ from the filename if needed' do
548
+ expect(tree).to receive(:open_file).with( { filename: 'test', write: true } )
549
+ tree.open_pipe(opts)
550
+ end
551
+
552
+ it 'does not modify the original option hash' do
553
+ tree.open_pipe(opts)
554
+ expect(opts).to eq( { filename: '\\test', write: true } )
555
+ end
556
+ end
534
557
  end
data/spec/spec_helper.rb CHANGED
@@ -7,7 +7,7 @@ end
7
7
  require 'coveralls'
8
8
  require 'ruby_smb'
9
9
 
10
- if ENV['TRAVIS'] == 'true'
10
+ if ENV['CI'] == 'true'
11
11
  # don't generate local report as it is inaccessible on travis-ci, which is
12
12
  # why coveralls is being used.
13
13
  SimpleCov.formatter = Coveralls::SimpleCov::Formatter
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ruby_smb
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.3
4
+ version: 2.0.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Metasploit Hackers
@@ -68,20 +68,20 @@ cert_chain:
68
68
  -----END CERTIFICATE-----
69
69
  - |
70
70
  -----BEGIN CERTIFICATE-----
71
- MIIFIzCCBAugAwIBAgIQDX9ZkVJ2eNVTlibR5ALyJTANBgkqhkiG9w0BAQsFADBy
71
+ MIIFIzCCBAugAwIBAgIQCMePMbkSxvnPeJhYXIfaxzANBgkqhkiG9w0BAQsFADBy
72
72
  MQswCQYDVQQGEwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3
73
73
  d3cuZGlnaWNlcnQuY29tMTEwLwYDVQQDEyhEaWdpQ2VydCBTSEEyIEFzc3VyZWQg
74
- SUQgQ29kZSBTaWduaW5nIENBMB4XDTE5MTAxNjAwMDAwMFoXDTIwMTAxOTEyMDAw
74
+ SUQgQ29kZSBTaWduaW5nIENBMB4XDTIwMTAwNzAwMDAwMFoXDTIzMTEwNjEyMDAw
75
75
  MFowYDELMAkGA1U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CeTB+ojrxX+5PdLVZa0ss7toWzJ2A1poPXZ1eZvm5xeFD32z
95
+ YQaTmmNWNI3PCDTyJ2PXUc+bDiNNwcZ7yc5o78UNRvp9Jxghya17Q76c9Ov9wvnv
96
+ dxxQKWGOQy0m4fBrkyjAyH9Djjn81RbQrqYgPuhd5nD0HjN3VUQLhQbIJrk9TVs0
97
+ EknWpNgVhohbot1lfVAMmIhdtOVaRVcQQixWPwprDj/ydB8ryDMDosIMcw+fkoXU
98
+ 9GJsSaSRRYQ9UUkVL27b64okU8D48m8=
99
99
  -----END CERTIFICATE-----
100
- date: 2020-08-17 00:00:00.000000000 Z
100
+ date: 2021-04-09 00:00:00.000000000 Z
101
101
  dependencies:
102
102
  - !ruby/object:Gem::Dependency
103
103
  name: redcarpet
@@ -246,10 +246,10 @@ executables: []
246
246
  extensions: []
247
247
  extra_rdoc_files: []
248
248
  files:
249
+ - ".github/workflows/verify.yml"
249
250
  - ".gitignore"
250
251
  - ".rspec"
251
252
  - ".simplecov"
252
- - ".travis.yml"
253
253
  - ".yardopts"
254
254
  - CONTRIBUTING.md
255
255
  - Gemfile
@@ -284,12 +284,21 @@ files:
284
284
  - lib/ruby_smb/client/tree_connect.rb
285
285
  - lib/ruby_smb/client/utils.rb
286
286
  - lib/ruby_smb/client/winreg.rb
287
+ - lib/ruby_smb/compression.rb
288
+ - lib/ruby_smb/compression/lznt1.rb
287
289
  - lib/ruby_smb/crypto.rb
288
290
  - lib/ruby_smb/dcerpc.rb
289
291
  - lib/ruby_smb/dcerpc/bind.rb
290
292
  - lib/ruby_smb/dcerpc/bind_ack.rb
291
293
  - lib/ruby_smb/dcerpc/error.rb
292
294
  - lib/ruby_smb/dcerpc/ndr.rb
295
+ - lib/ruby_smb/dcerpc/netlogon.rb
296
+ - lib/ruby_smb/dcerpc/netlogon/netr_server_authenticate3_request.rb
297
+ - lib/ruby_smb/dcerpc/netlogon/netr_server_authenticate3_response.rb
298
+ - lib/ruby_smb/dcerpc/netlogon/netr_server_password_set2_request.rb
299
+ - lib/ruby_smb/dcerpc/netlogon/netr_server_password_set2_response.rb
300
+ - lib/ruby_smb/dcerpc/netlogon/netr_server_req_challenge_request.rb
301
+ - lib/ruby_smb/dcerpc/netlogon/netr_server_req_challenge_response.rb
293
302
  - lib/ruby_smb/dcerpc/p_syntax_id_t.rb
294
303
  - lib/ruby_smb/dcerpc/pdu_header.rb
295
304
  - lib/ruby_smb/dcerpc/ptypes.rb
@@ -519,10 +528,17 @@ files:
519
528
  - lib/ruby_smb/version.rb
520
529
  - ruby_smb.gemspec
521
530
  - spec/lib/ruby_smb/client_spec.rb
531
+ - spec/lib/ruby_smb/compression/lznt1_spec.rb
522
532
  - spec/lib/ruby_smb/crypto_spec.rb
523
533
  - spec/lib/ruby_smb/dcerpc/bind_ack_spec.rb
524
534
  - spec/lib/ruby_smb/dcerpc/bind_spec.rb
525
535
  - spec/lib/ruby_smb/dcerpc/ndr_spec.rb
536
+ - spec/lib/ruby_smb/dcerpc/netlogon/netr_server_authenticate3_request_spec.rb
537
+ - spec/lib/ruby_smb/dcerpc/netlogon/netr_server_authenticate3_response_spec.rb
538
+ - spec/lib/ruby_smb/dcerpc/netlogon/netr_server_password_set2_request_spec.rb
539
+ - spec/lib/ruby_smb/dcerpc/netlogon/netr_server_password_set2_response_spec.rb
540
+ - spec/lib/ruby_smb/dcerpc/netlogon/netr_server_req_challenge_request_spec.rb
541
+ - spec/lib/ruby_smb/dcerpc/netlogon/netr_server_req_challenge_response_spec.rb
526
542
  - spec/lib/ruby_smb/dcerpc/p_syntax_id_t_spec.rb
527
543
  - spec/lib/ruby_smb/dcerpc/pdu_header_spec.rb
528
544
  - spec/lib/ruby_smb/dcerpc/request_spec.rb
@@ -747,10 +763,17 @@ specification_version: 4
747
763
  summary: A pure Ruby implementation of the SMB Protocol Family
748
764
  test_files:
749
765
  - spec/lib/ruby_smb/client_spec.rb
766
+ - spec/lib/ruby_smb/compression/lznt1_spec.rb
750
767
  - spec/lib/ruby_smb/crypto_spec.rb
751
768
  - spec/lib/ruby_smb/dcerpc/bind_ack_spec.rb
752
769
  - spec/lib/ruby_smb/dcerpc/bind_spec.rb
753
770
  - spec/lib/ruby_smb/dcerpc/ndr_spec.rb
771
+ - spec/lib/ruby_smb/dcerpc/netlogon/netr_server_authenticate3_request_spec.rb
772
+ - spec/lib/ruby_smb/dcerpc/netlogon/netr_server_authenticate3_response_spec.rb
773
+ - spec/lib/ruby_smb/dcerpc/netlogon/netr_server_password_set2_request_spec.rb
774
+ - spec/lib/ruby_smb/dcerpc/netlogon/netr_server_password_set2_response_spec.rb
775
+ - spec/lib/ruby_smb/dcerpc/netlogon/netr_server_req_challenge_request_spec.rb
776
+ - spec/lib/ruby_smb/dcerpc/netlogon/netr_server_req_challenge_response_spec.rb
754
777
  - spec/lib/ruby_smb/dcerpc/p_syntax_id_t_spec.rb
755
778
  - spec/lib/ruby_smb/dcerpc/pdu_header_spec.rb
756
779
  - spec/lib/ruby_smb/dcerpc/request_spec.rb