Commit Graph

933 Commits (3bb220c94badac84b61e99e4294abc02dd7c63b8)

Author SHA1 Message Date
Raphaël Vinot 19a50a7ba7 chg: Use new format for filtering. 2017-12-14 11:06:52 +01:00
Raphaël Vinot 78d9673e24 chg: Bump misp-objects 2017-12-13 18:01:42 +01:00
Raphaël Vinot f15341d1cf chg: Bump describeTypes 2017-12-13 18:00:35 +01:00
Raphaël Vinot 68afcf1c38 chg: Bump misp-objects 2017-12-13 17:12:35 +01:00
Raphaël Vinot f02f889077 chg: Bump version 2017-12-13 17:09:46 +01:00
Raphaël Vinot 6db31b397a new: Add methods to get taxonomy(ies)
Thanks to @truckydev
2017-12-13 16:43:21 +01:00
Raphaël Vinot fe00b0b712
Merge pull request #151 from MISP/refactor
chg: Make the library easier to use
2017-12-13 15:58:56 +01:00
Raphaël Vinot 6c4e2b2861
Merge pull request #150 from sdrees/first-friendly-contribution-enhance-coverage
First friendly contribution enhance coverage
2017-12-13 15:47:43 +01:00
Raphaël Vinot d19a10ddcc chg: Make the library easier to use 2017-12-13 15:45:02 +01:00
Raphaël Vinot 5cbcc09d7d new: Add method to get all the events modified in an interval 2017-12-11 15:01:25 +01:00
Stefan Hagen (Individual) 207e1f195e Merge branch 'master' of https://github.com/MISP/PyMISP into first-friendly-contribution-enhance-coverage 2017-12-11 14:04:04 +01:00
Raphaël Vinot 9f8f15fb2b Merge branch 'get_last_modified_event' of https://github.com/truckydev/PyMISP into truckydev-get_last_modified_event 2017-12-11 14:03:37 +01:00
Stefan Hagen (Individual) e7f395a92c enhance coverage and fix en passant with focus on api 2017-12-11 14:00:43 +01:00
Raphaël Vinot 7946e2ef83 fix: Disable pseudofile support in py2, skip tests. 2017-12-09 13:35:44 +01:00
Raphaël Vinot 52e079fea2 chg: Allow to pass a pseudofile to LIEF 2017-12-09 13:12:04 +01:00
Raphaël Vinot ab3a6bb404 chg: Bump misp-objects 2017-12-09 11:52:26 +01:00
StrayLightning 748be6a093 Improve the exception message for a server 500+ response with no response content 2017-12-05 18:04:11 +00:00
StrayLightning 8a8b0c113d Check for zero-length 500 response from the server and produce a suitable error message
In experimenting with PyMISP I am triggering problems on the server I
am using.  Occasionally the server will return a 500 response with a
message indicating an internal error, but more often than not it returns
a 500 response with no contents, and _check_response falls over itself,
generating hard-to-fathom exception from the json internals.

This commit hardens _check_response by detecting zero-length responses
and raising a suitable exception.

