Commit Graph

36 Commits (ebd28aca9d01dfb02f93f9d1421798b6e1f5ae2e)

Author SHA1 Message Date
Chris Lenk 3ca8cf820e Add STIXDomainObject and STIXRelationshipObject 2017-10-03 15:01:55 -04:00
Chris Lenk 2bdf83401a Add a shortcut for marking functions
So marking functions like `add_markings()` can be directly called as methods on
SDO/SRO classes. Note that they return new versions of the objects
because objects are immutable.
2017-10-03 10:28:58 -04:00
Chris Lenk 42962e6675 Improve markings tests
- Test markings functions with both dictionaries and our _STIXBase-derived
  classes as input.
- Slightly improve test coverage.
- Drop Python 2.6 support.
2017-09-01 16:41:16 -04:00
Emmanuelle Vargas-Gonzalez 23f36a9a69 Minor changes to custom object decorators. Add new marking decorator. 2017-08-28 14:30:53 -04:00
Greg Back 69eb09c32b Merge remote-tracking branch 'origin/master' into datastores 2017-08-21 22:40:07 +00:00
clenk d4edb8b0bc Validate patterns when creating Indicators 2017-08-18 14:22:57 -04:00
Emmanuelle Vargas-Gonzalez a18804a195 Add ordereddict dependency for 2.6 support. Import change in utils.py 2017-08-15 14:12:21 -04:00
Emmanuelle Vargas-Gonzalez cb5c4ad080 Merge pull request #42 from oasis-open/bundles Parse bundles correctly 2017-08-14 15:21:58 -04:00
Emmanuelle Vargas-Gonzalez add14c2490 Update CustomObject docstring, re-organize object properties. 2017-08-14 09:06:20 -04:00
clenk ee8013d782 Parse bundles correctly
This required refactoring parts of the library. Code in __init__.py
merged into bundle.py, which was renamed core.py. Code in other.py was
merged into common.py.

Fixes #40.
2017-08-11 16:18:20 -04:00
Emmanuelle Vargas-Gonzalez 8086447fce Change SDOs to OrderedDict approach. Removed COMMON_PROPERTIES. 2017-08-11 15:12:45 -04:00
clenk 5c5903179d Fix import sort order 2017-07-14 16:02:29 -04:00
clenk e1330692c8 Move ObservableProperty, ExtensionsProperty, and Observable parsing code
into observables.py to prevent circular imports and fix #23.
2017-07-14 15:10:12 -04:00
clenk fdbb6ff337 Add custom Cyber Observables 2017-06-14 09:36:35 -04:00
clenk d4e92dd813 Allow adding validation to custom object types
_Custom.__init__() is a solution to recursion errors arising from using
a decorator. See https://stackoverflow.com/q/14739809/1013457
2017-06-13 10:27:31 -04:00
clenk bcfb13f23c Add custom STIX Object types 2017-06-12 16:22:16 -04:00
Greg Back a913d9d5ad Merge pull request #14 from oasis-open/parse-cyber-observables
Parse cyber observables
2017-05-19 09:15:00 -05:00
clenk 958e60b01d Add 'labels' property to COMMON_PROPERTIES 2017-05-15 10:57:40 -04:00
clenk 67935d08fe Fix isort settings, rename Observable to clarify
it's an internal class
2017-05-09 18:03:46 -04:00
clenk 2c67b90638 Add Artifact type 2017-05-03 17:35:33 -04:00
clenk cd815bfe84 Fix import order, add flake8-import-order plugin
to Tox
2017-04-24 18:29:56 -04:00
clenk d06df8b9da Fix parsing errors
- Typos in Attack Pattern tests
- Put MarkingDefinition, ExternalReference, and KillChainPhase together
  in a file for objects that aren't SDOs or SROs
- Create utility function to return dictionary from string or
  file-like object
- Put off testing parsing Cyber Observable Objects until a later commit
2017-04-19 14:32:56 -04:00
clenk 05ccffc5bd Use correct Property classes for all STIX objects 2017-04-18 09:21:38 -04:00
clenk bc8bdccece Merge branch 'master' into parsing 2017-04-11 15:05:22 -04:00
clenk bab8d187c9 Rework kill chain phases 2017-04-07 17:34:06 -04:00
Richard Piazza 3c17c9259c Add Sighting object and data markings
- Update ReferenceProperty to allow specifying a particular object type
- Update ListProperty and add SelectorProperty
- Add description to Relationship
2017-04-07 16:07:17 -05:00
clenk 93b8076ae3 Use StringProperty and ListProperty in Malware objects,
fix bugs in those properties
2017-04-07 14:53:40 -04:00
Greg Back c1a59265ae Remove unnecessary TODO comments. 2017-03-21 20:24:32 -04:00
Greg Back 79554a6491 Convert remaining properties from dicts to classes 2017-03-21 20:24:32 -04:00
Greg Back 9bcf064213 Convert most old-style properties to Property classes 2017-03-21 20:06:09 -04:00
Greg Back 2645bf2c71 Convert 'type' to a new Property class. 2017-02-24 12:33:45 -06:00
Greg Back a264ca1e5e Convert ID properties to class style 2017-02-24 12:32:05 -06:00
Greg Back 805c15c397 Add tests for all SDOs 2017-02-24 11:56:55 -06:00
clenk 61d3652514 Add more SDO skeletons
- Campaign
- CourseOfAction
- Identity
- ObservedData
- Report
- ThreatActor
- Vulnerability
2017-02-23 10:12:38 -05:00
clenk 375b915da4 Add KillChainPhase, AttackPattern, IntrusionSet, Tool 2017-02-22 10:06:35 -05:00
Greg Back 96e880b49b Refactor library into separate files. 2017-02-10 15:35:02 -06:00