emasser 3.10.0 → 3.12.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/codeql-analysis.yml +4 -4
- data/.github/workflows/gh-pages.yml +1 -1
- data/.github/workflows/push-to-docker-mail.yml +5 -5
- data/.github/workflows/push-to-docker.yml +4 -4
- data/.github/workflows/release.yml +1 -1
- data/.github/workflows/rubocop.yml +1 -1
- data/.github/workflows/test-cli.yml +1 -1
- data/CHANGELOG.md +52 -2
- data/Gemfile.lock +7 -7
- data/README.md +17 -16
- data/docs/features.md +397 -222
- data/emasser.gemspec +1 -1
- data/lib/emasser/configuration.rb +4 -4
- data/lib/emasser/constants.rb +0 -4
- data/lib/emasser/delete.rb +78 -16
- data/lib/emasser/get.rb +416 -209
- data/lib/emasser/help/artifacts_del_mapper.md +2 -2
- data/lib/emasser/help/milestone_del_mapper.md +1 -1
- data/lib/emasser/help/poam_del_mapper.md +1 -1
- data/lib/emasser/output_converters.rb +14 -4
- data/lib/emasser/version.rb +1 -1
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 8b90b832b57672567d46686a6c1e490a2f61ea08fae87709b2db7e5ee7f789bb
|
4
|
+
data.tar.gz: 312b2c6c4a56d40c1ac5fdefae3ee36f745af244a5f0e4839cf6b40796b53b14
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 50272e2670c607779a0365c352b7def9cbbb9b2dacab88811edbf0bd198a0b5e80e1c1111b5aebb13e5dd6e48cbf28a4a2304c86145841dbbd08325bdeafcaa2
|
7
|
+
data.tar.gz: 7853329f250ab9aa7af9420d6d706aaf8d6fa0caf3471c3da179370552a00ba33ca161e0ea1d5c406b9d8e0b815bfe0fcec3b42d99bd5fe9211b3567db08b461
|
@@ -38,11 +38,11 @@ jobs:
|
|
38
38
|
|
39
39
|
steps:
|
40
40
|
- name: Checkout repository
|
41
|
-
uses: actions/checkout@
|
41
|
+
uses: actions/checkout@v4
|
42
42
|
|
43
43
|
# Initializes the CodeQL tools for scanning.
|
44
44
|
- name: Initialize CodeQL
|
45
|
-
uses: github/codeql-action/init@
|
45
|
+
uses: github/codeql-action/init@v2
|
46
46
|
with:
|
47
47
|
languages: ${{ matrix.language }}
|
48
48
|
# If you wish to specify custom queries, you can do so here or in a config file.
|
@@ -53,7 +53,7 @@ jobs:
|
|
53
53
|
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
|
54
54
|
# If this step fails, then you should remove it and run the build manually (see below)
|
55
55
|
- name: Autobuild
|
56
|
-
uses: github/codeql-action/autobuild@
|
56
|
+
uses: github/codeql-action/autobuild@v2
|
57
57
|
|
58
58
|
# ℹ️ Command-line programs to run using the OS shell.
|
59
59
|
# 📚 https://git.io/JvXDl
|
@@ -67,4 +67,4 @@ jobs:
|
|
67
67
|
# make release
|
68
68
|
|
69
69
|
- name: Perform CodeQL Analysis
|
70
|
-
uses: github/codeql-action/analyze@
|
70
|
+
uses: github/codeql-action/analyze@v2
|
@@ -10,17 +10,17 @@ jobs:
|
|
10
10
|
runs-on: ubuntu-latest
|
11
11
|
steps:
|
12
12
|
- name: Set up Docker Buildx
|
13
|
-
uses: docker/setup-buildx-action@
|
13
|
+
uses: docker/setup-buildx-action@v2
|
14
14
|
- name: Login to DockerHub
|
15
|
-
uses: docker/login-action@
|
15
|
+
uses: docker/login-action@v2
|
16
16
|
with:
|
17
17
|
username: ${{ secrets.DOCKERHUB_USERNAME }}
|
18
18
|
password: ${{ secrets.DOCKERHUB_TOKEN }}
|
19
|
-
- name: Checkout the
|
20
|
-
uses: actions/checkout@
|
19
|
+
- name: Checkout the eMASSer Repository
|
20
|
+
uses: actions/checkout@v4
|
21
21
|
- name: Build and push
|
22
22
|
id: docker_build
|
23
|
-
uses: docker/build-push-action@
|
23
|
+
uses: docker/build-push-action@v3
|
24
24
|
with:
|
25
25
|
context: .
|
26
26
|
file: Dockerfile
|
@@ -9,9 +9,9 @@ jobs:
|
|
9
9
|
runs-on: ubuntu-latest
|
10
10
|
steps:
|
11
11
|
- name: Set up Docker Buildx
|
12
|
-
uses: docker/setup-buildx-action@
|
12
|
+
uses: docker/setup-buildx-action@v2
|
13
13
|
- name: Login to DockerHub
|
14
|
-
uses: docker/login-action@
|
14
|
+
uses: docker/login-action@v2
|
15
15
|
with:
|
16
16
|
username: ${{ secrets.DOCKERHUB_USERNAME }}
|
17
17
|
password: ${{ secrets.DOCKERHUB_TOKEN }}
|
@@ -24,10 +24,10 @@ jobs:
|
|
24
24
|
replace-with: ''
|
25
25
|
flags: 'g'
|
26
26
|
- name: Checkout the emasser Repository
|
27
|
-
uses: actions/checkout@
|
27
|
+
uses: actions/checkout@v4
|
28
28
|
- name: Build and push
|
29
29
|
id: docker_build
|
30
|
-
uses: docker/build-push-action@
|
30
|
+
uses: docker/build-push-action@v3
|
31
31
|
with:
|
32
32
|
context: .
|
33
33
|
file: Dockerfile
|
data/CHANGELOG.md
CHANGED
@@ -4,9 +4,59 @@ All notable changes to this project will be documented in this file.
|
|
4
4
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
5
5
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
6
6
|
|
7
|
-
## [
|
8
|
-
|
7
|
+
## [3.12.0] Oct 11, 2023
|
8
|
+
### Changes
|
9
|
+
- Implemented eMASS API V3.12 specifications (to include previous updates)
|
10
|
+
|
11
|
+
## [3.10.0] Jun 27, 2023
|
12
|
+
### Changes
|
13
|
+
- Implemented eMASS API 3.10 specifications
|
9
14
|
|
15
|
+
## [3.4.1] Oct 7, 2022
|
16
|
+
### Changes
|
17
|
+
- Included the ability to register NPE credentials and obtain the Api key api-key
|
18
|
+
|
19
|
+
## [3.4.0] Sep 22, 2022
|
20
|
+
### Changes
|
21
|
+
- Implemented API specifications V3.4
|
22
|
+
- Changed release version to match API specificationa
|
23
|
+
|
24
|
+
## [1.0.6] Jun 17, 2022
|
25
|
+
### Changes
|
26
|
+
- addMultiplePackages
|
27
|
+
|
28
|
+
## [1.0.3] Jan 14, 2022
|
29
|
+
### Changes
|
30
|
+
- UpdateVersionTags
|
31
|
+
|
32
|
+
## [1.0.2] Jan 14, 2022
|
33
|
+
### Changes
|
34
|
+
- updateCLI_Help
|
35
|
+
|
36
|
+
## [1.0.1] Jan 3, 2022
|
37
|
+
### Changes
|
38
|
+
- Rename swagger_client to emass_client and publish it to rubygems.
|
39
|
+
|
40
|
+
## [1.0.0] - Dec 29, 2021
|
41
|
+
### Changes
|
42
|
+
- addReleaseWorkflow @georgedias (#26)
|
43
|
+
- create test-cli workflow @georgedias (#25)
|
44
|
+
- Add cli tests @georgedias (#24)
|
45
|
+
- Add the stoplight prism mock server as a server selection @georgedias (#23)
|
46
|
+
- Update eMASSRestOpenApi.yaml @georgedias (#22)
|
47
|
+
- ci(Mergify): configuration update @camdenmoors (#21)
|
48
|
+
- fix_gh_pages @georgedias (#18)
|
49
|
+
- Fixed the removal of jekyll thene when updating the gh_pages @georgedias (#17)
|
50
|
+
- Add workflow to update markdown files in gh-pages @georgedias (#15)
|
51
|
+
- Udates to the emasser features documentation @georgedias (#13)
|
52
|
+
- corrected controls post/put requests @georgedias (#9)
|
53
|
+
- Added eMASS contact information to the README @georgedias (#8)
|
54
|
+
- Update eMASSOpenAPI specification, add redoc and swagger documentation @rbclark (#6)
|
55
|
+
|
56
|
+
### Features
|
57
|
+
|
58
|
+
- Initial workflow configuration @georgedias (#10)
|
59
|
+
|
10
60
|
## [0.2.0] - 2020-12-14
|
11
61
|
### Added
|
12
62
|
- Scaffolding for the emasser project including such things as a Dockerfile, a .gitlab-ci.yml, some repository dependencies such as `standard` and `minitest`, and some gem dependencies such as `thor`.
|
data/Gemfile.lock
CHANGED
@@ -1,18 +1,18 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
emasser (3.
|
4
|
+
emasser (3.12.0)
|
5
5
|
activesupport (>= 6.1.4, < 7.1.0)
|
6
6
|
colorize (~> 0.8.1)
|
7
7
|
dotenv (~> 2.7.6)
|
8
|
-
emass_client (~> 3.
|
8
|
+
emass_client (~> 3.12)
|
9
9
|
rubyzip (~> 2.3.2)
|
10
10
|
thor (~> 1.1.0)
|
11
11
|
|
12
12
|
GEM
|
13
13
|
remote: https://rubygems.org/
|
14
14
|
specs:
|
15
|
-
activesupport (7.0.
|
15
|
+
activesupport (7.0.8)
|
16
16
|
concurrent-ruby (~> 1.0, >= 1.0.2)
|
17
17
|
i18n (>= 1.6, < 2)
|
18
18
|
minitest (>= 5.1)
|
@@ -26,16 +26,16 @@ GEM
|
|
26
26
|
concurrent-ruby (1.2.2)
|
27
27
|
diff-lcs (1.5.0)
|
28
28
|
dotenv (2.7.6)
|
29
|
-
emass_client (3.
|
29
|
+
emass_client (3.12.0)
|
30
30
|
typhoeus (~> 1.0, >= 1.0.1)
|
31
31
|
ethon (0.16.0)
|
32
32
|
ffi (>= 1.15.0)
|
33
|
-
ffi (1.
|
34
|
-
ffi (1.
|
33
|
+
ffi (1.16.3)
|
34
|
+
ffi (1.16.3-x64-mingw32)
|
35
35
|
i18n (1.14.1)
|
36
36
|
concurrent-ruby (~> 1.0)
|
37
37
|
json (2.6.3)
|
38
|
-
minitest (5.
|
38
|
+
minitest (5.20.0)
|
39
39
|
parallel (1.23.0)
|
40
40
|
parser (3.2.2.3)
|
41
41
|
ast (~> 2.4.1)
|
data/README.md
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
#
|
1
|
+
# eMASSer
|
2
2
|
![GitHub Release Date](https://img.shields.io/github/release-date/mitre/emasser?label=Release%20Date&logo=github&color=blue)
|
3
3
|
![GitHub release (latest by date)](https://img.shields.io/github/v/release/mitre/emasser?label=Release%20Version&logo=github) ![Gem](https://img.shields.io/gem/v/emasser?label=gem%20version&logo=ruby&logoColor=red) ![Docker Version](https://img.shields.io/docker/v/mitre/emasser?label=docker%20version&logo=docker&sort=semver)
|
4
4
|
|
@@ -9,29 +9,29 @@
|
|
9
9
|
|
10
10
|
## About
|
11
11
|
|
12
|
-
`
|
12
|
+
`eMASSer` is a Command Line Interface (CLI) that aims to automate routine business use-cases and provide utility surrounding the Enterprise Mission Assurance Support Service (eMASS) by leveraging its Representational State Transfer (REST) [Application Programming Interface (API)](https://mitre.github.io/emass_client/docs/eMASS_API_Documentation.pdf).
|
13
13
|
|
14
|
-
***NOTE***: The `
|
14
|
+
***NOTE***: The `eMASSer` CLI utilizes the [emass_client](https://github.com/mitre/emass_client) RubyGem executable package to access the eMASS API endpoints.
|
15
15
|
|
16
16
|
---
|
17
17
|
## Documentation
|
18
18
|
For detail content information about the `eMASS` API references the [**eMASS API Specification**](https://mitre.github.io/emass_client/docs/redoc/) page.
|
19
19
|
|
20
|
-
For detail features provided by the `
|
20
|
+
For detail features provided by the `eMASSer` CLI references the [**eMASSer CLI Features**](docs/features.md) page.
|
21
21
|
|
22
|
-
The `
|
22
|
+
The `eMASSer` CLI [**Architecture**](#emasser-cli-architecture) depicts the structure, and provides an explanation of CLI behaviors.
|
23
23
|
|
24
24
|
---
|
25
25
|
## Installation Options
|
26
26
|
|
27
|
-
`
|
27
|
+
`eMASSer` is a Ruby CLI distributed via GitHub (this repository), [RubyGems](https://rubygems.org/gems/emass_client/versions/), or [Docker](https://hub.docker.com/r/mitre/emasser/tags).
|
28
28
|
|
29
29
|
### Installation Dependencies
|
30
30
|
* git
|
31
31
|
* Ruby version 2.7 or greater
|
32
32
|
|
33
|
-
### Runtime Dependencies
|
34
|
-
* Ruby version 2.7 or greater
|
33
|
+
### Runtime Major Dependencies
|
34
|
+
* Ruby version 2.7 or greater
|
35
35
|
* `rubyzip (latest version)`
|
36
36
|
* `emass_client (latest version)`
|
37
37
|
* On Windows the `cURL` binary is required (libcurl.dll). To install cURL:
|
@@ -41,6 +41,7 @@ The `emasser` CLI [**Architecture**](#emasser-cli-architecture) depicts the `ema
|
|
41
41
|
- Extract the file into the Ruby installation /bin directory
|
42
42
|
- Rename the file to `libcurl.dll` if it has the `_x64` suffix
|
43
43
|
- Install [cURL for windows](https://community.chocolatey.org/packages/curl) and add the installation directory to the PATH.
|
44
|
+
* See the `emasser.gemspec` file for all other dependencies
|
44
45
|
|
45
46
|
|
46
47
|
## Install via GitHub
|
@@ -49,7 +50,7 @@ The `emasser` CLI [**Architecture**](#emasser-cli-architecture) depicts the `ema
|
|
49
50
|
git clone <path to emasser repository> emasser
|
50
51
|
cd emasser
|
51
52
|
```
|
52
|
-
- Build the
|
53
|
+
- Build the eMASSer gem*
|
53
54
|
```bash
|
54
55
|
gem build *.gemspec
|
55
56
|
gem install *.gem
|
@@ -81,7 +82,7 @@ bundle exec exe/emasser [command]
|
|
81
82
|
***Note:** See [Setting Environment Variables Configuration](https://github.com/mitre/emasser/wiki/Editing-Environment-Variables-Configuration) for detailed information on required and optional variables.
|
82
83
|
|
83
84
|
## Using Docker
|
84
|
-
Ensure that docker engine is running and start the
|
85
|
+
Ensure that docker engine is running and start the eMASSer Docker Container.
|
85
86
|
### Install
|
86
87
|
- On Linux or Mac:
|
87
88
|
```
|
@@ -109,7 +110,7 @@ Ensure that docker engine is running and start the emasser Docker Container.
|
|
109
110
|
```
|
110
111
|
- See [Editing Environment Variables Configuration](https://github.com/mitre/emasser/wiki/Editing-Environment-Variables-Configuration)
|
111
112
|
|
112
|
-
### Run
|
113
|
+
### Run eMASSer API client commands
|
113
114
|
- To list all available GET, POST, PUT, or DELETE commands use:
|
114
115
|
```
|
115
116
|
docker run --rm -v $PWD/path-to-secrets:/data mitre/emasser:latest get help
|
@@ -132,7 +133,7 @@ Ensure that docker engine is running and start the emasser Docker Container.
|
|
132
133
|
---
|
133
134
|
## Roadmap
|
134
135
|
|
135
|
-
The `
|
136
|
+
The `eMASSer` implements all endpoints provided by the `eMASS` API, there is, all of the functions available from the `eMASS GUI` that are exposed by the API. If additional functions are useful (accessible via the CLI), please submit a request to [eMass Tier III Support](mailto:disa.meade.id.mbx.emass-tier-iii-support@mail.mil) for possible inclusion into the API.
|
136
137
|
|
137
138
|
The Road Map seeks to add any useful features that facilitates organization that utilizes `eMASS` instances and have a need to automate their cybersecurity management process.
|
138
139
|
|
@@ -147,13 +148,13 @@ Some proposed capabilities (looking for a sponsor) are:
|
|
147
148
|
## Design
|
148
149
|
|
149
150
|
### Interactions with eMASS API
|
150
|
-
The `
|
151
|
+
The `eMASSer` CLI leverages the [emass_client](https://github.com/mitre/emass_client), which provides a REST API client developed by MITRE based on the [OpenAPI V3](https://www.openapis.org/) standards for the official [eMASS API specification](https://mitre.github.io/emass_client/docs/redoc). This design enables REST API clients to be generated in [any supported programming language](https://openapi-generator.tech/docs/generators/). The design enables the `emass_client` to be generated independently of the eMASSer CLI. Currently, a Ruby and a Typescript eMASS client API are provided. The TypeScript client is used with the [Security Automation Framework CLI (SAF) CLI](https://github.com/mitre/saf).
|
151
152
|
|
152
153
|
### Business Logic
|
153
|
-
Because interactions with the API are handled by a dependency, the bulk of `
|
154
|
+
Because interactions with the API are handled by a dependency, the bulk of `eMASSer` business logic is for accepting user input/output, reading data from eMASS or from input, transforming data, and routing data to the appropriate eMASS API endpoint. This business logic is organized into Ruby Classes and Modules based on the command or subcommand requested by the user.
|
154
155
|
|
155
|
-
##
|
156
|
-
The `
|
156
|
+
## eMASSer CLI Architecture
|
157
|
+
The `eMASSer` CLI makes use of the `emass_client` ruby gem to communicate with an `eMASS` instance via the `eMASS API` as depicted in the diagram below:
|
157
158
|
|
158
159
|
<div align="center">
|
159
160
|
<img src="images/emasser_architecture.jpg" alt="emasser CLI Architecture" title="emasser CLI Architecture">
|