|
1 | 1 | # TAXII2Sharp.Client
|
2 |
| -TAXII 2 C# Client Library |
| 2 | + |
| 3 | +TAXII2Sharp.Client is a C# .NET Standard implementation of the TAXII2 specifications for retrieving STIX structured data from a TAXII Endpoint. |
| 4 | + |
| 5 | +For more information on the TAXII Specifications, please see the References section below. |
| 6 | +For more information on the STIX specifications, please see the References section below. |
| 7 | + |
| 8 | + |
| 9 | +## Usage |
| 10 | + |
| 11 | +```C# |
| 12 | +using System; |
| 13 | +using System.Collections.Generic; |
| 14 | +// Please note that the client version to be imported is dependent on the TAXII Standard version run by the server |
| 15 | +using TAXIISharp2.Client.V20; |
| 16 | + |
| 17 | +... |
| 18 | + |
| 19 | +// Create a server |
| 20 | +Server endpoint = new Server("https://somesite.org/taxii"); |
| 21 | + |
| 22 | +// Get a list of the APIRoot endpoints provided by that server |
| 23 | +List<APIRoots> APIRoots = endpoint.GetAPIRoots(); |
| 24 | + |
| 25 | +// Iterate over the APIRoot objects |
| 26 | +foreach (APIRoot root in APIRoots) |
| 27 | +{ |
| 28 | + // Iterate over the Collection hosted at that APIRoot |
| 29 | + foreach (Collection collection in root.Collections) |
| 30 | + { |
| 31 | + // Get the STIX objects that the collection contains |
| 32 | + var Objects = collection.GetObjects(); |
| 33 | + Console.WriteLine("Total objects in collection: {0}", Objects.Objects.Length); |
| 34 | + } |
| 35 | +} |
| 36 | +``` |
| 37 | +For additional information, please see the example included in the project |
| 38 | + |
| 39 | +## Contributing |
| 40 | +Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change. |
| 41 | + |
| 42 | + |
| 43 | +## References |
| 44 | +[TAXII 2.0 Specification](https://docs.oasis-open.org/cti/taxii/v2.0/taxii-v2.0.pdf) |
| 45 | +[TAXII 2.1 Specification](https://docs.oasis-open.org/cti/taxii/v2.1/taxii-v2.1.pdf) |
| 46 | +[STIX Specification](https://www.oasis-open.org/committees/download.php/58538/STIX2.0-Draft1-Core.pdf) |
| 47 | + |
| 48 | +## License |
| 49 | +[GNU Lesser General Public License v2.1](https://choosealicense.com/licenses/lgpl-3.0/) |
0 commit comments