-
Notifications
You must be signed in to change notification settings - Fork 1
/
README.mustache
124 lines (87 loc) · 4.52 KB
/
README.mustache
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
# Crimson Falcon - The CrowdStrike Falcon SDK for Ruby
[![Gem Version](https://badge.fury.io/rb/crimson-falcon.svg)](https://badge.fury.io/rb/crimson-falcon)
Welcome to Crimson Falcon, the Ruby SDK for the CrowdStrike Falcon Platform. This is where the power of the CrowdStrike Falcon Platform meets the elegance and simplicity of Ruby.
"Why Ruby?" you might ask.
Well, Ruby is a dynamic, open source programming language with a focus on simplicity and productivity. It has an elegant syntax that is natural to read and easy to write. It's unique balance of simplicity, productivity, and just sheer fun, makes coding feel less like a task and more like a hobby. It's like your favorite pair of comfy shoes - familiar, comfortable, and always reliable. :wink:
That's what we aim to achieve with Crimson Falcon - a tool that brings together the robust capabilities of CrowdStrike Falcon with the friendly charm of Ruby.
Ready to bring some fun to your cybersecurity game with Ruby and Crimson Falcon? Let's jump right in!
- [Installation](#installation)
- [Getting Started](#getting-started)
- [Contribute to Crimson Falcon](#contribute-to-crimson-falcon)
- [Crimson Falcon API Docs](#crimson-falcon-api-docs)
## Installation
### From RubyGems (*This is the way*)
To install from RubyGems, use the following command:
```shell
gem install {{{gemName}}}
```
Add this to the Gemfile:
<!-- x-release-please-start-version -->
```ruby
gem '{{{gemName}}}', '~> {{{gemVersion}}}'
```
<!-- x-release-please-end -->
### From Source to Gem: Building the Ruby Code
To build the Ruby code into a gem:
```shell
gem build {{{gemName}}}.gemspec
```
Then install the gem locally:
<!-- x-release-please-start-version -->
```shell
gem install ./{{{gemName}}}-{{{gemVersion}}}.gem
```
<!-- x-release-please-end -->
Finally, add this to the Gemfile:
<!-- x-release-please-start-version -->
```ruby
gem '{{{gemName}}}', '~> {{{gemVersion}}}'
```
<!-- x-release-please-end -->
### Install from Git
If the Ruby gem is hosted at a git repository: <https://{{gitHost}}/{{gitUserId}}{{^gitUserId}}YOUR_GIT_USERNAME{{/gitUserId}}/{{gitRepoId}}{{^gitRepoId}}YOUR_GIT_REPO{{/gitRepoId}}>, then add the following in the Gemfile:
```ruby
# Example
gem 'crimson-falcon', :git => 'https://github.com/CrowdStrike/crimson-falcon.git'
```
## Getting Started
### Samples
We have a collection of sample code that demonstrates how to use the Crimson Falcon SDK.
These samples are a great way to get started with the SDK. You can find the samples in the [samples](./samples) directory.
### Take Flight
Eager to take flight? Follow the [installation](#installation) process, and then launch into the following code:
```ruby
# Load the gem
require '{{{gemName}}}'
# Setup authorization
Falcon.configure do |config|
config.client_id = ENV["FALCON_CLIENT_ID"]
config.client_secret = ENV["FALCON_CLIENT_SECRET"]
config.cloud = "us-2" # or "us-2", "eu-1", "us-gov1"
end
# Create a new API instance
api_instance = Falcon::SensorDownloadApi.new
begin
# Get CCID to use with sensor installers
result = api_instance.get_sensor_installers_ccidby_query
p result.resources
rescue Falcon::ApiError => e
puts "Error when calling SensorDownloadApi->get_sensor_installers_ccidby_query: #{e}"
end
```
Welcome aboard the Crimson Falcon! Fly high, code with grace.
## Contribute to Crimson Falcon
We are always excited to have contributions from the community! It's what makes open source truly powerful. If you are looking to help out, that's awesome and we thank you in advance.
To get started, please read our [Contributing Guide](./CONTRIBUTING.md) that explains the development process, the project structure, how to propose bugfixes and improvements, and how to build and test your changes to the project. It's a set of directions that will help establish a baseline of expectation for any contributions.
Please make sure you also follow our [Code of Conduct](./CODE_OF_CONDUCT.md). It outlines our expectations for participant behavior as well as the steps for reporting unacceptable behavior.
We appreciate your interest in our project and look forward to collaborating with you!
## Crimson Falcon API Docs
> :recycle: ***API Docs are automatically generated from the CrowdStrike API specification.*** :recycle:
---
{{#apiInfo}}{{#apis}}{{#operations}}{{#operation}}
**Class**: `{{moduleName}}::{{classname}}`
- **Operation**: [**{{operationId}}**]({{apiDocPath}}{{classname}}.md#{{operationId}})
- **{{httpMethod}}**: {{path}}
- **Description**: {{summary}}
---
{{/operation}}{{/operations}}{{/apis}}{{/apiInfo}}