Commit Graph

545 Commits (8a402da056f99d0c3b69edb6ca7c76a609af7468)

Author SHA1 Message Date
Jon Hart 7b33ff1363
Land #3767, @jvazquez-r7's specs for Rex::Encoder::XDR 2014-10-22 09:22:53 -07:00
Jon Hart 82de2eb1f3
Fix Rex::Encoder::XDR.decode_int! to properly handle short data 2014-10-20 11:30:13 -07:00
Joshua Smith 19e8a50573
Land 3847, specs for Rex::Oui 2014-10-17 13:22:51 -05:00
Joshua Smith 32faa0bc62
Land 3796, specs for Rex::Encoder::Alpha2 encoders 2014-10-17 13:15:00 -05:00
jvazquez-r7 2f20998eaa Force Rex::OLE::Util to work on LITTLE_ENDIAN 2014-10-13 16:01:43 -05:00
jvazquez-r7 51f1309cc3 Add specs for Rex::OLE::CLSID 2014-10-13 14:28:58 -05:00
jvazquez-r7 8b9c8da4ac Add specs for Rex::OLE::Util 2014-10-13 13:41:43 -05:00
jvazquez-r7 e4a7025157 Avoid explicit use of subject 2014-10-13 10:41:12 -05:00
jvazquez-r7 10d50e77eb Avoid explicit use of subject 2014-10-13 10:21:31 -05:00
jvazquez-r7 3aadaf672e Fix @lsanchez-r7's feedback, single expectation per test and avoid explicit use of subject 2014-10-06 16:08:20 -05:00
Samuel Huckins 0dfd8e25b8
Land #3846, Rex::ImageSource specs 2014-10-02 12:33:56 -05:00
jvazquez-r7 e4f71d79ac Fix grammar 2014-09-24 15:17:09 -05:00
sinn3r 35f788a1a4
Land #3848 - Add specs for Rex::Arch 2014-09-23 13:03:40 -05:00
jvazquez-r7 0dfc2d3f87 Add specs for Rex::ExtTime 2014-09-22 14:55:14 -05:00
jvazquez-r7 db587afac8 Add specs for Rex::Arch 2014-09-22 14:10:55 -05:00
jvazquez-r7 701d6470c9 Add specs for Rex::Oui 2014-09-22 13:28:07 -05:00
jvazquez-r7 a677749f5b Add specs for #read_asciiz and fix bugs there 2014-09-22 12:14:21 -05:00
jvazquez-r7 f804d42ddc Add specs for Memory#index 2014-09-22 11:43:18 -05:00
jvazquez-r7 b121764003 Add specs for Memory#subsource 2014-09-22 11:30:30 -05:00
jvazquez-r7 3500e1ce7c Add specs for Memory#close 2014-09-22 11:18:21 -05:00
jvazquez-r7 a612caf1ae Finish examples for Memory#read 2014-09-22 11:17:09 -05:00
jvazquez-r7 df7ee55962 Add first specs for Rex::ImageSource::Memory#read 2014-09-22 11:06:34 -05:00
jvazquez-r7 77122895db Add specs for Rex::ImageSource::Memory#initialize 2014-09-22 11:02:24 -05:00
jvazquez-r7 a249eb1026 Add specs for Disk#subsource and Disk#close 2014-09-22 10:50:11 -05:00
jvazquez-r7 23bf36bc75 Start specs for Disk#subsource 2014-09-22 10:37:56 -05:00
jvazquez-r7 3f1eea55a6 Add specs for Disk#read and Disk#index 2014-09-22 10:35:54 -05:00
Luke Imhoff f61afe2598
Merge branch 'master' into bug/MSP-11368/boot-profiling
MSP-11368
2014-09-22 10:00:07 -05:00
jvazquez-r7 46e4235e79 Add spec templates 2014-09-22 09:16:21 -05:00
sinn3r cd70014446 Fix os detection rspec
no more window
2014-09-20 21:29:13 -05:00
sinn3r d52236fe05
Land #3835 - JSObfu to a gem 2014-09-20 01:38:45 -05:00
Joe Vennix df999db547
Add spec to ensure gem loads without error. 2014-09-19 19:49:01 -05:00
Luke Imhoff b863978028
Remove fastlib
MSP-11368
MSP-11143