Also fix a missing bracket in one of the subsequent exception strings.
2017-12-05 17:44:15 +00:00
Raphaël Vinot 1d190cdf50
Merge pull request #146 from c-goes/lief_integrity_exception
Make FileObject creation work if lief parsing fails
2017-12-04 18:57:52 +01:00
Raphaël Vinot 42c5cc5e37 chg: allow to pass a proxy to query VT 2017-12-04 18:43:44 +01:00
c-goes b514600965 Make FileObject creation work if lief parsing fails 2017-12-04 17:52:13 +01:00
Raphaël Vinot 5d0cc16e75 Merge branch 'master' of github.com:MISP/PyMISP 2017-12-04 14:12:18 +01:00
Raphaël Vinot 2ec1f20bc6 chg: Bump misp-objects 2017-12-04 14:11:45 +01:00
Raphaël Vinot 5e931ffde7
Merge pull request #144 from c-goes/objects_delete
allow deletion of objects and object references
2017-12-02 21:36:44 +01:00
Raphaël Vinot 119169d4eb chg: Bump version to 2.4.83 2017-12-01 17:55:58 +01:00
Raphaël Vinot be65733d73 chg: Do not get the event from the server before publishing if PyMISP.publish gets an ID 2017-12-01 16:47:06 +01:00
Raphaël Vinot f4439ae970 chg: Add live tests for recommended pymisp version and describeTypes up-to-date 2017-12-01 16:15:46 +01:00
Raphaël Vinot 9a2b82a2ae chg: Add a way to check if the ACL is up-to-date 2017-12-01 14:35:19 +01:00
Raphaël Vinot eb5cf6c06c chg: Add validators for describeTypes on the live instance 2017-12-01 14:02:04 +01:00
Raphaël Vinot 9c7923fe0a new: Add get CSV method. 2017-12-01 12:01:42 +01:00
Raphaël Vinot 2e46f00055 fix: Bump describeTypes.json
Add testing
2017-12-01 10:36:09 +01:00
Tristan METAYER 60f3111f47 - Correction for 'last' param.
'last' gives the latest events that have been published
- add get_events_last_modified()
this function returns the modified events based on timestamp
2017-11-29 16:46:41 +01:00
Raphaël Vinot 0875ad4a5f chg: Add example file to push OpenIOC file to MISP
chg: Add some imports in the tool's init file
2017-11-28 11:54:08 +01:00
c-goes 4416fe30b1 allow deletion of objects and object references 2017-11-23 17:51:04 +01:00
Raphaël Vinot d4b8df380f chg: Bump misp-objects 2017-11-23 10:17:36 +01:00
3c7 069023e802 Adding multiple named attributes require a single POST request now 2017-11-22 14:57:11 +01:00
c-goes 2e5fcf4e31 fixed typo 2017-11-20 15:11:30 +01:00
Steve Clement 89a5558014 - Remove CIRCL reference from README.md
- Updated 2 bad indentations where epydoc was Warning
2017-11-19 10:02:03 +01:00
Raphaël Vinot 44831b1fdb chg: Add new objects: MISPUser and MISPOrganisation 2017-11-17 16:51:46 +01:00
Raphaël Vinot bfe9867b2e chg: Add a generic MISP object generator 2017-11-15 17:37:17 +01:00
Raphaël Vinot b1262a0c96 chg: Add fast publish method
Fix #86
2017-11-10 15:42:07 -08:00
Raphaël Vinot 55b4064a57 chg: Improve documentation
Fix #121
2017-11-10 14:56:53 -08:00
Raphaël Vinot 31e98c6e5d chg: Bump PyMISP version 2017-11-09 13:49:09 -08:00
Raphaël Vinot 5d414cb8e9 chg: Bump misp-objects 2017-11-09 13:45:31 -08:00
Raphaël Vinot f54a029e2a new: Proper debug system
Make it easy to investigate the json blobs sent to the server.
2017-11-08 17:33:55 -08:00
Raphaël Vinot 4512a4eaca chg: small improvments in the logging system 2017-11-07 19:10:54 -08:00
Raphaël Vinot f1a88f460e fix: Typo loger -> logger 2017-11-07 18:19:57 -08:00
Raphaël Vinot 134df0cafb chg: Properly use python logging module. 2017-11-07 18:10:04 -08:00
Raphaël Vinot 0e123af546 fix: Let load unknown object relations in known templates
This isn't recommended, but happens very often.
2017-11-02 09:57:53 -07:00
Raphaël Vinot 75d96b2d7a fix: Allow to load non-malware ZIP files in MISP Event
Prior to his patch, any zip file loaded by MISP Event was unpacked and
processed as an excrypted malware from MISP.
2017-11-02 09:26:05 -07:00
Raphaël Vinot e5a7153284 fix: Properly pass the distribution when uploading a sample
Fix: https://github.com/MISP/PyMISP/issues/129
2017-11-01 17:26:58 -07:00
Raphaël Vinot 4b53b399d0 fix: Properly upload a sample in an existing event.
Fix https://github.com/MISP/PyMISP/issues/123
2017-11-01 17:15:49 -07:00
Raphaël Vinot 7ece6b7fbc fix: Properly set the distribution at event level
fix #120
2017-10-28 17:09:11 -04:00
Raphaël Vinot 30da658292 chg: Remove warning if PyMISP is too new 2017-10-28 16:57:03 -04:00
Raphaël Vinot 14bc9e4b19 fix: Properly pop the distribution key. 2017-10-26 12:05:51 -04:00
Raphaël Vinot 78eb6e3080 fix: Update dependencies for VT generator. 2017-10-25 15:00:00 -04:00
Thomas Gardner e2d690d0ef added vtreportobject and vt_to_misp example 2017-10-25 09:48:18 -04:00
Raphaël Vinot 23f82e68cd chg: version bump 2017-10-24 09:07:57 -04:00
Raphaël Vinot 7686020f95 chg: Bump version 2017-10-24 08:54:38 -04:00
Raphaël Vinot 85669abbcb chg: Do not raise an exception when the object template is unknown.
+ bump misp-object
2017-10-24 08:52:00 -04:00
Raphaël Vinot cb166a6295 chg: Bump misp-objects 2017-10-23 11:53:21 -04:00
Raphaël Vinot 4c4cd23983 chg: Allow to hard delete an attribute by ID. 2017-10-22 14:02:47 -04:00
Raphaël Vinot a63d53094f fix: Fix typos and logic mistakes in mispevent. 2017-10-22 12:17:48 -04:00
Raphaël Vinot 45684cfd5f chg: Update comments 2017-10-21 20:22:38 +02:00
Andras Iklody cae7f635ea Update openioc.py 2017-10-18 16:27:54 +02:00
Raphaël Vinot c49008a636 fix: Missing default category
Fix #119
2017-10-18 08:36:19 +02:00
Raphaël Vinot c5f8cc88a2 chg: Bump misp-objects and describeTypes 2017-10-18 08:30:35 +02:00
tssbo82 8032e5f06d Added **kwargs to add_named_attribute call in add_attachment 2017-10-09 15:54:20 -04:00
Raphaël Vinot 9beb2da1b1 up: bump version 2017-10-09 16:14:17 +02:00
Raphaël Vinot 474db01d8e up: Bump misp-objects 2017-10-09 16:13:41 +02:00
Raphaël Vinot 182a70b02f up: Version bump 2017-10-04 10:06:37 +02:00
Raphaël Vinot b298f8de6e up: Bump misp-objects & describeTypes 2017-10-04 10:03:42 +02:00
Raphaël Vinot 3e73ae826f Fix: create file object
Was broken in case the file was neither PE/ELF/Mach-O
2017-09-27 16:05:06 +02:00
Raphaël Vinot 6d2576be0a fix: Allow again to tag/delete unsaved attributes 2017-09-26 10:52:38 +01:00
cgi1 7ad02eb68c Similar to #114 on attribute level
`add_attribute_tag(tag,attribute_identifier)` fails if attribute does not have any tag in before.
2017-09-25 13:43:25 +02:00
cgi1 4fee9b0c85 Fixing #114 2017-09-25 10:01:23 +02:00
infosec-intern f08f744cc2 Formatted "Unknown MISP object" error message
When a user tries to add an object with a name that doesn't exist, the error thrown was missing its format string
This ended up looking like
pymisp.exceptions.UnknownMISPObjectTemplate: {} is unknown in the MISP object directory.
Here's a patch that adds self.name to the format string
2017-09-22 11:43:20 -06:00
Raphaël Vinot d3d34d5953 update: make make_binary_objects more flexible
fix: use proper exception handlers
2017-09-20 11:44:55 +01:00
Raphaël Vinot 8c3f2e5ff8 fix: import the openioc converter from tool again 2017-09-20 11:24:51 +01:00
Raphaël Vinot 6eb807381d Properly initialize a new malware sample 2017-09-18 15:37:55 +01:00
Raphaël Vinot b1989f16f2 Merge branch 'objects' 2017-09-18 11:43:48 +01:00
Raphaël Vinot 9abaed0499 Bump misp object 2017-09-18 11:37:09 +01:00
Raphaël Vinot 6dfaa78722 Allow to get the list of known types out of MISPEvent again 2017-09-14 14:34:53 +02:00
Raphaël Vinot b3c15da967 Merge branch 'objects' of github.com:MISP/PyMISP into objects 2017-09-12 16:55:29 +02:00
Raphaël Vinot da2b28a927 Use MISPAbstract as a master class everywhere.
This is probably breaking everything.... ¯\_(ツ)_/¯
2017-09-12 16:46:06 +02:00
iglocska b337e77070 changed source => object / destination => referenced 2017-09-07 16:09:45 +02:00
Raphaël Vinot 2a5f3346e4 Bump miso-objects 2017-09-07 14:30:05 +02:00
iglocska c15b82c45a Changed two fields in object references
- source_uuid => object_uuid
- destination_uuid => referenced_uuid
2017-09-07 14:01:13 +02:00
Raphaël Vinot b74e558f75 Some more refactoring 2017-08-31 10:40:18 +02:00
Raphaël Vinot 74037cb6fa Some more refactoring and cleanup 2017-08-30 12:47:32 +02:00
Raphaël Vinot 69ede74ce7 Update object definitions 2017-08-29 18:38:28 +02:00
Raphaël Vinot 8452e16dbd Update PE generator 2017-08-29 10:25:45 +02:00
Raphaël Vinot 2bc0745fbf Refactoring in order to load objects 2017-08-28 19:16:20 +02:00
Raphaël Vinot 44f32bc443 Add support for multiple entries of the same type in an object 2017-08-27 18:12:42 +02:00
Raphaël Vinot ed441d6356 Remove some python versions from travis 2017-08-25 18:35:53 +02:00
Raphaël Vinot a5531990ae Do not try to run code requiring lief 2017-08-25 17:41:58 +02:00
Raphaël Vinot 9ff3739753 Remove ImportError 2017-08-25 17:37:35 +02:00
Raphaël Vinot f06bfd310b Do not fail if pymisp is not installed 2017-08-25 16:38:12 +02:00
Raphaël Vinot 44008d1c0c Add support for ELF and MachO objects 2017-08-25 15:57:12 +02:00
Raphaël Vinot bfa5b67c1d Version bump 2017-08-25 14:25:51 +02:00
Raphaël Vinot f66af15c62 Update get_template_id, cleanup 2017-08-25 09:45:56 +02:00
Raphaël Vinot c09ce0032c Refactor all the things
Add script for MISP core, make everything generic.
2017-08-24 19:21:52 +02:00
edhoedt bd6deba55e Fixing undefined ressources_path 2017-08-24 17:09:19 +02:00
Raphaël Vinot e567ddc877 Update function names in mispevent 2017-08-24 17:09:16 +02:00
Raphaël Vinot 314f7eaed1 Re-enable python < 3.5 support. 2017-08-23 16:55:32 +02:00
Raphaël Vinot 77845bd813 Update file/pe/pe-sections objects creator. 2017-08-23 15:37:04 +02:00
Raphaël Vinot 3c443095e8 Exact match on the value when adding tag. 2017-08-22 10:07:34 +02:00
Raphaël Vinot 6d06b77d76 Improve event ID detection in publish method 2017-08-04 19:30:40 +02:00
Raphaël Vinot 57778d2b0b Merge branch 'patch-8' of https://github.com/Deventual/PyMISP into Deventual-patch-8 2017-08-04 19:17:26 +02:00
Hannah Ward 394c312d0d
new: Add ZMQ publishing method 2017-08-03 16:17:37 +01:00
Deventual a9d4ab829b Update api.py 2017-08-03 14:22:48 +03:00
Deventual c8d962a594 Implemented much faster publish method to replace the old one
new publish method that is less resourceful and also having the ability to send emails (same as the web interface).
The method depends on the publish misp api method instead of update.
2017-08-03 14:19:48 +03:00
Raphaël Vinot 533b69d944 Update path to roles API 2017-07-31 17:28:47 +02:00
Raphaël Vinot 622a5701ee Fix typo in variable name. 2017-07-27 17:14:49 +02:00
Raphaël Vinot 0c86d489b6 Merge pull request #99 from edhoedt/patch-1
Fixing undefined ressources_path
2017-07-27 16:02:27 +02:00
Raphaël Vinot 0db710a586 Allow to load the event_id in MISPAttrbute 2017-07-27 15:42:56 +02:00
edhoedt b4dea5173f Fixing undefined ressources_path 2017-07-27 14:54:02 +02:00
Raphaël Vinot 41b5672360 Doesn't require describe_types in MISPAttribute's constructor. 2017-07-26 11:28:50 +02:00
Raphaël Vinot 1d6c63c54c Doesn't require describe_types in MISPAttribute's constructor. 2017-07-26 10:10:12 +02:00
Raphaël Vinot 2fd3b05202 Update accordingly to the current server implementation 2017-07-24 17:16:40 +02:00
Sebastian Wagner 5a85788c5d
Fix shebangs and executable permissions
Files containing a shebang should be executable (examples/*.py)
Non-executable files should not contain a shebang (pymisp/...)

spotted with rpmlint
2017-07-24 13:27:28 +02:00
Raphaël Vinot 0c66d80dd1 Re-enable python2 support... 2017-07-22 22:22:39 +02:00
Raphaël Vinot 78488db7aa Initial commit supporting MISP Objects 2017-07-21 20:34:56 +02:00
Raphaël Vinot 14fcc5f586 Fix typo in the method name 2017-07-21 15:16:00 +02:00
Raphaël Vinot f679e8aa7d Update describe types 2017-07-21 10:12:32 +02:00
Raphaël Vinot 5f94ad3104 Add test of the authkey, update warnings. 2017-07-20 15:33:15 +02:00
Raphaël Vinot fe829b8f4d Search paramaters validation.
Fix #96
2017-07-18 12:07:47 +02:00
Raphaël Vinot 59f9b37b5e Allow to pass a bytestream to upload_sample.
Fix #101
2017-07-18 11:26:09 +02:00
Raphaël Vinot af636812fd Fix get_attachment.
Fix #105
2017-07-18 10:55:49 +02:00
Raphaël Vinot e39d014ddc Update describeTypes.json 2017-07-17 16:49:40 +02:00
Raphaël Vinot ae40bf5d1b Allow to list roles and tags on a MISP instance 2017-07-15 20:35:58 +02:00
Raphaël Vinot c91849b468 Improve errors flattening 2017-07-15 20:35:00 +02:00
Raphaël Vinot cd7f928382 Version bump 2017-07-12 16:16:45 +02:00
Raphaël Vinot d0eb1252ae Avoid a comment set to NoneNone
Fix https://github.com/MISP/misp-modules/issues/127
2017-07-12 12:13:34 +02:00
Alex Bolshakov 8b0c379b7f Add handling a string response
To avoid AttributeError when variable to_return is a string with a value "Pull queued for background execution."
2017-07-12 12:51:26 +03:00
Raphaël Vinot 9fc631cc85 Simplfy MISPEvent.add_attribute 2017-07-12 11:25:41 +02:00
Raphaël Vinot 481c8e4790 Revert "Simplfy MISPEvent.add_attribute"
This reverts commit f64f42ac71.
2017-07-12 11:24:21 +02:00
Raphaël Vinot f64f42ac71 Simplfy MISPEvent.add_attribute 2017-07-12 11:08:58 +02:00
Raphaël Vinot bb9642445a Revert "Fix OpenIOC import"
This reverts commit acd6d8b052.
2017-07-12 11:07:54 +02:00
Raphaël Vinot acd6d8b052 Fix OpenIOC import 2017-07-12 10:49:45 +02:00
Raphaël Vinot a0273b8a43 Merge branch 'master' of github.com:CIRCL/PyMISP 2017-07-11 16:15:59 +02:00
obsidianpentesting c18d5cac6d Simple function to cache all feeds at once. This is almost identical to fetch_feed. In the future, I would like to specify the scope to include other values. 2017-07-06 16:06:59 -05:00
raw-data 6139caae2f exposing more feeds functions (for which _isRest() is available) to the API 2017-07-03 21:56:44 +01:00
Alexandre Dulaunoy 4a21727b2f Merge branch 'master' of github.com:CIRCL/PyMISP 2017-06-20 12:23:19 +02:00
Hannah Ward 64f1edd5b4
fix: If array passed to add_attrib, add each individually 2017-06-16 12:25:27 +01:00
Raphaël Vinot e8caa6a7b1 Merge pull request #102 from aparriel/debug-fix
Fix missing %s in debug
2017-06-13 16:04:46 +02:00
Raphaël Vinot 72a484ca32 Add support for freetext import in the API. 2017-06-13 15:37:39 +02:00
Alexandre Dulaunoy b73435949f Typo fixed
Paris is not the center of the world as the idiot of the World village
would said.
2017-06-02 09:12:00 +02:00
aparriel 72382f7618 Fix missing %s in debug
Missing %s in logger.debug call lead to error.
2017-05-31 18:07:31 +02:00
CheYenBzh 01770aa51e Add function to fetch all events from a feed
Function takes the feed id as argument (-f).
2017-05-29 13:57:02 +02:00
Raphaël Vinot b43722c73f Make pep8 happy 2017-05-24 07:38:17 +02:00
George 0bdef56001 Fix not_values type check in __prepare_rest_search 2017-05-19 18:19:21 +02:00
Hannah Ward a7892c03ff
fix: Don't even bother trying with futuressession if Async isn't ok
fixes #85
2017-05-16 10:27:54 +01:00
Tristan METAYER d72d3dceb7 correction for https://travis-ci.org/MISP/misp-modules/jobs/231065469
code refactoring

add new composite
2017-05-15 20:25:16 +02:00
Raphaël Vinot 619cb10403 Cleanup warning function 2017-05-03 16:52:57 +02:00
Raphaël Vinot 8b3d17c5d0 Fix typos 2017-05-03 16:49:51 +02:00
Raphaël Vinot db768ffef0 Merge pull request #82 from truckydev/master
add mapping and composite feature
2017-05-03 16:35:22 +02:00
Raphaël Vinot e76f19e793 Merge pull request #83 from bernhl/fix_api_version_check
Fix checks of recommended version
2017-05-03 15:57:42 +02:00
Raphaël Vinot ba6568eb46 Merge branch 'master' into logging 2017-05-03 15:42:01 +02:00
Tristan METAYER e232392335 remove unused variable 2017-05-03 15:36:08 +02:00
Tristan METAYER 2267e8a97b remove category
It will be automaticly detected
https://github.com/MISP/PyMISP/blob/master/pymisp/tools/openioc.py
2017-05-03 15:19:27 +02:00
Lukas Bernhard 3e4e76c21e Fix checks of recommended version 2017-05-03 14:49:16 +02:00
fluxas 0bee414592 Use logging instead of print; deprecate debug param 2017-05-03 14:14:13 +02:00
fluxas 6ec2513184 Add exception types to api.py 2017-05-03 13:22:15 +02:00
Hannah Ward e5f9c0b704
new: Enable async option for search() 2017-05-03 10:13:18 +01:00
Tristan METAYER 6548ed6e6f revert tab to escape 2017-05-03 10:56:41 +02:00
Hannah Ward d2b0c506a4
Merge branch 'master' of github.com:MISP/PyMISP 2017-05-03 09:47:44 +01:00
Hannah Ward 36661439cc
Merge branch 'async' 2017-05-03 09:43:45 +01:00
Paul A 9bfa24155c Normalize output between misp.search_index and misp.search
Fix issue: https://github.com/CIRCL/PyMISP/issues/78
2017-05-03 10:32:14 +02:00
Tristan METAYER abe54225b7 Ajout de mapping
Ajout de la prise en compte d'autre composite
2017-05-02 18:47:53 +02:00
Hannah Ward e86ffab5f4 Merge branch 'master' of github.com:MISP/PyMISP 2017-05-02 12:10:23 +01:00
Hannah Ward e7f9731179
fix: can't instantiate basestring
fixes #76
2017-05-02 12:09:59 +01:00
Hannah Ward a81e8f0b6d
fix: Added docstring for search 2017-05-02 10:12:25 +01:00
Hannah Ward 8f9e2a77e5
fix: Add docstring for asynch 2017-05-02 10:11:01 +01:00
Raphaël Vinot a4ac1b2c7f Quick and dirty fix for #97 2017-04-14 14:41:55 +02:00
Raphaël Vinot 4a2021f244 Fix testing 2017-04-13 16:56:28 +02:00
Raphaël Vinot 52a87ccfe0 Allow to pass some parameters as False or 0.
When creating or updating users and organisations

Fix #70
2017-04-13 15:05:13 +02:00
Raphaël Vinot 60b78fd885 Use POST instead of get in search_index
Fix #73
2017-04-13 14:51:50 +02:00
Raphaël Vinot c74cdd19c6 Fix typos and pep8 2017-04-11 15:59:12 +02:00
Raphaël Vinot bd7d782716 Update types 2017-04-11 15:55:49 +02:00
Raphaël Vinot 6d76141c35 Version Dump 2017-04-11 15:53:26 +02:00
Hannah Ward bcffa2f310
fix: Pass disable_correlation flag from add_attribute 2017-04-11 14:35:41 +01:00
Raphaël Vinot deb88969b5 Merge pull request #69 from SekoiaLab/fix/serverCreation
Fix/server creation
2017-04-11 10:51:01 +02:00
Raphaël Vinot 816bd0b6d5 Merge pull request #71 from SekoiaLab/fix/remoteOrgUUID
fix: raise exception if uuid not setted in remote org
2017-04-11 10:47:48 +02:00
Raphaël Vinot 540c54e2c1 Merge pull request #72 from SekoiaLab/feat/getAllOrganisations
feat: add filter to specify which organisation to list
2017-04-11 10:47:02 +02:00
Adrien RAFFIN 4ecfc1ada4 feat: add filter to specify which organisation to list 2017-04-10 17:23:44 +02:00
Adrien RAFFIN e46a74b41a fix: Add default values for mandatory variable 2017-04-10 14:14:55 +02:00
Raphaël Vinot bcb3b8cdfb Update validation
* Allow strict validation
* Add workaround to avoid all JSON dumps from MISP <=2.4.70 to fail
2017-04-09 00:02:02 +02:00
Raphaël Vinot 1dda8eb40a Merge branch 'master' of github.com:MISP/PyMISP 2017-04-07 17:31:27 +02:00
Raphaël Vinot 25795df308 Major rewrite of the schema 2017-04-07 17:30:43 +02:00
Adrien RAFFIN 46ef153d4b fix: raise exception if uuid not setted in remote org 2017-04-07 17:13:11 +02:00
Adrien RAFFIN 6ab8eee9e8 fix: org_type was not the correct variable 2017-04-07 17:10:47 +02:00
Hannah Ward 75fa1de2e4
fix: don't double-json-encode when sending proposals 2017-04-04 10:07:29 +01:00
Raphaël Vinot becaecaec8 Merge branch 'master' of github.com:CIRCL/PyMISP 2017-04-03 10:05:48 +02:00
Raphaël Vinot f6dc991751 Properly display deprecation warning 2017-04-03 10:04:59 +02:00
Raphaël Vinot 4f694ba389 Merge pull request #95 from RichieB2B/ncsc-nl/send-attributes
Return json when adding attributes
2017-03-31 12:12:02 +02:00
Raphaël Vinot 142566df4d Fix python 3 support
Fix #94
2017-03-31 11:44:48 +02:00
Richard van den Berg 6fef2c60e3 Return json when adding attributes 2017-03-31 11:29:02 +02:00
Raphaël Vinot 7d34153e0e Merge pull request #63 from TheDr1ver/patch-5
publish_timestamp Windows 7 Fix
2017-03-15 14:16:00 +01:00
Raphaël Vinot 8dd0914a73 Allow to pass a MISPEvent to add_event and update_event 2017-03-15 14:10:51 +01:00
Nick Driver d9bef7d65e extended the Windows fix to lines 168 and 471 2017-03-15 09:03:02 -04:00
Raphaël Vinot 38f2dbe94d Add an attributes to an event without sending the full existing event 2017-03-15 11:33:24 +01:00
Nick Driver 4aa0df9d1f publish_timestamp Windows 7 Fix
On Windows 7 datetime.datetime.fromtimestamp(int(0)) returns a date before 1970, which causes the script to crash. This fixes the bug.
2017-03-14 11:07:31 -04:00
Raphaël Vinot a7e66ca5db Allow to pass None to to_ids, default to sane default 2017-03-14 15:58:54 +01:00
Raphaël Vinot c875fde6ea Merge branch 'master' of github.com:MISP/PyMISP 2017-03-12 23:05:25 +01:00
Raphaël Vinot 638ad3d4b7 Update types, allow 0 as attribute value 2017-03-12 23:05:13 +01:00
Déborah Servili 0636b9393e fix add_domain_ip 2017-03-10 14:48:11 +01:00
Hannah Ward b3376183c0
fix: Entrypt isn't a word!
fixes #59
2017-03-09 16:36:30 +00:00
Raphaël Vinot e029b60455 Version bump 2017-03-09 16:43:40 +01:00
Raphaël Vinot fc80e711a9 Merge branch 'master' of github.com:MISP/PyMISP 2017-03-09 16:33:29 +01:00
Raphaël Vinot 1da447abf2 Reorganisation, make add attribute more flexible 2017-03-09 16:32:51 +01:00
rmarsollier 29a211ac64 Using the facilities introduced by MISP commit bdbd0920ba760a514cffdb30cc741b61b589d9da
(fix: attachTagToObject and removeTagFromObject now accept posted JSON objects)
2017-03-09 15:36:27 +01:00
rmarsollier 9c36afbcc6 throw exception for invalid uuid 2017-03-08 17:02:34 +01:00
Raphaël Vinot c348fcc7dc Properly split ip:port for ipv4 (openioc import) 2017-02-27 18:38:52 +01:00
Raphaël Vinot be0c8a1f8c Properly support CDATA fields in OpenIOC files. 2017-02-27 18:01:37 +01:00
Raphaël Vinot 17d6a3e27e Version bump 2017-02-27 13:34:28 +01:00
Raphaël Vinot a55603e5c8 Allow to pass a pseudo file to OpenIOC loader. 2017-02-27 11:33:07 +01:00
Raphaël Vinot 8175a0ecf0 Security fix: do not try to load any valid path as a MISP Event.
The MISP Event loader was trying to open any string passed as parameter
if is an existing filepath. Anything that isn't a valid MISP event would
raise an exception, but I can see it used for malicous purposes.

load_file is will do the same, but the user can decide if it is safe to
use.
2017-02-27 11:28:12 +01:00
Raphaël Vinot ee3f0fb9ca Allow filenames with regexes.
Fix #52
2017-02-23 16:59:37 +01:00
Raphaël Vinot ad02ebdef7 Merge pull request #53 from SekoiaLab/feature/serversRestApi
Adds new methods to add and edit servers in MISP
2017-02-23 16:11:47 +01:00
Raphaël Vinot 4be491b7a0 Merge pull request #51 from SekoiaLab/feature/AddAuthkeyAtCreation
feature: Add support for authkey in PyMISP operations
2017-02-23 14:46:42 +01:00
Sebastien Quioc cb8f4acf64 feature: Adds new methods to edit servers in MISP 2017-02-23 14:37:11 +01:00
Sebastien Quioc f0038d4be3 feature: Adds new methods to add new servers in MISP 2017-02-23 14:37:11 +01:00
iglocska 9576058bb4 Merge branch 'master' into errorhandling2 2017-02-22 09:27:19 +01:00
iglocska 13871dbd77 potential fix for the errors not being picked up by pymisp from the response "errors" field 2017-02-22 09:03:47 +01:00
Adrien RAFFIN 03a16fefef feature: Add support for authkey in PyMISP operations 2017-02-21 14:29:44 +01:00
Richard van den Berg ef69016e4a Allow 'Your organisation only' distribution for attributes 2017-02-21 11:07:57 +01:00
Raphaël Vinot 3493b26bd0 Add method to set sightings from a string 2017-02-17 10:32:25 +01:00
Hannah Ward 9e59a81b4c
new: Added async method for search_index 2017-02-16 15:39:36 +00:00
Hannah Ward bb00201aaf
new: Added base async imports 2017-02-16 15:23:42 +00:00
Raphaël Vinot ff21263405 Update bundled-in describeTypes.json 2017-02-10 16:57:52 +01:00
Raphaël Vinot 9a7961e0a3 Version dump 2017-02-09 16:41:01 +01:00
Raphaël Vinot 1556c901ef Add support for {attach,remove}TagToObject
Fix #47
2017-02-09 11:59:38 +01:00
Raphaël Vinot 6b5f347423 Merge branch 'master' of github.com:MISP/PyMISP 2017-02-07 14:03:22 +01:00
Raphaël Vinot b66e1258a7 Fix error message 2017-02-07 14:03:10 +01:00
Hannah Ward 98a008e67a
fix: Don't auto-publish events 2017-02-06 11:06:37 +00:00
Christophe Vandeplas b4d81e0d09 get_all_attributes_txt - support the additional flags 2017-02-03 12:22:54 +01:00
Raphaël Vinot d5e28abc70 Version bump 2017-01-31 10:24:29 +01:00
Raphaël Vinot 14ccf16d73 Fix regression.
Fix #46
2017-01-28 11:24:04 +01:00
Raphaël Vinot 6ecb713667 Version bump 2017-01-27 13:22:47 +01:00
Raphaël Vinot 2b9663cdf4 Bug fixes
* Improve version checking
* Fix attribute update
2017-01-27 11:58:00 +01:00
Raphaël Vinot 48e1211ed8 Allow to add a tag to a MISPEvent and MISPAttribute 2017-01-26 14:36:01 +01:00
Hannah Ward d260dc5ea5 Merge branch 'master' of github.com:MISP/PyMISP 2017-01-26 13:19:52 +00:00
Hannah Ward d355fc7e44
chg: Allow for old-style tag add 2017-01-26 13:19:32 +00:00
Raphaël Vinot 9ddbf0523d Fix python3 support. 2017-01-25 17:16:37 +01:00
Raphaël Vinot a81f6b5c15 Bump version 2017-01-25 17:02:29 +01:00
Raphaël Vinot 5cfbb679db Add orgs managment 2017-01-25 15:09:12 +01:00
Raphaël Vinot 6bee446fa0 Fix last commit 2017-01-24 09:46:31 +01:00
Raphaël Vinot 8e67303abc Merge branch 'master' of github.com:MISP/PyMISP 2017-01-24 09:42:52 +01:00
Raphaël Vinot 0f1553ef33 Refactoring search method 2017-01-24 09:41:30 +01:00
Koen Van Impe 38c0d2343d Wrong use of API for dateuntil
PyMISP uses “dateto” whereas the API expects “dateuntil”.
https://github.com/MISP/misp-book/tree/master/automation
2017-01-24 08:46:14 +01:00
Raphaël Vinot 296d0501db Revert "Add options to restsearch calls."
This reverts commit 3241e415b5.
2017-01-24 07:56:54 +01:00
Raphaël Vinot 3241e415b5 Add options to restsearch calls.
Related to:
8c63e6f3d5
2017-01-24 07:15:38 +01:00
Raphaël Vinot 9cc3c6e57d Merge branch 'master' of github.com:MISP/PyMISP 2017-01-19 19:07:36 -05:00
Raphaël Vinot b26c021b0e Fix typo 2017-01-19 19:07:24 -05:00
Christophe Vandeplas 351157b8f1 Minor documentation clarification 2017-01-18 09:33:35 +01:00
Raphaël Vinot f593ce69f8 Fix last commit 2017-01-17 19:03:38 -05:00
Raphaël Vinot 2bcc4163ad Add support for attribute level tagging 2017-01-17 18:20:24 -05:00
Raphaël Vinot 619538ced7 Fix travis 2017-01-16 15:41:17 -05:00
Raphaël Vinot 351ad53c97 Merge branch 'master' of git://github.com/cgi1/PyMISP into cgi1-master 2017-01-16 14:43:07 -05:00
Raphaël Vinot 748136f3f1 Allow to update an event by UUID, syntax fixes. 2017-01-16 14:41:32 -05:00
Hannah Ward 7c8cde0afd
chg: Updated api.py docstrings to comply with PEP257 2017-01-16 14:27:44 +00:00
Hannah Ward 78cef06963
new: Added ability to disable correlation on attributes 2017-01-16 09:52:35 +00:00
Hannah Ward cfb8572ab1
new: Added ability to add attachments to events 2017-01-13 13:15:53 +00:00
Raphaël Vinot 56a18275bb Fix get sharing groups
Fix #79
2017-01-11 14:29:20 -05:00
cgi 60c02cb5e9 + separate function change_sharing_group using update_event 2017-01-09 16:19:20 +01:00
Raphaël Vinot 3d2d41525f Merge branch 'master' of github.com:MISP/PyMISP 2017-01-06 16:25:36 -05:00
Raphaël Vinot b2752bd8d5 Load RelatedEvent as MISPEvent.
Fix #76
2017-01-06 16:24:39 -05:00
Hannah Ward 59aa5adfee
Merge branch 'master' of https://github.com/truckydev/PyMISP 2017-01-04 16:21:51 +00:00
Tristan METAYER 5478778a38 idem 2017-01-04 17:04:36 +01:00
Tristan METAYER 879f60f368 refere to FloatingGhost comment 2017-01-04 17:02:13 +01:00
Tristan METAYER bfb9fd5db3 Add uuid serch with pymisp 2017-01-04 11:23:18 +01:00
Raphaël Vinot 585ca9cd08 Allow to mark an attribute as deleted in a MISPEvent
Related to #33
2017-01-02 16:53:23 +01:00
Georges Bossert 0511bd4486 Fix typo in comments of 'search_index' method definition 2016-12-27 17:02:20 +01:00
Raphaël Vinot 4f230c9299 Add warning of PyMISP and MISP version don't match. 2016-12-14 15:42:43 +01:00
Raphaël Vinot d4489d9c34 Fix sharing group distribution level.
Fix https://github.com/MISP/MISP/issues/1761
2016-12-14 15:17:33 +01:00
Raphaël Vinot 0f2206a700 Add basic support for Galaxy 2016-12-09 17:35:50 +01:00
Raphaël Vinot a2ec3bf551 Bump to v2.4.56 2016-12-09 17:21:59 +01:00
Raphaël Vinot 83c9ce9218 Allow to change the to_ids flag of an attribute 2016-12-09 11:42:07 +01:00
Raphaël Vinot 81faa507f4 Add support for data field (malware-sample) 2016-12-07 19:27:12 +01:00
Raphaël Vinot 5bc4db789b Fix typo in add_mutex 2016-12-07 10:54:22 +01:00
Raphaël Vinot f96c1b5748 Reorganize json dumps 2016-12-03 18:37:13 +01:00
Raphaël Vinot d75d02b5eb Fix merge conflict, make pep8 happy. 2016-12-03 17:29:41 +01:00
morallo c40eaf935f Fixed synthax error 2016-12-02 17:51:43 +01:00
morallo a6a851f38d Solved warnings in tests when run under Python3 2016-12-02 16:53:45 +01:00
Nicolas Bareil 59b7d19970 map() is a generator in Python3 2016-12-01 14:26:59 +01:00
Nicolas Bareil 802fc0f20e python3 does not like lambda (x,y) syntax 2016-12-01 11:01:46 +01:00
Nicolas Bareil fff3a66d09 Unit-tests 2016-12-01 10:49:12 +01:00
Nicolas Bareil e44e33fe90 capitalizeformat() does not exist on Python2 and fix category variables 2016-12-01 10:48:33 +01:00
Raphaël Vinot f956fd526e Fix neo4j 2016-11-30 17:14:55 +01:00
Nicolas Bareil d3d7bccf0b Factorize all add_* in favor of add_named_attribute()
Not tested...
2016-11-30 13:17:15 +01:00
Raphaël Vinot 7b5b45146c Remove crazy replace 2016-11-24 10:50:46 +01:00
Raphaël Vinot e1b5000a16 Merge branch 'master' of github.com:CIRCL/PyMISP 2016-11-24 10:42:46 +01:00
Raphaël Vinot c90c73c9af Improve debug mode 2016-11-24 10:41:47 +01:00
Hannah Ward f7b228ac56
Use misp_stix_converter.converters.convert's load_stix method 2016-11-21 11:57:49 +00:00
Raphaël Vinot f62cf9f3d9 More granularity in the verification 2016-11-21 10:44:03 +01:00
Raphaël Vinot d2e4e73abb Allow to pass a passphrase as parameter for signing. 2016-11-18 18:01:57 +01:00
Raphaël Vinot b8a391d263 Avoid error if pyme3 isn't installed 2016-11-17 17:30:23 +01:00
Raphaël Vinot 419897aba0 Bump recommended python3 version 2016-11-17 17:29:54 +01:00
Raphaël Vinot 35a4dd52bc Add signing support for MISP events 2016-11-17 17:07:29 +01:00
Raphaël Vinot fba21ac051 Version bump 2016-11-16 16:39:55 +01:00
Raphaël Vinot 0c2a1f0d50 Update missing dependency exception 2016-11-16 16:35:06 +01:00
Raphaël Vinot 5632959f02 Set user parameters in a function 2016-11-15 10:59:29 +01:00
Raphaël Vinot 6885779be5 Allow to set org_id and orgc_id when creating a new MISPEvent
Squashed commit of the following:

commit 8a5dfda8a728d8722dfba890729066948e744e44
Merge: 477f81d 332fc05
Author: Raphaël Vinot <raphael@vinot.info>
Date:   Tue Nov 15 09:52:26 2016 +0100

    Merge https://github.com/garanews/PyMISP into garanews-master

commit 332fc0508d3f5dc32cf962bd2cad1d800b6b4b02
Author: garanews <puntogtg@tiscali.it>
Date:   Mon Nov 14 15:29:04 2016 +0100

    Delete api_old.py

commit 7fb955fa2fba964ae7120f4cf56cf85e203efe96
Author: garanews <puntogtg@tiscali.it>
Date:   Mon Nov 14 14:05:22 2016 +0100

    Create api.py

commit 7f6f45d9ce8ec4e948c5b2513b9bc59296985e09
Author: garanews <puntogtg@tiscali.it>
Date:   Mon Nov 14 14:05:06 2016 +0100

    Rename api.py to api_old.py

commit 63c325816c2bda646f462a322eb3063788ab91a4
Author: garanews <puntogtg@tiscali.it>
Date:   Mon Nov 14 11:48:17 2016 +0100

    Add files via upload

commit edf0cd1d90e89c30a4d3ef756d6bc6501de3885f
Author: garanews <puntogtg@tiscali.it>
Date:   Wed Nov 2 15:31:42 2016 +0100

    Add files via upload
2016-11-15 10:21:49 +01:00
Raphaël Vinot 477f81d3ab Fix openioc loader, update mapping 2016-11-10 11:41:13 +01:00
Déborah Servili 3cadc1a78d Improvements in the user api 2016-11-04 12:00:42 +01:00
Déborah Servili a11e26f80b Improvements in the user api 2016-11-04 11:58:21 +01:00
Raphaël Vinot 75ebedae5c Merge pull request #68 from MISP/tooling
[WIP] Tooling
2016-11-03 16:04:28 -04:00
Raphaël Vinot 9f0737c34a Add some mapping to openioc, add python version in the user agent 2016-11-03 16:02:09 -04:00
Déborah Servili dbba8ed0f9 add user management and examples 2016-11-03 11:41:37 +01:00
Déborah Servili 0b462404de add user management and examples 2016-11-03 11:23:48 +01:00
Raphaël Vinot 6c5289d495 Initial version of the OpenIOC loader 2016-10-29 15:27:48 -04:00
Raphaël Vinot 81e3ce37af Fix forgotten import 2016-10-27 17:04:23 -04:00
Raphaël Vinot 857cd40ea2 Update import 2016-10-27 16:29:56 -04:00
Raphaël Vinot ac2e801d97 Add helper tool to load STIX objects. 2016-10-27 16:25:17 -04:00
Raphaël Vinot d48f248176 Fix Python2 - Python3 support 2016-10-27 15:58:58 -04:00
Raphaël Vinot 2907fd18d7 Cleanup neo4j support 2016-10-27 15:58:08 -04:00
Raphaël Vinot abd836babb Add simple script to push MISP events into Neo4j 2016-10-25 17:28:55 -04:00
Raphaël Vinot 2c2bfe2354 Properly warn if the user is using python2 2016-10-25 11:36:49 -04:00
Raphaël Vinot 5ccb4db3d3 Allow to load a MISP event without attributes 2016-10-25 11:33:51 -04:00
Raphaël Vinot c8aeab7823 Bump to v2.4.53 2016-10-21 15:42:38 +02:00
Raphaël Vinot f8f117f1a4 Cleanup 2016-10-21 13:42:22 +02:00
Raphaël Vinot aec6a2bbf2 Merge branch 'master' of github.com:CIRCL/PyMISP into next 2016-10-20 14:33:27 +02:00
Tom ec508191ca Including Network-Other option for API 2016-10-20 09:49:06 +01:00
Raphaël Vinot 0a63285efb Fix Python2 support 2016-10-19 19:00:09 +02:00
Raphaël Vinot 49433cdc3a Print a warning in case python2 is used. 2016-10-19 18:52:49 +02:00
Raphaël Vinot 3455567d45 Fix schemas 2016-10-19 18:29:20 +02:00
Déborah Servili 0d0ca1e9b5 Update comment 2016-10-13 13:43:57 +02:00
Déborah Servili 22956fbd81 add metadata flag to search 2016-10-13 11:48:17 +02:00
Déborah Servili 9cc55341f0 fix date formatting in mispevent.py + some PEP8 cleaning 2016-10-12 15:40:49 +02:00
Raphaël Vinot ed2be78f4e Avoid validation issue if attribute_count is none 2016-10-11 17:45:38 +02:00
Déborah Servili 3df35826c5 fix flatten 2016-10-11 11:26:57 +02:00
Raphaël Vinot 268598fe23 Add forgotten variable 2016-10-11 11:22:31 +02:00
Raphaël Vinot 78919272ab Use sane_defaults from describeTypes.json if unable to fetch it from the instance. 2016-10-10 12:24:17 +02:00
Raphaël Vinot 8817674dd0 Do not dump an empty list of attrbutes. 2016-10-10 12:23:03 +02:00
Raphaël Vinot b6072f7145 Raise exception if the dest instance is < 2.4.52, set User-Agent. 2016-10-07 16:50:57 +02:00
Raphaël Vinot e91ad63ccf More logical output for _prepare_full_event 2016-10-05 11:43:33 +02:00
Raphaël Vinot 8a931a89f3 Fix upload function 2016-10-05 11:07:40 +02:00
Raphaël Vinot 5ee23d46c0 Make sure all integers are string in the dumped json 2016-09-30 16:06:41 +02:00
Raphaël Vinot dcd76ec5c4 Fix python 2.7 support, add missing test file 2016-09-28 18:50:05 +02:00
Raphaël Vinot 6482a21834 More cleanup 2016-09-28 18:20:37 +02:00
Raphaël Vinot e035922949 Getting closed to a full support of a misp event as a Python Object 2016-09-27 19:47:22 +02:00
Raphaël Vinot cf257493f7 First batch of changes, will be squashed 2016-09-26 00:26:09 +02:00
Hannah Ward f6cf9d9150
Fixed search_index 2016-09-13 13:03:22 +01:00
Raphaël Vinot aef6bbc32d Version bump 2016-09-12 13:09:26 +02:00
Raphaël Vinot bf5793992b Fix examples after removal of MISP XML support 2016-09-12 12:53:58 +02:00
Raphaël Vinot 8059ead9cf Bump to 2.4.51 2016-08-29 11:05:18 +02:00
Raphaël Vinot cd25559c94 Fix flattening, fix python2.7 2016-08-27 18:13:15 +02:00
Raphaël Vinot aaaab590f5 Fix error flattening 2016-08-26 18:22:41 +02:00
Raphaël Vinot 77e3ad0016 Update rendering doc 2016-08-26 14:19:19 +02:00
Raphaël Vinot 32bc8782f0 Add doc 2016-08-26 12:00:13 +02:00
Raphaël Vinot 0b0905d0e7 Update documentation for client side certificate 2016-08-26 09:24:02 +02:00
Richard van den Berg a1a524c2c5 Add ssl client certificate support 2016-08-26 09:11:01 +02:00
Raphaël Vinot cdc77de598 Add some more tests 2016-08-18 13:18:58 +02:00
Raphaël Vinot cdcb1cca5e Update testing 2016-08-18 00:23:49 +02:00
Raphaël Vinot 709770e367 Version bump 2016-08-17 14:51:35 +02:00
Jurriaan Bremer 1ff08c7d73 provide sane defaults for upload-sample/samplelist
Most of the arguments are unused when a proper event ID has been
provided, hence default them to standard values.
2016-08-16 18:35:35 +02:00
Jurriaan Bremer 353d04eab3 magic value enumerations 2016-08-16 16:51:35 +02:00
Jurriaan Bremer f23a7c3357 allow multiple attributes to be sent off at once
Slightly worked out version of the suggestion by doomedraven in #42.
2016-08-16 11:44:08 +02:00
Thomas King 8ada05f310 Fixed double status code check on helpers and other functions 2016-08-11 19:30:31 +02:00
Raphaël Vinot f19520d5ac Proper support of functions returning plain text instead of json 2016-08-11 17:50:47 +02:00
Raphaël Vinot ab09c0a1dc Fix calls to __prepare_session
Fix #58
2016-08-11 17:45:32 +02:00
Raphaël Vinot 2a0d6566ee change: remove XML output, all functions return a Python dictionary. 2016-08-09 13:58:54 +02:00
Richard van den Berg af44760967 Set default distribution for attributes to inherit 2016-08-09 13:31:44 +02:00
Raphaël Vinot 86758cce19 Properly handle errors while fetching the types.
Fix #53
2016-08-05 11:13:26 +02:00
Raphaël Vinot cb25177a46 Add option to search function to only return attributes instead of events 2016-08-04 13:21:28 +02:00
Raphaël Vinot 5937ef9e9b Version bump 2016-08-02 15:17:42 +02:00
Raphaël Vinot fd5c22d8d9 Merge branch 'master' of github.com:CIRCL/PyMISP 2016-07-28 09:50:57 +02:00
Raphaël Vinot b8205f11a8 Fix PEP8 2016-07-28 09:50:46 +02:00
Raphaël Vinot f45490b02e Add support for proxies in the library.
Fix #48
2016-07-28 09:49:40 +02:00
Kenneth Adam Miller 90b772d938 Caught exception on python3.4 where base64encode returns bytes and not str, and bytes are not json encodable. This caused a failure in upload_sample 2016-07-27 07:30:46 -04:00
Jessy Campos d31ec7a73c Add a method to add a textual detection name under the 'Antivirus detection' category 2016-07-26 13:13:29 -04:00
Nils ca5a4d0960 Fixes: expected bytes, got <class 'str'> in download_samples() 2016-07-21 13:43:04 +02:00
Hannah Ward 414ddaec01
Added STIX retrieval
- misp.get_stix(event_id=ID, with_attachment=True/False,
			from_date=YYYY-MM-DD, to_date=YYYY-MM-DD,
			tags=["tag1", "tag2"]
	                )
2016-07-14 12:55:37 +01:00
Raphaël Vinot c97651e6ac Version bump 2016-07-11 18:54:17 +02:00
Raphaël Vinot 51a9725583 Add remove tag method 2016-07-11 17:57:16 +02:00
Déborah Servili 29476b6eba Add examples "create_dummy_event" and "create_massive_dummy_events" 2016-07-01 10:33:44 +02:00
Antonio S 101a274447 Added function to AV detection link 2016-06-28 13:12:37 +02:00
Antonio S b7c7afa4f6 Added add_domain_ip attribute function 2016-06-27 16:53:13 +02:00
Raphaël Vinot a42be22f78 Make pep8 happy 2016-06-15 11:44:08 +09:00
Raphaël Vinot fe8415dbc7 Fix check MISP latest version 2016-06-15 09:44:36 +09:00
Raphaël Vinot 03c2a053f4 Tag version 2.4.48 2016-06-09 14:50:44 +02:00
Alexandre Dulaunoy 11c401bb6a Merge pull request #19 from Delta-Sierra/master
add function get_tags_statistics
2016-05-23 15:20:09 +02:00
Déborah Servili d781b4690f add function get_tags_statistics 2016-05-23 15:16:31 +02:00
Alexandre Dulaunoy 70808a46ca File indention fixed 2016-05-19 14:30:43 +02:00
Alexandre Dulaunoy 6fc403f7c8 Merge pull request #18 from Delta-Sierra/master
add function get_sharing_groups
2016-05-19 14:29:45 +02:00
Déborah Servili 5108d78f8d add function get_sharing_groups 2016-05-19 14:09:01 +02:00
KevTheHermit 12fa199202 Add Attribute by named category and type 2016-05-05 10:05:59 +01:00
Alexandre Dulaunoy f9ce3999e9 Merge pull request #17 from Delta-Sierra/master
Add function for sighting using attribute id, uuid or a json file
2016-04-30 14:52:09 +02:00
Déborah Servili 3cd9ede99f Add function for sighting using attribute id, uuid or a json file 2016-04-29 16:35:27 +02:00
Alexandre Dulaunoy ca382960ef Debug print removed 2016-04-28 14:45:02 +02:00
Déborah Servili 5c23d12f2c add function get_attributes_statistics 2016-04-28 13:29:54 +02:00
Raphaël Vinot ea952a9588 Add 'add_yara' to upload yara rules, increase flexibility of config
fix #38
2016-04-20 10:17:31 +02:00
Raphaël Vinot 46396202f5 Update version to v2.4.36 2016-04-15 16:29:47 +02:00
Déborah Servili 089b0a72b0 add comment field in upload_sample 2016-04-15 15:52:50 +02:00
Déborah Servili b94423781c add function add filename 2016-04-15 13:47:13 +02:00
Déborah Servili 369922436e type-category association checking automated 2016-04-14 16:24:37 +02:00
Déborah Servili 25bc301789 removing some unnecessary checks 2016-04-14 14:19:08 +02:00
Déborah Servili c31a1c9799 Merge https://github.com/MISP/PyMISP 2016-04-14 13:29:13 +02:00
Déborah Servili c269913ad3 type-category association checking automated 2016-04-14 10:47:13 +02:00
Déborah Servili d493ff76ba type-category association checking automated 2016-04-14 10:36:32 +02:00
Nick Driver 9e92072f88 Add SSDEEP and FILENAME|SSDEEP support 2016-04-14 10:35:03 +02:00
Nick Driver 887a2b49b1 Add internal reference attributes 2016-04-14 10:35:03 +02:00
Iglocska 7f00da0788 Capitalisation issues 2016-04-06 11:49:19 +02:00
Raphaël Vinot 7be215a732 Ann missing categories in the authorized ones. 2016-04-05 02:03:30 +02:00
Raphaël Vinot 14f05fc9af Revert "Add upload_attachment"
This reverts commit 6db19ace9e.
2016-04-04 18:48:27 +02:00
Raphaël Vinot 9920d7686d Revert "Use correct function to upload an attachment"
This reverts commit 1b7877dd06.
2016-04-04 18:45:45 +02:00
Raphaël Vinot cb09a19e24 Make PEP8 happy 2016-04-04 18:34:08 +02:00
Raphaël Vinot 1b7877dd06 Use correct function to upload an attachment
Fix #33
2016-04-04 18:26:05 +02:00
= 2c134f6154 Designed in same style as search, all attributes can be used 2016-03-31 12:33:04 +01:00
Thomas King c88096ab5d Merge remote-tracking branch 'upstream/master'
Merging new pymisp changes
2016-03-31 09:13:04 +01:00
Raphaël Vinot f54e92ab81 Fix pep8 2016-03-24 14:36:30 +01:00
Tristan METAYER 6db19ace9e Add upload_attachment 2016-03-23 14:40:44 +01:00
Raphaël Vinot 6656e63dcc Update version to 2.3 2016-03-21 14:59:39 +01:00
Raphaël Vinot a0c91e5c37 Make pep8 happy 2016-03-21 14:55:41 +01:00
Thomas King 9e8f81aafe Python 2/3 compatible, urllib module 2016-03-18 08:47:30 +00:00
Thomas King c73becee36 Added in searchable indexes, only brings back index and count etc, not results within the index 2016-03-18 08:38:04 +00:00
Alexandre Dulaunoy bc655cedbf Merge pull request #7 from sebdraven/master
add method change_threat_level
2016-03-15 18:36:30 +01:00
Sébastien Larinier ba14cf1aaa add method change_threat_level 2016-03-15 17:17:04 +01:00
Thomas King 3c90e25ebd Add threat actor through API, Create new tag 2016-03-14 11:17:53 +00:00
Sébastien Larinier 39c06a7d24 add add_tag method to an event and value 5 to distribution attribute 2016-03-11 16:53:31 +01:00
Sébastien Larinier a67a90d1d3 add method to export txt all attributes by type 2016-03-09 18:37:27 +01:00
Alexandre Dulaunoy 9a241ec547 Remove a small bug introduced by previous commit 2016-03-01 16:20:10 +01:00
Iglocska be242152e7 Script for the upcoming feed generator
- also some minor modifications to the get_index api
2016-03-01 15:32:58 +01:00
Raphaël Vinot f968f43bd9 Initial Tags API 2015-12-21 18:58:08 +01:00
Raphaël Vinot a7fc1ceb20 Normalize error messages 2015-12-19 18:18:12 +01:00
Raphaël Vinot a334055749 Add debug option 2015-11-25 09:51:22 +01:00
Raphaël Vinot d1db9a74ee Add add_ipsrc 2015-11-05 09:36:35 +01:00
Raphaël Vinot 588a1abc00 Add basic support for the proposal API 2015-10-30 17:23:25 +01:00
grolinet eadc7ec1b5 Whitespace cleaned 2015-10-06 16:57:28 +02:00
grolinet c9fd4c11cb Helper methods added 2015-10-06 16:52:58 +02:00
unknown e364c3aed7 missing types added 2015-09-30 14:46:25 +02:00
unknown 0256a487b6 missing types added 2015-09-30 14:45:15 +02:00
unknown 17316e349e missing types added 2015-09-30 14:37:18 +02:00
Raphaël Vinot cc8400a9df Improve error handling 2015-09-23 18:47:47 +02:00
Raphaël Vinot 81fa4e5bdd Add test cases (initial) 2015-09-22 15:25:47 +02:00
Raphaël Vinot b4dc6e90b1 Fix typo in categories names 2015-09-22 11:48:23 +02:00
Raphaël Vinot 69f19a8616 Check the MISP instance to query is valid.
And return a json object from upload_sample.
2015-09-21 14:40:06 +02:00
Raphaël Vinot 35423ebf2e Force json if nothing else is supported. 2015-09-21 11:52:26 +02:00
Raphaël Vinot f4bf57cc46 Better error handling of no URL/Key are passed 2015-09-18 17:48:10 +02:00
Raphaël Vinot 11b3470167 Add support for downloading unzipped samples. 2015-09-18 14:38:52 +02:00
Raphaël Vinot a7c3d8869c Add version-related methods 2015-09-18 12:03:56 +02:00
Raphaël Vinot d735e6a3d3 Add methods to query the version of MISP (master and local) 2015-09-17 13:51:31 +02:00
Raphaël Vinot 5fea22600e Add publish method 2015-09-17 00:51:45 +02:00
Raphaël Vinot f731b88fde Try to convert event ID to integer if not None. 2015-09-13 00:31:27 +02:00
Raphaël Vinot c133713d33 Fix bug in download sample function.
Thanks to @kevthehermit
2015-09-12 23:08:06 +02:00
Raphaël Vinot 22e4d58a50 Timestamp not needed to update an event.
Fix #18
2015-09-08 15:25:26 +02:00
Raphaël Vinot 249407c32f Restore python3 support 2015-09-02 13:56:08 +02:00
Raphaël Vinot f50f4acfc0 Cleanup + add helpers for network attributes. 2015-09-02 11:50:15 +02:00
Raphaël Vinot 08e1c40987 Add helpers to update events with specific attributes. 2015-09-01 18:46:10 +02:00
Raphaël Vinot 0d112bea47 Reorganise 2015-09-01 10:31:22 +02:00
Raphaël Vinot c7b03640fb Multiple updates, cleanup
* Remove attribute (Fix #4)
* Deprecate pure XML API
* Cleanups and fixes in the upload file functionality
2015-08-28 17:07:30 +02:00
Raphaël Vinot e4d96bd198 Fix download of samples with the new archive format. 2015-08-24 12:05:49 +02:00
Raphaël Vinot 218ffcd915 Add Yara rules download support (by event) 2015-08-19 10:43:03 +02:00
Alexandre Dulaunoy c456538528 events id are integers not strings 2015-08-12 11:23:38 +00:00
Raphaël Vinot eacd82840b Fix bug introduced by using urljoin. 2015-08-10 11:58:20 +02:00
Raphaël Vinot bdd09bfe9a Add sample download 2015-08-07 17:24:03 +02:00
Raphaël Vinot 2ad737e7b7 Add search all 2015-08-06 17:43:12 +02:00
Raphaël Vinot 208091dc47 Fix last commit 2015-08-06 09:49:44 +02:00
Raphaël Vinot dd3591f87c Initial changes to increase flexibility for Viper module 2015-08-06 01:57:59 +02:00
Raphaël Vinot 97dfe2a4f6 Add last param to restSearch + example script 2015-08-05 17:20:59 +02:00
Raphaël Vinot effd8084a7 Cleanup of the upload API 2015-08-05 16:01:57 +02:00
Raphaël Vinot bef354ac44 Preliminary version of the file uploader 2015-08-04 16:24:55 +02:00
Alexandre Dulaunoy e0b781c033 Bug fix: get_index now works properly and return the events index
An bug was introduced and appending "{}" to the /index url which
gives a 404 on a MISP server.
2015-07-30 14:20:41 +00:00
Iglocska 507c5a5446 API made a bit more flexible with input data
- input for add_event() and update_event() can now be a JSON object, JSON string, XML
2015-07-30 15:53:34 +02:00
Iglocska c315ecaef6 Fix to an issue with using XML as input for add_event() and update_event()
- also a change to the copy_list.py script to account for the change
2015-07-30 15:26:05 +02:00
Debra Jules f28c9cdf07 Add 2 download functions of suricata rules events 2015-07-29 15:07:37 +02:00
didelphodon b08d3ab15d Update / Add need a JSON object as data
... furthermore content-type application was necessary otherwise MISP-REST API refuses to work as expected, at least with my installation.
2015-06-02 10:40:14 +02:00
Raphaël Vinot b6ff8746bc Make the code python3 friendly 2015-05-03 02:47:47 +02:00
Raphaël Vinot 59254c8246 Use JSON POST to do the search 2015-02-16 14:31:29 +01:00
Raphaël Vinot 3fc24e2e89 Small cleanup, update to 1.0.1 2014-05-02 17:10:22 +02:00
Raphaël Vinot f2c7bbe5c9 Add installer, proper copy script 2014-04-16 15:14:58 +02:00
Raphaël Vinot 24f2fab134 Add support for self-signed certificate.
Add comments
2014-04-16 14:09:56 +02:00
Raphaël Vinot 8f477cc802 add search by organisation 2014-04-15 16:40:49 +02:00
Raphaël Vinot 07b66ad05f add export-import of a list 2014-04-14 19:18:12 +02:00
Raphaël Vinot 93ddd4cf50 cleanup style 2014-04-14 10:55:20 +02:00
Raphaël Vinot ac482e8f00 support xml and json copy 2014-04-12 17:44:47 +02:00
Raphaël Vinot 0ff70618e8 Delete export_import.py 2014-04-12 17:04:05 +02:00
Raphaël Vinot b53dac7773 fix event_add, add example 2014-04-12 16:17:36 +02:00
Raphaël Vinot 483f7839c0 make the API a class 2014-04-11 18:45:52 +02:00
Raphaël Vinot acb6384bfb json export is not supported everywhere 2014-03-28 18:04:28 +01:00
Raphaël Vinot a920333544 some testing 2014-03-20 11:10:52 +01:00
Raphaël Vinot b27bb44e61 initial commit 2014-03-19 19:10:36 +01:00