Commit Graph

415 Commits

Author SHA1 Message Date
christopher lee 038fe03777 Merge branch 'master' into ms-2962 2018-05-02 15:31:57 -05:00
christopher lee 41307e62f8 remove puts 2018-04-27 15:50:21 -05:00
christopher lee 0a73a5007c Removed duplicated online test 2018-04-27 09:37:17 -05:00
christopher lee 9c7db375bf Fix broken tests after latest merge with master 2018-04-26 16:39:56 -05:00
christopher lee 516b61ebaa Merged master 2018-04-26 16:02:56 -05:00
Matthew Kienow c79e39377e Narrow rescue scope to StandardError 2018-04-26 14:55:41 -04:00
James Barnett a5172e066d Land #9926, check remote data service before connecting
This PR adds a check prior to connecting to a remote data service
to verify it is online and returning expected data. This prevents
crashes that were occurring when unexpected responses were returned
2018-04-25 14:07:33 -05:00
christopher lee 071a191055 Merge master + workspace removal from http remote data service 2018-04-25 13:39:46 -05:00
Brent Cook 3eac989fb0 Land #9886, ignore unused tags on host import 2018-04-25 03:41:55 -05:00
Matthew Kienow 0d284197cb Add MsfServlet to host endpoint for online check 2018-04-24 15:01:17 -04:00
James Barnett e5513409db Include :workspace in db_import opts 2018-04-24 13:53:55 -05:00
James Barnett f4a949e649 Fix bug creating sessions when connected to remote data service 2018-04-19 16:19:39 -05:00
James Barnett 31be847213 Add workspace when reporting vuln_attempt 2018-04-19 11:09:13 -05:00
James Barnett aa40ef1789 Grab session_dto workspace from host 2018-04-18 17:38:42 -05:00
James Barnett 81d00fa5b7 Fix edge cases in workspace update 2018-04-18 12:56:38 -05:00
James Barnett d4a2703ff1 Dont stop host parsing if id tag found
Also make clarify 'bl' variable name.
2018-04-18 10:12:12 -05:00
James Barnett 77558cd2d7 Remove unused code 2018-04-17 14:28:28 -05:00
James Barnett 82798424b2 Support getting a workspace via id
Also implements a helper method to sanitize sinatra injected
params since it was causing issues downstream. Updated each
use of sinatra params to use this helper method.
2018-04-17 12:35:22 -05:00
James Barnett b569498250 Address more code review comments 2018-04-17 10:52:56 -05:00
James Barnett a8a95a03a3 Implement remote workspace delete 2018-04-17 10:19:40 -05:00
James Barnett 68ad91763a Merge branch 'rapid7/master' into MS-3062_workspaces 2018-04-16 15:33:59 -05:00
James Barnett 2ef451c349 Land #9873, add notes functionality to remote datastore
This PR enables create, update, and delete functionality for the notes
command and data model when using a remote data service.
2018-04-16 15:03:27 -05:00
Matthew Kienow e283f109a7 Remove commented out code 2018-04-16 14:14:46 -04:00
Matthew Kienow 37479d8fd4 Modify notes search to handle serialized data
Initial Goliath notes search implementation attempted to use Arel and
decode base64 serialized data column, however, this was not without
issue. Updated implementation retrieves all records that match
conditions, thus data has been deserialized and then filters using
specified search term.
2018-04-12 17:37:16 -04:00
James Barnett 86b6009999 Land #9860, Fix DB init when database.yml is missing
This PR fixes a bug introduced with goliath that caused incorrect error messages
and other error messages when no database.yml was present. It also improves the
messaging around that use case and loads CommandDispatcher::Db correctly.
2018-04-11 16:13:40 -05:00
Matthew Kienow 3db19fe4f2 Fix DBManager::Service use of services method
services method was previously modified to use a hash as the parameter,
but each_service was passing a workspace. Make each_service method
consistent with other DBManager modules.
2018-04-11 11:43:12 -04:00
Matthew Kienow e639fda53c Fix DB initialization with no database YAML 2018-04-11 09:15:38 -04:00
James Barnett cd48b47760 Fix failing tests.
-Was accidentally deleting opts[:workspace] instead of processing
-Update notes help text expectations
2018-04-10 17:10:32 -05:00
James Barnett e51f41fa34 Merge remote-tracking branch 'msf_jbarnett/fix_services_bugs' into MS-3062_workspaces 2018-04-10 13:35:33 -05:00
James Barnett 48c0bbfa7a Only display the services for a given workspace 2018-04-10 10:28:02 -05:00
James Barnett 90542779ff Audit models to ensure :workspace is passed only when needed 2018-04-09 14:50:37 -05:00
James Barnett fe224f628b Remove update_host_via_sysinfo since it is unused 2018-04-05 14:20:25 -05:00
James Barnett 852bc3d237 Dont inject :workspace into every HTTP request. 2018-04-04 16:30:25 -05:00
James Barnett 6a02712674 Merge remote-tracking branch 'mkienow/MS-3061-remote-notes-read-update-delete' into MS-3062_workspaces 2018-04-04 16:03:43 -05:00
Jon Hart bc81cfad1f Fix error handling when trying to delete non-existent workspace 2018-04-04 11:40:21 -07:00
James Barnett e892911fbe Use a constant for default workspace name 2018-04-02 17:02:14 -05:00
christopher lee 3aed6d6666 Initial 2018-04-02 08:08:23 -05:00
Matthew Kienow cb2366d2eb Fix regex search for serialized data column 2018-03-30 19:25:38 -04:00
James Barnett ecbbf1d940 Pass workspace when using db_nmap 2018-03-30 15:27:32 -05:00
James Barnett f41490728b Process workspace when importing nmap data 2018-03-29 11:46:34 -05:00
James Barnett 1b6aa86d92 Merge remote-tracking branch 'mkienow/MS-3061-remote-notes-read-update-delete' into MS-3062_workspaces 2018-03-27 15:57:41 -05:00
Matthew Kienow 0b5d3d31f9 WIP remote note read, update, delete 2018-03-27 16:36:56 -04:00
christopher lee abf16a4469 fix workspace tests 2018-03-27 10:41:08 -05:00
James Barnett 83f2052ee7 Accidentally q 2018-03-26 16:09:56 -05:00
James Barnett cfa03a999c Finish moving current_workspace tracking to client 2018-03-26 15:58:47 -05:00
James Barnett def0e4d93b Merge branch 'goliath' into MS-3062_workspaces 2018-03-23 11:37:01 -05:00
James Barnett ed5b22a541 Address more code review comments 2018-03-22 21:47:59 -05:00
James Barnett 6c5a7a663a Merge branch 'goliath' into MS-2879_db_export 2018-03-22 21:22:23 -05:00
James Barnett 466c97f114 WIP: move tracking active workspace to client side
* Move the @current_workspace tracking to workspace proxy
* Create helper for handling workspace value in opts
* Call framework.db.proxy across dbmanager files now that active ws is tracked in proxy

NOTE: This commit throws an exception when adding a remote data service.
2018-03-22 21:00:06 -05:00
James Barnett 93d4f5cd0b Last few review comments 2018-03-21 17:50:11 -05:00