Remove fastlib as it slows down the code loading process.  From the
previous commit, the mean loading for
`METASPLOIT_FRAMEWORK_PROFILE=true msfconsole -q -x exit` was
27.9530±0.3485 seconds (N=10).  The mean after removal of fastlib
was 17.9820±0.6497 seconds (N=10).  This means an average 35.67%
reduction in boot time.
2014-09-18 15:24:21 -05:00
jvazquez-r7 ca4c4f55bd Add specs for Rex::Encoder::Alpha2::UnicodeMixed 2014-09-15 17:05:08 -05:00
jvazquez-r7 ee45056827 Add specs for Rex::Encoder::Alpha2::UnicodeUpper 2014-09-15 16:57:26 -05:00
jvazquez-r7 3dc53cd013 Add specs for Rex::Encoder::Alpha2::AlphaMixed 2014-09-15 16:43:40 -05:00
jvazquez-r7 e8dce6ac59 Add specs for Rex::Encoder::Alpha2::AlphaUpper 2014-09-15 16:35:54 -05:00
jvazquez-r7 2e126b6a68 Include it_behaves_like 2014-09-15 15:46:53 -05:00
jvazquez-r7 4064fb60ef Refactor specs for Rex::Encoder::Alpha2::Generic 2014-09-15 15:43:31 -05:00
jvazquez-r7 2728318358 Add specs for Rex::Encoder::Alpha2::Generic 2014-09-15 15:26:13 -05:00
jvazquez-r7 3f5fdaebb4 Add specs for Rex::Encoder::NDR 2014-09-15 13:49:18 -05:00
HD Moore 6bd3675f03 Land #3680, add specs for Rex::MIME 2014-09-13 00:34:39 -05:00
HD Moore 6a2a85d2c4 Land #3789, adds specs for Rex::Proto::Http::Packet::Header
orts
2014-09-13 00:21:43 -05:00
James Lee f68628c487 Add minimal specs for rex/proto/http/packet/header 2014-09-12 14:30:27 -05:00
sinn3r 12e3cb3c6a
Land #3764 - Add specs for Rex::Encoder::NonAlpha 2014-09-12 12:09:55 -05:00
sinn3r 1b4ceec4f9
Land #3743 - Add specs for Rex::Arch::X86 2014-09-09 17:24:08 -05:00
jvazquez-r7 962c66b3bb Fix some descriptions 2014-09-08 18:17:24 -05:00
jvazquez-r7 8370bf0f2a Finish XDR specs 2014-09-08 18:05:09 -05:00
jvazquez-r7 44724d1141 Add specs for .decode_varray 2014-09-08 17:12:04 -05:00
jvazquez-r7 8af13592c2 Add first specs for Rex::Encoder::XDR 2014-09-08 16:25:53 -05:00
jvazquez-r7 f521cc598d Delete .encode specs, anyone uses the method, plus looks wrong 2014-09-08 14:42:43 -05:00
jvazquez-r7 9a74e60db3 Add specs for .encode 2014-09-08 14:32:33 -05:00
jvazquez-r7 11ca383d4f Add specs for .encode_byte 2014-09-08 14:24:03 -05:00
jvazquez-r7 3535a6a21d Add first specs for .gen_decoder and .encode_byte 2014-09-08 14:07:21 -05:00
jvazquez-r7 4c15954be5 Add specs for Rex::Arch::Sparc 2014-09-08 11:59:52 -05:00
jvazquez-r7 15f19468a1 Do last cleanup 2014-09-02 18:57:10 -05:00
jvazquez-r7 3ad0542b2a Fix some specs 2014-09-02 18:50:37 -05:00
jvazquez-r7 a1823b6c1e Add more specs for Rex::Arch::X86 2014-09-02 18:17:14 -05:00
jvazquez-r7 16111aa2f7 Use RSpec::Mocks::Double 2014-09-02 13:25:05 -05:00
jvazquez-r7 fdb66d978b Fix remainings be_truthy and be_falsey conditionals 2014-09-02 13:22:21 -05:00
jvazquez-r7 15e564ddf3
Merge branch 'collection_owner' into fix_deprecation_warnings 2014-09-02 13:14:09 -05:00
jvazquez-r7 bf0d30cf03 Fix rspec-collection_matchers deprecation warning in Rex::Socket::RangeWalker 2014-09-02 11:08:26 -05:00
jvazquez-r7 5a0b6ece6e Use is_expected 2014-09-02 10:27:53 -05:00
jvazquez-r7 764af20567 Fix rspec-collection_matchers deprecation warnings in Rex::Socket 2014-09-02 10:21:52 -05:00
jvazquez-r7 b37e1a5421 Solve conflicts 2014-08-26 17:51:37 -05:00
Joshua Smith 49adde2095
Land 3702, prefer be_falsey and cleanup specs 2014-08-26 15:24:41 -05:00
Joshua Smith 1fa26e2afb cleans up a bunch of spec msftidy issues 2014-08-26 15:24:08 -05:00
jvazquez-r7 042b8a3672 Switch from pending to skip in specs 2014-08-26 15:17:00 -05:00
HD Moore ba1f7c3bf6 Land #3687, reworks the nat-pmp portscanner 2014-08-26 14:34:46 -05:00
HD Moore 4e19d9ade1 Land #3545, fix up sip scanners, msftidy, db services cmd 2014-08-26 14:07:21 -05:00
Jon Hart 5ad090e833 Add unit test for and correct parsing of NAT-PMP port map responses 2014-08-26 10:49:53 -07:00
Jon Hart b0347906e3 Correct NATPMP external address resposne epoch and result parsing 2014-08-26 10:49:52 -07:00
jvazquez-r7 41420a97d5 Solve conflicts 2014-08-26 09:04:05 -05:00
jvazquez-r7 60ecf4e8c4 Use be_truthy instead of be_true 2014-08-25 23:58:08 -05:00
jvazquez-r7 aa47746290 Undo incorrect be_true switch 2014-08-25 18:23:55 -05:00
jvazquez-r7 c372f5164b And switch more cases to be_falsey 2014-08-25 17:50:38 -05:00
jvazquez-r7 dd1c015e4e Use be_falsey 2014-08-25 17:34:55 -05:00
jvazquez-r7 9a14b64051 First version of Rex::Arch::X86 specs 2014-08-25 16:44:28 -05:00
Jon Hart 6185721a61 Address @hmoore-r7's feedback regarding binary encoding 2014-08-25 13:11:22 -07:00
Jon Hart e3753e3649 Refactor SIP response parsing for future improvements 2014-08-25 13:11:21 -07:00
Jon Hart 02e41c27e7 Split SIP response parsing out on its own, add unit tests.
Passes rspec but fails in framework. WIP.
2014-08-25 13:11:20 -07:00
jvazquez-r7 fd05e634e8 Move once more let into describe 2014-08-21 10:41:37 -05:00
jvazquez-r7 b0a4ea6750 Move let helpers to describe groups 2014-08-21 10:39:16 -05:00
jvazquez-r7 6301d79162 Describe setters just expecting how assignement to properties should happen 2014-08-21 10:34:52 -05:00
jvazquez-r7 54395e38a0 Use a part subject to describe #add_part 2014-08-21 10:29:44 -05:00
jvazquez-r7 9dcc95fb04 Fix Rex::MIME::Message#initialize boundaries parsing 2014-08-20 10:22:38 -05:00
jvazquez-r7 e8a6307df1 Fix Rex::MIME::Header#parse 2014-08-20 09:42:44 -05:00
jvazquez-r7 e5fc0a007f Add some Message specs 2014-08-20 09:31:49 -05:00
jvazquez-r7 e4b586a96d Add specs for add_part_inline_attachment 2014-08-20 08:32:58 -05:00
jvazquez-r7 381c88f814 Add specs for add_part and add_part_attachment 2014-08-19 17:06:59 -05:00
Tod Beardsley a4c6a10edb
The .foo domain is live now.
I still kinda hate these tests, though, since they fail in wildcard DNS
environments (like OpenDNS).
2014-08-19 16:47:30 -05:00
jvazquez-r7 0585b13398 Add first specs for Rex::MIME::Message 2014-08-19 15:17:17 -05:00
sinn3r 311cc5befb
Land #3668 - Add specs for Rex::Exploitation::HeapLib 2014-08-19 13:14:24 -05:00
sinn3r 7bf637716a
Land #3663 - Add specs for Rex::Exploitation::EncryptJS 2014-08-19 13:08:14 -05:00
sinn3r ad241910d0 This is more invalid than the other one 2014-08-19 10:39:50 -05:00
sinn3r 17b03e7d34 Fix rspec due to an invalid dns becoming valid 2014-08-19 10:28:30 -05:00
jvazquez-r7 663e11f16b Add specs for Rex::MIME::Part 2014-08-18 18:03:27 -05:00
jvazquez-r7 85662d5ccd Add specs for Rex::MIME::Header 2014-08-18 17:33:26 -05:00
jvazquez-r7 73ac0e9537 Add specs for Rex::MIME::Encoding 2014-08-18 16:04:08 -05:00
jvazquez-r7 f812d2619c Fix load_js when opts[:newobfu] and add specs 2014-08-18 13:50:19 -05:00
jvazquez-r7 3dae6ee934 Not prefixing the class when describing method 2014-08-18 12:19:30 -05:00
jvazquez-r7 2dc579d467 Add template for specs 2014-08-18 12:16:20 -05:00
jvazquez-r7 75df32b1d3 Use single quoted strings out of the spec strings 2014-08-18 11:43:54 -05:00
jvazquez-r7 4ffd166918 Add specs for Rex::Exploitation::EncryptJS 2014-08-18 11:31:36 -05:00
Meatballs b4111df381
Retab spec 2014-08-01 14:41:20 +01:00
Meatballs 4ef3de84f3
get some more test cases 2014-08-01 14:34:17 +01:00
Meatballs 1fb4216d6d
Update spec 2014-08-01 12:08:03 +01:00
Meatballs 53b66f3b4a Land #2075, Powershell Improvements 2014-07-31 00:49:39 +01:00
Tod Beardsley ffafd4c01f
Add NTP fuzzer from @jhart-r7
Looks good to me!
2014-07-21 12:38:12 -05:00
Meatballs 474ee81807
Merge remote-tracking branch 'upstream/master' into pr2075 2014-07-20 21:01:54 +01:00
Meatballs b28343842f Address @jhart-r7's comments 2014-07-20 21:00:34 +01:00
scriptjunkie 8fe508207c Merge Meatballs' gpp_again pull into new branch 2014-07-19 11:10:14 -05:00
Meatballs 7583ed4950
Merge remote-tracking branch 'upstream/master' into pr2075 2014-07-16 20:34:34 +01:00
sinn3r 4fb58202fa
Land #3529 - Handle Rex::AddressInUse exception 2014-07-16 13:57:41 -05:00
jvazquez-r7 4098979448 Add spec 2014-07-15 13:06:53 -05:00
Tod Beardsley 038d1e210a
Merge upstream/master to deconflict.
Conflicts:
	Gemfile.lock
2014-07-09 17:43:42 -05:00
jvazquez-r7 14b1ed5290 Add spec for comma separated cookies 2014-07-06 16:23:43 -05:00
Jon Hart bc3ac1ee36 Correct private message format, update tests 2014-07-03 08:27:27 -07:00
Jon Hart 1830bdc7a5 Add rspec coverage for Rex::Proto::NTP 2014-07-01 12:29:47 -07:00
Tod Beardsley 8b63d3d467 Revert the revert of #3446
This reverts commit 9b35b0e13a.

This should not land on master until the Metasploit Pro folks (@trosen-r7
and friends) get their Meterpreter path specifications working the
same way as Framework's does.
2014-06-29 17:22:21 -05:00
Matt Buck 27ef12bafe
Land #3478, disallow port 0 for portspec
[Closes #3478]
2014-06-25 15:46:30 -05:00
David Maloney 42bfe8ba4f
make portspec specs not insane
the specs for the portspec_to_portlist method
need a lot of work. this gives us some btter minimum coverage
2014-06-25 14:10:06 -05:00
Chris Doughty 9b35b0e13a Revert "Land #3446 -- Meterpreter bins gem switch" due to build failures
This reverts commit bba8bd3498, reversing
changes made to 002234993f.
2014-06-25 13:24:07 -05:00
OJ bba8bd3498
Land #3446 -- Meterpreter bins gem switch 2014-06-25 03:00:11 +10:00
Tod Beardsley c71eb1aa4e
Add specs for changed object UI 2014-06-22 13:05:17 -05:00
Tod Beardsley 53d0aba305
Add some specs for changed object Priv 2014-06-22 12:54:10 -05:00
Spencer McIntyre 05d4a1ab2c
Land #3342, Support negation in portspec 2014-06-21 18:14:50 -04:00
Tod Beardsley f90e8f00e5
Add the first few specs
Coverage for meterpreter and client core, just the bits I'm changing. I
intend to make liberal use of doubles, since they're easier than mocks
and all I care about is the changed behavior. I refuse to fall into a
trap where I need to first spec out aaaaaalllll of Metepreter just to
make this one change.
2014-06-20 13:18:55 -05:00
jvazquez-r7 4203e75777
Land #3408, @m-1-k-3's exploit for D-Link hedwig.cgi OSVDB 95950 2014-06-20 10:27:32 -05:00
jvazquez-r7 330caa8c13 Fix specs 2014-06-20 00:08:55 -05:00
jvazquez-r7 ee62428248 Add specs 2014-06-19 18:13:14 -05:00
Christian Mehlmauer da0a9f66ea
Resolved all msftidy vars_get warnings 2014-05-25 19:29:39 +02:00
Lutz Wolf 2b75a53c93 Add basic rspec for portspec_to_portlist 2014-05-24 23:46:26 +02:00
Meatballs 09af023a71
Merge in parser 2014-05-20 21:56:35 +01:00
Jeff Jarmoc 638ae477d9 Fix up spec. Rex::Proto::Http::ClientRequest handles & and = outside of Rex::Text::uri_encode, so mode doesn't affect them.
Fix erroneous typo char.
2014-05-12 12:10:30 -05:00
Jeff Jarmoc cba39a9a04 Adds spec for 'hex-all' mode 2014-05-12 12:01:06 -05:00
Jeff Jarmoc 5f523e8a04 Rex::Text::uri_encode - make 'hex-all' really mean all.
'hex-all' encoding was previously ignoring slashes.
This pull adds 'hex-noslashes' mode which carries forward the previous functionality, and replaces all existing references to 'hex-all' with 'hex-noslashes'  It then adds a replacement 'hex-all' mode, which really encodes *ALL* characters.
2014-05-12 11:26:27 -05:00
Meatballs dc38212741
Fix function parsing 2014-05-05 20:53:36 +01:00
Meatballs e946046de5
Add methods spec 2014-05-05 19:08:18 +01:00
Meatballs 0b886db406
Script specs and remove unknown method 2014-05-05 19:01:36 +01:00
Meatballs 0177e51148
Finish obfu specs and use rig 2014-05-05 18:47:25 +01:00
Meatballs 6ab85027a4
More spec 2014-05-05 17:47:30 +01:00
Meatballs 162b6a8ab9
Add output spec 2014-05-05 14:48:18 +01:00
Meatballs 589d235a80
Simple param spec 2014-05-05 13:46:52 +01:00
Meatballs b860cecad6
Function spec (doesnt pass) 2014-04-28 14:09:39 +01:00
Meatballs 3ae8c3ff46
Basic specs 2014-04-25 18:14:39 +01:00
Meatballs 8031e50d35
Make Exploitation::Powershell testable
Example test
2014-04-26 13:27:25 +01:00
sinn3r 7a4e12976c
First little bit at Bug 8498
[FixRM #8489] rhost/rport modification
2014-04-15 18:20:16 -05:00
Tod Beardsley e4a61e2730
Fix Module.new bug and test for vhost 2014-04-14 18:01:13 -05:00
joev e09f887c4c Revert "Fixes large-string expansion in JSObfu."
This reverts commit 14fed8c610.
2014-04-11 16:51:47 -05:00
sinn3r 68a50e3663
Land #3224 - Fixes large-string expansion in JSObfu 2014-04-10 12:09:22 -05:00
Joe Vennix 14fed8c610 Fixes large-string expansion in JSObfu. 2014-04-09 15:45:48 -05:00
William Vu 9779913060
Land #3184, Rex::Proto::Http::Client IOError fix 2014-04-03 15:58:50 -05:00
joev 3504ddc633 Fix http spec. 2014-04-03 14:50:54 -05:00
William Vu 92c6113a7c
Fix broken spec for Rex::Text.randomize_space 2014-04-02 11:48:50 -05:00
Tod Beardsley 8ab03f3aeb
Use Array#sample in randomize_space 2014-04-01 14:09:07 -05:00
Tod Beardsley ec7bb6de54
Land #2969, random name generator for phishing 2014-04-01 13:00:55 -05:00
William Vu 355cda0a43
Add specs for random name and e-mail methods
Babby's first RSpec. Style is consistent with the rest of the tests.
2014-03-28 16:47:52 -05:00
sinn3r b431bf3da9
Land #3052 - Fix nil error in BES 2014-03-11 12:51:03 -05:00
Joe Vennix 5790547d34 Start undoing some work. 2014-03-04 17:01:53 -06:00
Joe Vennix 2a87973d3c Use be instead of eq. 2014-03-03 21:55:12 -06:00
Joe Vennix a382b78f80 Oops, $ and _ need to be in the spec.
* Repeats the random check 20 times for each spec.
2014-03-03 21:54:09 -06:00
Joe Vennix bfecf9525d Add Rex::RandomIdentifierGenerator. 2014-03-03 16:43:49 -06:00
Joe Vennix e8b10db73b Dropped a space. 2014-03-03 15:48:44 -06:00
Joe Vennix 1352e5eacb Add presence spec. 2014-03-03 15:47:30 -06:00
Joe Vennix b3ab8f7ce1 Make random_var_name public, add specs for it. 2014-03-03 15:39:56 -06:00
Joe Vennix 6574a06bc3 Whitespace fix. 2014-03-02 20:55:07 -06:00
Joe Vennix 4514e32df8 Remove spec changes, oops. 2014-03-02 20:54:22 -06:00
Joe Vennix b458b8ad63 Add specs for new methods. 2014-03-02 20:23:20 -06:00
William Vu 0a3ee573bc Uncomment spec_helper require 2014-01-22 11:58:10 -06:00
William Vu 2b7a993f65
Land #2902, updated PJL spec 2014-01-22 11:57:28 -06:00
Tod Beardsley 90207628cc
Land #2666, SSLCompression option
[SeeRM #823], where Stephen was asking for SSL compression for
Meterpreter -- this isn't that, but it's at least now possible for other
Metasploit functionality.
2014-01-22 10:42:13 -06:00
sinn3r 1c1597973e Update PJL rspec to comply with guidelines
Basically the updated version is more explicit. If a moethod doesn't
return anything but might raise an error, then we focus on that.
Also use . to # for instance methods.
2014-01-22 03:34:49 -06:00
sinn3r a1eba03d1f
Land #2725 - Rex::Proto::PJL plus modules 2014-01-16 15:57:38 -06:00
William Vu 6110ad72b3 Update tests and ensure full coverage 2014-01-16 15:11:04 -06:00
sinn3r 7b206d6094 Ensure full coverage 2014-01-12 23:10:47 -06:00
sinn3r f9fc54980a retab 2014-01-12 22:54:43 -06:00
sinn3r b8dd4b08c8 Add rspec 2014-01-12 22:53:11 -06:00
William Vu b43a221959
Land #2855, Rex::Socket refactor and specs 2014-01-09 16:20:50 -06:00
James Lee 442c98bc05
Add spec for fixed bug 2014-01-09 15:18:03 -06:00
James Lee 1519af33f5
Refactor `getaddress` in terms of `getaddresses` 2014-01-09 11:03:24 -06:00
James Lee 01f350964f
Add specs for some stuff in Rex::Socket 2014-01-09 10:19:19 -06:00
James Lee cc51c2033e
Fix unreliable spec
Sometimes "localhost" resolves to more than one address
2014-01-08 10:16:32 -06:00
James Lee 9c23910b69
Refactor Socket::Range
There was really no reason for it to inherit from Array. Also adds a few
more specs and gets coverage up to a more respectable percentage.
2014-01-07 16:31:55 -06:00
James Lee 2ed9772080
Fix unhandled exceptions when resolution fails 2014-01-07 12:00:04 -06:00
James Lee a6b25d3323
Add failing spec for invalid hostname bug 2014-01-06 17:49:27 -06:00
Joe Vennix 3ff9da5643 Remove compression options from client sockets.
I couldn't verify that it was working, as it always sends 1 compression type of NULL.
2013-11-20 14:41:45 -06:00
Joe Vennix f8b57d45cd Reenable the client SSLCompression advanced option.
Add spec for some of the additions to Rex::Proto::Http::Client
2013-11-20 01:03:13 -06:00
sinn3r 991240a87e Support java version detection 2013-11-07 00:54:52 -06:00
sinn3r 73e72a6488 Update the detect_spec testcase 2013-11-05 01:14:12 -06:00
joev 7d975dfa87 Fix spec to refer to postInfo(). 2013-11-02 16:54:22 -05:00
joev 90d8da6a21 Fix some bugs in my edits, add a spec. 2013-11-02 16:46:33 -05:00
sinn3r afcce8a511 Merge osdetect and addonsdetect 2013-10-22 01:11:11 -05:00
sinn3r 135648c171 Add the new rspec files 2013-10-21 20:18:36 -05:00
sinn3r 9a3e719233 Rework the naming style 2013-10-21 20:16:37 -05:00
sinn3r 5280bcf3f8 Update rspec files
Remove some junk code
2013-10-21 17:13:01 -05:00
sinn3r 8a94df7dcd Change category name for base64 2013-10-18 21:20:16 -05:00
sinn3r 73b8eb0f83 Add rspec files to make sure the javascript files are loadable. 2013-10-18 15:14:26 -05:00
jvazquez-r7 8b7d241dc3 Use a named subject 2013-10-07 12:28:50 -05:00
jvazquez-r7 d8dba8ee58 Fix ropdb spec according to @limhoff-r7's comments 2013-10-07 09:51:21 -05:00
sinn3r 41e87d83a6 Add rspec for Rex::Exploitation::RopDb 2013-10-04 00:54:07 -05:00
Tab Assassin 2e8d19edcf Retab all the things (except external/) 2013-09-30 13:47:53 -05:00
Tod Beardsley 7cc2ad55a6
Land #1770, unattend.xml snarfing modules 2013-09-27 16:04:38 -05:00
Tabassassin 120cca8bb3 Retab unattended_spec to avoid conflicts 2013-09-27 13:44:33 -05:00
Tod Beardsley 5bab85fcda Use a context for #parse 2013-09-27 13:04:18 -05:00
Tod Beardsley 6345fb2788 Use described_class 2013-09-27 12:59:10 -05:00
Tod Beardsley 7d9d98c9eb
Land #2421, update to cookie parsing specs 2013-09-27 11:45:33 -05:00
Tod Beardsley 8f957a5394 Add spec for new #to_h method 2013-09-27 11:27:31 -05:00
Tod Beardsley 103a64a32a Indent like a sane person. 2013-09-27 10:22:46 -05:00
Tod Beardsley 623aeb367f Set a context for #get_cookies 2013-09-27 10:12:11 -05:00
Tod Beardsley 467c503fb9 DRY with a cookie_sanity_check method 2013-09-27 10:07:28 -05:00
Tod Beardsley 5e95df1370 Convert local variables to HEREDOC methods 2013-09-27 10:02:22 -05:00
Tod Beardsley 57862125b9 Use shuffle and *splat operator to test arrays
Also, move the local variables to inside the describe block to avoid any
future scope issues.
2013-09-27 09:53:04 -05:00
Tod Beardsley 0aa2556dfc Use described_class, not a new constant 2013-09-27 09:32:15 -05:00
FireFart 3d28003285 updated get_cookies rspecs 2013-09-25 22:56:13 +02:00
Brandon Turner 4760000bca Replace mock with double in specs
mock is deprecated - https://www.relishapp.com/rspec/rspec-mocks/docs
2013-09-06 09:34:05 -05:00
Tab Assassin 269c1a26cb Merge for retab 2013-09-05 14:57:32 -05:00
William Vu d493346691 Land #2137, fixes and specs for Opt containers 2013-07-23 15:58:09 -05:00
William Vu 86ab942435 Land #2146, Unix and Windows path normalization 2013-07-23 15:23:41 -05:00
sinn3r 8b0aac2d3c Add another test case for having a trailing slash for unix path
If a trailing path exists in the original input, should keep it.
This test case should verify that.
2013-07-22 23:23:40 -05:00
sinn3r 2be0b84ba8 Not Windows format, Unix. 2013-07-22 22:37:36 -05:00
sinn3r 4ea176b5ee Add another test case 2013-07-22 22:35:19 -05:00
sinn3r 958a4edd73 Keep the trailing slash if the user wishes 2013-07-22 20:46:18 -05:00
sinn3r 359009583f Drop support for UNC path parsing in normalize_win_path
Not really a good idea to try to parse UNC format. Confuses the
purpose of the function.
2013-07-22 20:20:45 -05:00
sinn3r 8656fcf5e0 Update the test description a little better 2013-07-22 19:35:52 -05:00
sinn3r 4b3fce9349 Add functions to normalize Winodws & Unix paths
The purpose of these functions is to be able to join file/dir paths
safely without trailing slashes, basically for the same reason as
normalize_uri.  Some modules are really buggy when merging paths,
so instead of letting them do it, it's better to use these functions.
2013-07-22 19:26:04 -05:00
David Maloney ec82644bd3 mo fixes mo specs
SEERM #7536
SEERM #7537
2013-07-18 15:00:57 -05:00
James Lee 273046d8f0 Add a class for generating random identifiers
Will be useful for all kinds of things, but brought about in discussions
specifically for Util::EXE in #2037.
2013-07-09 02:06:44 -05:00
James Lee 5955397882 Use a more descriptive subject
Also removes the unnecessary (and now broken in 2.0) checks for
respond_to? on accessors.
2013-06-07 13:27:40 -05:00
James Lee 0f2ea755c5 Add encoding comment to spec files for 2.0 compat 2013-06-07 13:27:39 -05:00
sinn3r 1d9a695d2b Landing #1772 - Adds phpMyadmin Preg_Replace module (CVE-2013-3238)
[Closes #1772]
2013-04-28 12:17:16 -05:00
Meatballs de5c856188 get_cookies spec 2013-04-26 21:21:11 +01:00
James Lee a12dbbaee7 Use :each instead of :all here, too 2013-04-26 11:49:30 -05:00
Meatballs 590b8a3e26 Added rspec 2013-04-26 00:50:29 +01:00
James Lee 1ec6884bfa Use before(:each) instead of :all
Fixes deprecation warnings in newer rspec like these

  WARNING: subject accessed in a `before(:all)` hook at:
    /metasploit-framework/spec/lib/rex/post/meterpreter/packet_spec.rb:455:in `block (3 levels) in <top (required)>'

  This is deprecated behavior that will not be supported in RSpec 3.

Also switches to using named subjects for easier reading.
2013-04-25 10:28:30 -05:00
James Lee 93bddd9041 Improved docs and partial specs for Rex::Text
Conflicts:
	lib/msf/core/modules/loader/base.rb
	lib/rex/poly/block.rb
	lib/rex/text.rb
2013-04-23 17:24:03 -05:00
James Lee f321cea4cd Slightly more readable assertion 2013-03-07 14:45:58 -06:00
James Lee 8abcc5a1d4 Whitespace 2013-03-07 14:34:44 -06:00
David Maloney 7332d31523 fix some style things for egypt 2013-03-07 11:11:48 -06:00
David Maloney 6eb334c925 a little more coverage 2013-03-05 00:01:09 -06:00
David Maloney d909c00036 better spec coverage 2013-03-04 23:43:18 -06:00
David Maloney 3a72fa4ea0 address sslv2 issues in specs
the ubuntu sslv2 thing caused all kinds of issues with rspec
handling this by expecting those exceptions properly or doing away
with sslv2 where it isn't needed in the examples
2013-03-04 21:45:44 -06:00
David Maloney 3bb1b2b368 attempt to deal with specs 2013-03-04 19:25:20 -06:00
David Maloney dc7c02e9e8 still trying to get around this sslv2 thing 2013-03-04 18:18:01 -06:00
David Maloney 246977e0cf Address openssl sslv2 issues
Debian/Ubuntu ship openssl without sslv2 compiled in.
we now check for this ahead of time
2013-03-04 17:39:28 -06:00
David Maloney 13ad5cf150 Merge branch 'master' into feature/ssl/add_cipher_support 2013-03-04 15:07:32 -06:00
James Lee cb18b81503 Add spec to ensure auth is sane 2013-03-04 11:59:30 -06:00
David Maloney 4212c36566 Fix up basic auth madness 2013-03-01 11:59:02 -06:00
James Lee 5a79fcd11e Ensure we build only one Authorization header
Also fixes an issue where Host headers were generated with nil by
preferring the vhost from Client instead of the default nil from
ClientRequest.
2013-02-28 13:47:30 -06:00
James Lee 425c245771 Axe set_cgi in favor of set_uri
They were identical except for a couple of extra bugs in set_cgi.

Also changes ```split("/")``` to ```split("/", -1)```, which behaves
correctly when the input has a seperator at the beginning or end.
2013-02-27 19:13:05 -06:00
James Lee 16bba7a6ac Add test for pad_get_params 2013-02-27 18:06:55 -06:00
James Lee 4edd46216f Refactor config -> opts
Puts all the evasion stuff in the same place as regular HTTP options to
make it easier to deal with.
2013-02-27 17:29:26 -06:00
James Lee 5606db3f9c Re-enable some commented tests 2013-02-27 16:28:17 -06:00
James Lee 29df20996e Move most of the configuration into ClientRequest
Also fixes in-place modification of the query string which resulted in
duplication of the GET parameters when calling #to_s more than once.
2013-02-26 17:38:09 -06:00
James Lee 935304ee0c No longer pending 2013-02-26 16:36:36 -06:00
James Lee 93537de68c Use let and subject blocks for better readability 2013-02-26 16:27:32 -06:00
James Lee 579c11bc69 Set reasonable defaults for more things
All current tests are passing now
2013-02-26 14:25:46 -06:00
James Lee c206ac4998 Set some reasonable defaults
Fixes a number of nil deref issues
2013-02-26 14:15:51 -06:00
James Lee 7b3a11f2f9 Axe tests that belong in client_request_spec 2013-02-26 13:28:44 -06:00
James Lee cae030ccd7 Whitespace 2013-02-26 13:25:37 -06:00
James Lee 5ac20e1b02 Merge branch 'feature/http/authv2' of git://github.com/dmaloney-r7/metasploit-framework into dmaloney-r7-feature/http/authv2
Conflicts:
	lib/rex/proto/http/client.rb
2013-02-26 12:08:00 -06:00
David Maloney c104fa6d97 Add spec and a few fixes for set_uri 2013-02-26 11:01:16 -06:00
James Lee 1ce86b7adb Whitespace 2013-02-25 14:29:10 -06:00
James Lee 904a69ba63 Move xor tests to the right filenames
Thanks, simplecov, for telling me that these weren't actually getting
run.
2013-02-25 13:02:03 -06:00
Tod Beardsley 73f6314373 Moving @cli and @ip to instance vars 2013-02-25 08:29:08 -06:00
Tod Beardsley caed599f7d Backed out all the fails from the auth bits 2013-02-25 08:26:02 -06:00
Tod Beardsley 6e35813d69 Pending hashes need to end w a block 2013-02-25 08:20:46 -06:00
James Lee 4a84528ecf Move pending messages to it()'s args 2013-02-20 15:02:12 -06:00
Tod Beardsley 5a0744934e Let's not intro functionality as testing
That's a bad habit to get into.
2013-02-11 21:06:52 -06:00
Tod Beardsley ba7f5a7245 Actually run this spec. 2013-02-11 21:04:57 -06:00
Tod Beardsley 039fd2b885 Adds some light testing for Rex's HTTP client lib
In light ofi PR #1476, it would be nice to have some basic, modern,
maintained testing on Rex's HTTP Client proto library.

My rspec fu is quite weak, of course, but this should cover the very
basic cases. There are lots of pending holes, but hey, it's a start.
2013-02-11 15:54:40 -06:00
David Maloney 949eb08062 In the final stages 2013-02-11 09:59:39 -06:00
David Maloney 0f9b16d07f Scanner class finished, result needs more work
the result class needs a nice clean to_s method to print easily readable
output. mostly working now. a few more tweaks needed.
2013-02-09 19:06:17 -06:00
David Maloney c25d4b4863 Test Cipher method underway
Trying to get a clever test plan under way to actually test the network
side of this. Not quite working yet
2013-02-09 01:07:56 -06:00
David Maloney 38d0a244fd Beginings of the actual scanner
configuration and configuration validation in place with tests.
2013-02-09 00:03:58 -06:00
David Maloney ccf18d6cb7 Finalize specsfor Result class 2013-02-08 17:20:04 -06:00
David Maloney 3295157f78 More support for various checks 2013-02-08 13:25:49 -06:00
David Maloney dfc7ce9381 fix stupid datat structure
also supports a boolean value for whether the cipher is weak or not
2013-02-08 11:33:36 -06:00
David Maloney 5c9f946927 empty shells for the scanner and its specs 2013-02-07 16:16:41 -06:00
David Maloney 096360261e De-dup cipher results 2013-02-07 16:09:47 -06:00
David Maloney 4e87bf4ab3 Add enumeration and support options
i lied, there's more. Adds two enumerators and methods to check for
specific ssl version support as well as a quick method to tell if the
server supports ssl at all.
2013-02-07 15:51:07 -06:00
David Maloney 10e017ae73 finish up the SSLScan::Result class
finishes up result class for SSLScan , compelte with tests
2013-02-07 14:56:26 -06:00
David Maloney 7036365e04 Start adding sslscan results object
Building out the result object for the SSlScan
2013-02-07 12:42:18 -06:00
James Lee 2ee0c0d8fb Add simple specs for Rex::Encoding::Xor* 2013-01-15 16:59:01 -06:00
Tod Beardsley f6478678ce trailing whitespace 2012-12-27 23:08:50 -06:00
David Maloney ee6db8794e Basic specs for meterpreter packet parser 2012-12-27 17:19:37 -06:00
David Maloney 74e543ec5a add spec skeleton for packet parser 2012-12-27 14:23:05 -06:00
David Maloney aaa8716f5b minor cleanup as per egypt 2012-12-12 10:12:42 -06:00
David Maloney c952ed0f87 Add test for raw format of packets 2012-12-07 12:51:53 -06:00
David Maloney b707f8d13a Packet specs now complete
82 tests for the packet lib
2012-12-07 12:32:34 -06:00
David Maloney 89c98ebd39 Finished tests for GroupTlv ftmp 2012-12-06 17:59:07 -06:00
David Maloney 468f637efe basics for adding tlvs to GroupTlv 2012-12-05 18:19:12 -06:00
David Maloney 5dcf573063 TLV tests down, on to GroupTlv 2012-12-05 17:55:28 -06:00
David Maloney 391ff5bbb0 basic TLV method tests 2012-12-05 15:44:03 -06:00
David Maloney b18f5b1875 Start with the duh stuff, responds_to 2012-12-05 14:39:29 -06:00
Luke Imhoff 055f95898d Merge branch 'master' into bug/wrong-file_changed-argument
Conflicts:
	lib/msf/core/modules/loader/base.rb
2012-10-24 15:25:49 -05:00