emasser 1.0.6 → 3.4.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (61) hide show
  1. checksums.yaml +4 -4
  2. data/.dockerignore +8 -8
  3. data/.env-example +12 -12
  4. data/.github/release-drafter.yml +15 -15
  5. data/.github/workflows/codeql-analysis.yml +70 -70
  6. data/.github/workflows/draft-release.yml +15 -15
  7. data/.github/workflows/gh-pages.yml +32 -32
  8. data/.github/workflows/push-to-docker-mail.yml +28 -28
  9. data/.github/workflows/push-to-docker.yml +35 -35
  10. data/.github/workflows/release.yml +42 -42
  11. data/.github/workflows/rubocop.yml +23 -23
  12. data/.github/workflows/test-cli.yml +72 -72
  13. data/.gitignore +19 -19
  14. data/.mergify.yml +25 -25
  15. data/.rubocop.yml +80 -80
  16. data/.rubocop_todo.yml +27 -27
  17. data/CHANGELOG.md +16 -16
  18. data/Dockerfile +44 -44
  19. data/Gemfile +8 -8
  20. data/Gemfile.lock +104 -104
  21. data/LICENSE.md +15 -15
  22. data/README.md +178 -178
  23. data/Rakefile +18 -18
  24. data/_config.yml +1 -1
  25. data/docs/features.md +1436 -1330
  26. data/docs/redoc/index.html +1230 -1230
  27. data/emasser.gemspec +44 -44
  28. data/exe/emasser +5 -5
  29. data/lib/emasser/cli.rb +37 -37
  30. data/lib/emasser/configuration.rb +49 -49
  31. data/lib/emasser/constants.rb +26 -26
  32. data/lib/emasser/delete.rb +148 -148
  33. data/lib/emasser/errors.rb +14 -14
  34. data/lib/emasser/get.rb +949 -670
  35. data/lib/emasser/help/approvalCac_post_mapper.md +20 -20
  36. data/lib/emasser/help/approvalPac_post_mapper.md +20 -20
  37. data/lib/emasser/help/artifacts_del_mapper.md +9 -9
  38. data/lib/emasser/help/artifacts_post_mapper.md +59 -59
  39. data/lib/emasser/help/artifacts_put_mapper.md +34 -34
  40. data/lib/emasser/help/cloudresource_post_mapper.md +62 -62
  41. data/lib/emasser/help/cmmc_get_mapper.md +4 -4
  42. data/lib/emasser/help/container_post_mapper.md +44 -44
  43. data/lib/emasser/help/controls_put_mapper.md +74 -74
  44. data/lib/emasser/help/milestone_del_mapper.md +11 -11
  45. data/lib/emasser/help/milestone_post_mapper.md +14 -14
  46. data/lib/emasser/help/milestone_put_mapper.md +23 -23
  47. data/lib/emasser/help/poam_del_mapper.md +5 -5
  48. data/lib/emasser/help/poam_post_mapper.md +93 -93
  49. data/lib/emasser/help/poam_put_mapper.md +107 -107
  50. data/lib/emasser/help/staticcode_clear_mapper.md +16 -16
  51. data/lib/emasser/help/staticcode_post_mapper.md +21 -21
  52. data/lib/emasser/help/testresults_post_mapper.md +21 -21
  53. data/lib/emasser/help.rb +11 -11
  54. data/lib/emasser/input_converters.rb +21 -21
  55. data/lib/emasser/options_parser.rb +20 -20
  56. data/lib/emasser/output_converters.rb +111 -111
  57. data/lib/emasser/post.rb +830 -802
  58. data/lib/emasser/put.rb +588 -588
  59. data/lib/emasser/version.rb +5 -5
  60. data/lib/emasser.rb +19 -19
  61. metadata +10 -16
data/docs/features.md CHANGED
@@ -1,1331 +1,1437 @@
1
- # emasser CLI Features
2
-
3
- ## Environment Variables
4
- To facilitate setting the required environment variables the `emasser `CLI utilized the zero-dependency module to load these variables from a `.env` file.
5
-
6
- ### Configuring the `.env` File
7
- An `.env-example` file is provided with the required and optional fields.
8
-
9
- Modify the `.env_example` as necessary and save it as a `.env` file.
10
-
11
- Place the file on the path where the `emasser` command is executed.
12
-
13
- ### Required and Optional Environment Variables
14
- The following environment variables are required:
15
- * EMASSER_API_KEY_API_KEY=`<API key>`
16
- * EMASSER_API_KEY_USER_UID=`<unique identifier for the API Key (EMASSER_API_KEY_API_KEY)`
17
- * EMASSER_HOST=`<FQDN of the eMASS server>`
18
- * EMASSER_KEY_FILE_PATH=`<path to your eMASS key in PEM format>`
19
- * EMASSER_CERT_FILE_PATH=`<path to your eMASS certificate in PEM format>`
20
- * EMASSER_KEY_PASSWORD=`<password for the key given in EMASSER_KEY_FILE_PATH>`
21
-
22
- The following environment variables are *optional:
23
- * EMASSER_CLIENT_SIDE_VALIDATION=`<client side validation - true or false (default true)>`
24
- * EMASSER_VERIFY_SSL=`<verify SSL - true or false (default true)>`
25
- * EMASSER_VERIFY_SSL_HOST=`<verify host SSL - true or false (default true)>`
26
- * EMASSER_DEBUGGING=`<set debugging - true or false (default false)>`
27
- * EMASSER_CLI_DISPLAY_NULL=`<display null value fields - true or false (default true)>`
28
- * EMASSER_POCH_TO_DATETIME=`<convert epoch to data/time value - true or false (default false)>`
29
-
30
- \* If not provided defaults are used
31
-
32
- The proper format to set these variables in the `.env` files is as follows:
33
- ```bash
34
- export [VARIABLE_NAME]='value'
35
- ```
36
- ***NOTE***
37
- `emasser` requires authentication to an eMASS instance as well as authorization to use the eMASS API. This authentication and authorization is **not** a function of `emasser` and needs to be accomplished with the eMASS instances owner organization. Further information about eMASS credential requirements refer to [Defense Counterintelligence and Security Agency](https://www.dcsa.mil/is/emass/) about eMASS access.
38
-
39
- ---
40
- ## Common emasser Endpoint Requests Information
41
- - To invoke any boolean parameters use --parameterName for TRUE and --no-parameterName for FALSE
42
- - The eMASS API provides the capability of updating multiple entries within several endpoints, however the `emasser` CLI, in some cases only supports updating one entry at the time.
43
-
44
- ## Invoking emasser CLI Commands
45
-
46
- The CLI invoke commands listed in this document shows them when executing from the source code (after a pull from GitHub). Please reference the [`emasser` README](https://mitre.github.io/emasser/) on how to invoke the CLI using other available executables (gem or docker).
47
-
48
- ## API Endpoints Provided
49
-
50
- ### GET
51
- * [/api](#get-test-connection)
52
- * [/api/system](#get-system)
53
- * [/api/systems](#get-systems)
54
- * [/api/systems/{systemId}](#get-system)
55
- * [/api/system-roles](#get-roles)
56
- * [/api/system-roles/{roleCategory}](#get-roles)
57
- * [/api/systems/{systemId}/controls](#get-controls)
58
- * [/api/systems/{systemId}/test-results](#get-testresults)
59
- * [/api/systems/{systemId}/poams](#get-poams)
60
- * [/api/systems/{systemId}/poams/{poamId}](#get-poams)
61
- * [/api/systems/{systemId}/poams/{poamId}/milestones](#get-milestones)
62
- * [/api/systems/{systemId}/poams/{poamId}/milestones/{milestoneId})](#get-milestones)
63
- * [/api/systems/{systemId}/artifacts](#get-artifacts)
64
- * [/api/systems/{systemId}/artifacts-export](#get-artifacts)
65
- * [/api/systems/{systemId}/approval/cac](#get-cac)
66
- * [/api/systems/{systemId}/approval/pac](#get-pac)
67
- * [/api/cmmc-assessments](#get-cmmc)
68
- * [/api/workflow-definitions](#get-workflowdefinitions)
69
- * [/api/systems/{systemId}/workflow-instances](#get-workflowinstances)
70
-
71
- ### POST
72
- * [/api/systems/{systemId}/test-results](#post-test_results)
73
- * [/api/systems/{systemId}/poam](#post-poams)
74
- * [/api/systems/{systemId}/poam/{poamId}/milestones](#post-milestones)
75
- * [/api/systems/{systemId}/artifacts](#post-artifacts)
76
- * [/api/systems/{systemId}/approval/cac](#post-cac)
77
- * [/api/systems/{systemId}/approval/pac](#post-pac)
78
- * [/api/systems/{systemId}/static-code-scans](#post-static_code_scan)
79
- * [/api/systems/{systemId}/cloud-resource-results](#post-cloudresource)
80
- * [/api/systems/{systemId}/container-scan-results](#post-container)
81
-
82
- ### PUT
83
- * [/api/systems/{systemId}/controls](#put-controls)
84
- * [/api/systems/{systemId}/poams](#put-poams)
85
- * [/api/systems/{systemId}/poams/{poamId}/milestones](#put-milestones)
86
- * [/api/systems/{systemId}/artifacts](#put-artifacts)
87
-
88
- ### DELETE
89
- * [/api/systems/{systemId}/poams](#delete-poams)
90
- * [/api/systems/{systemId}/poams/{poamId}/milestones](#delete-milestones)
91
- * [/api/systems/{systemId}/artifacts](#delete-artifacts)
92
-
93
- ## Endpoints CLI help
94
-
95
- Each CLI endpoint command has several layers of help.
96
- - Using `help` after a `get, put, post, or delete` command lists all available endpoint calls. The following command would list all available `GET` endpoints commands.
97
-
98
- ```bash
99
- $ bundle exec exe/emasser get help
100
- Commands:
101
- emasser get artifacts # Get system Artifacts
102
- emasser get cac # Get location of one or many controls in...
103
- emasser get cmmc # Get CMMC assessment information
104
- emasser get controls # Get system Controls
105
- emasser get help [COMMAND] # Describe subcommands or one specific su...
106
- emasser get milestones # Get system Milestones
107
- emasser get pac # Get status of active workflows in a system
108
- emasser get poams # Get system Poams
109
- emasser get roles # Get all system roles or by category Id
110
- emasser get system # Get a system ID given name/owner, or ge...
111
- emasser get systems # Get all systems
112
- emasser get test # Test connection to the configured eMASS...
113
- emasser get test_results # Get system Test Results
114
- emasser get workflow_definitions # Get workflow definitions in a site
115
- emasser get workflow_instances # Get workflow instance by system and/or ...
116
- ```
117
- - Preceding any command with `help` provides help for the command. The following command would list all available sub-commands and options for the `get artifacts` endpoint command.
118
- ```bash
119
- $ bundle exec exe/emasser get help artifacts
120
- commands:
121
- emasser get artifacts export --filename=FILENAME --systemId=N # Get artifa...
122
- emasser get artifacts forSystem --systemId=N # Get all sy...
123
- emasser get artifacts help [COMMAND] # Describe s...
124
- ```
125
- - Using `help` after any command lists all available options. The following command would list all available options for the `get artifacts export` endpoint command.
126
- ```bash
127
- $ bundle exec exe/emasser get artifacts help export
128
- Usage:
129
- emasser get artifacts export --filename=FILENAME --systemId=N
130
-
131
- Options:
132
- --systemId=N # A numeric value representing the system identification
133
- --filename=FILENAME # The artifact file name
134
- [--compress], [--no-compress] # BOOLEAN - true or false.
135
- ```
136
- **The same format is applicable for POST, PUT and DELETE requests as well, however there may be additional help content**
137
-
138
-
139
- ## Usage - GET
140
-
141
- ### ```get test connection```
142
- ---
143
- The Test Connection endpoint provides the ability to verify connection to the web service.
144
-
145
- $ bundle exec exe/emasser get test connection
146
-
147
- A return of success from the call indicates that the CLI can reach the configure server URL.
148
- References [Required Environment Variables](#required-environment-variables) for the necessary environment variables.
149
-
150
- [top](#api-endpoints-provided)
151
-
152
- ### ```get system```
153
-
154
- ---
155
- The `get system` command is not a sanctioned eMASS endpoint, it makes use of the `get systems` endpoint with added business logic.
156
-
157
- There are two commands provided by the get system:
158
-
159
- - The `get system id` - returns system ID's based on the system `name` or `owner`
160
- - The `get system byId` - returns the system content for parameter system ID
161
-
162
- ### get system id
163
- Retrieves a system identification based on the SYSTEM_NAME (name) or SYSTEM_OWNER (systemOwner) fields.
164
-
165
- To invoke the `get system id` use the following command:
166
-
167
- $ bundle exec exe/emasser get system id --system_name "system name" --system_owner "system owner"
168
-
169
- If using a platform that has `awk` installed the following command can be used to return only the system Id:
170
-
171
- $ bundle exec exe/emasser get system --system_name "system name" --system_owner "system owner" | awk "{ print $1 }"
172
-
173
-
174
- ### get system byId
175
- Retrieves the system content for provided identification (ID) number. To invoke the endpoint use the following command:
176
-
177
- $ bundle exec exe/emasser get system byId
178
-
179
- - required parameter is:
180
-
181
- |parameter | type or values |
182
- |-------------|:----------------------------------|
183
- |--systemId |Integer - Unique system identifier |
184
-
185
- - Optional parameters are:
186
-
187
- |parameter | type or values |
188
- |------------------------|:----------------------------------------|
189
- |--includePackage |BOOLEAN - true or false |
190
- |--policy |Possible values: diacap, rmf, reporting |
191
-
192
- [top](#api-endpoints-provided)
193
-
194
- ### ```get systems```
195
-
196
- ----
197
- To retrieve controls use the following command:
198
- - all - Retrieves all available systems
199
- ```
200
- $ bundle exec exe/emasser get systems all
201
- ```
202
-
203
- - Optional parameters are:
204
-
205
- |parameter | type or values |
206
- |------------------------|:----------------------------------------------------------------------------|
207
- |--coamsId |Cyber Operational Attributes Management System (COAMS) string Id |
208
- |--ditprId |DoD Information Technology (IT) Portfolio Repository (DITPR) string id |
209
- |--includeDecommissioned |BOOLEAN - true or false |
210
- |--includeDitprMetrics |BOOLEAN - true or false |
211
- |--includePackage |BOOLEAN - true or false |
212
- |--policy |Possible values: diacap, rmf, reporting |
213
- |--registrationType |Possible values: assessAndAuthorize, assessOnly, guest, regular, functional, |
214
- | | cloudServiceProvider, commonControlProvider |
215
- |--reportsForScorecard |BOOLEAN - true or false |
216
-
217
- [top](#api-endpoints-provided)
218
- ### ```get roles```
219
-
220
- ----
221
- There are two get endpoints for system roles:
222
- - all - Retrieves all available roles
223
- ```
224
- $ bundle exec exe/emasser get roles all
225
- ```
226
- - byCategory - Retrieves roles based on the following required parameter:
227
- ````
228
- $ bundle exec exe/emasser get roles byCategory --roleCategory=ROLECATEGORY --role=ROLE
229
- ````
230
- - required parameters are:
231
-
232
- |parameter | type or values |
233
- |:---------------|:------------------------------------------|
234
- |--roleCategory |Possible values: PAC, CAC, Other |
235
- |--role |Possible values: AO, Auditor, Artifact Manager, C&A Team, IAO, ISSO, PM/IAM, SCA, User Rep (View Only), Validator (IV&V)|
236
-
237
- - optional parameter are:
238
-
239
- |parameter | type or values |
240
- |------------------------|:----------------------------------------|
241
- |--policy |Possible values: diacap, rmf, reporting |
242
- |--includeDecommissioned |BOOLEAN - true or false |
243
-
244
- [top](#api-endpoints-provided)
245
- ### ```get controls```
246
-
247
- ----
248
- To retrieve controls use the following command:
249
-
250
- $ bundle exec exe/emasser get controls forSystem --systemId=SYSTEMID
251
-
252
- - required parameter is:
253
-
254
- |parameter | type or values |
255
- |-------------|:----------------------------------|
256
- |--systemId |Integer - Unique system identifier |
257
-
258
- - optional parameter is:
259
-
260
- |parameter | type or values |
261
- |-------------|:------------------------------------------|
262
- |--acronyms |The system acronym(s) e.g "AC-1, AC-2" - if not provided all controls for systemId are returned |
263
-
264
- [top](#api-endpoints-provided)
265
- ### ```get test_results```
266
-
267
- ----
268
- To retrieve test results use the following command:
269
-
270
- $ bundle exec exe/emasser get test_results forSystem --systemId=SYSTEMID
271
-
272
- - required parameter is:
273
-
274
- |parameter | type or values |
275
- |-------------|:----------------------------------|
276
- |--systemId |Integer - Unique system identifier |
277
-
278
- - optional parameters are:
279
-
280
- |parameter | type or values |
281
- |-------------------|:------------------------------------------|
282
- |--controlAcronyms |String - The system acronym(s) e.g "AC-1, AC-2" |
283
- |--ccis |String - The system CCIS string numerical value |
284
- |--latestOnly |BOOLEAN - true or false|
285
-
286
- [top](#api-endpoints-provided)
287
- ### ```get poams```
288
-
289
- ----
290
- There are two get endpoints for system poams:
291
- - forSystem - Retrieves all poams for specified system ID
292
- ````
293
- $ bundle exec exe/emasser get poams forSystem --systemId=SYSTEMID
294
- ````
295
- - required parameter is:
296
-
297
- |parameter | type or values |
298
- |-------------|:----------------------------------|
299
- |--systemId |Integer - Unique system identifier |
300
-
301
- - optional parameters are:
302
-
303
- |parameter | type or values |
304
- |-------------------------------|:----------------------------------------------|
305
- |--scheduledCompletionDateStart |Date - Unix time format (e.g. 1499644800) |
306
- |--scheduledCompletionDateEnd |Date - Unix time format (e.g. 1499990400) |
307
- |--controlAcronyms |String - The system acronym(s) e.g "AC-1, AC-2"|
308
- |--ccis |String - The system CCIS string numerical value|
309
- |--systemOnly |BOOLEAN - true or false|
310
-
311
-
312
- - byPoamId - Retrieves all poams for specified system and poam ID
313
- ````
314
- $ bundle exec exe/emasser get poams byPoamId --systemId=SYSTEMID --poamId=POAMID
315
- ````
316
- - required parameters are:
317
-
318
- |parameter | type or values |
319
- |-------------|:----------------------------------|
320
- |--systemId |Integer - Unique system identifier |
321
- |--poamId |Integer - Unique poam identifier |
322
-
323
- [top](#api-endpoints-provided)
324
- ### ```get milestones```
325
-
326
- ----
327
- There are two get endpoints for system milestones:
328
- - byPoamId - Retrieves milestone(s) for specified system and poam ID
329
- ````
330
- $ bundle exec exe/emasser get milestones byPoamId --systemId=SYSTEMID --poamId=POAMID
331
- ````
332
- - required parameters are:
333
-
334
- |parameter | type or values |
335
- |-------------|:----------------------------------|
336
- |--systemId |Integer - Unique system identifier |
337
- |--poamId |Integer - Unique poam identifier |
338
-
339
- - optional parameters are:
340
-
341
- |parameter | type or values |
342
- |-------------------------------|:----------------------------------------------|
343
- |--scheduledCompletionDateStart |Date - Unix time format (e.g. 1499644800) |
344
- |--scheduledCompletionDateEnd |Date - Unix time format (e.g. 1499990400) |
345
-
346
-
347
- - byMilestoneId, Retrieve milestone(s) for specified system, poam, and milestone ID"
348
- ````
349
- $ bundle exec exe/emasser get poams byMilestoneId --systemId=SYSTEMID --poamId=POAMID --milestoneId=MILESTONEID
350
- ````
351
- - required parameters are:
352
-
353
- |parameter | type or values |
354
- |--------------|:-------------------------------------|
355
- |--systemId |Integer - Unique system identifier |
356
- |--poamId |Integer - Unique poam identifier |
357
- |--milestoneId |Integer - Unique milestone identifier |
358
-
359
- [top](#api-endpoints-provided)
360
- ### ```get artifacts```
361
-
362
- ----
363
- There are two get endpoints that provides the ability to view existing `Artifacts` in a system:
364
-
365
- - forSystem - Retrieves one or many artifacts in a system specified system ID
366
- ````
367
- $ bundle exec exe/emasser get artifacts forSystem --systemId=SYSTEMID
368
- ````
369
- - required parameter is:
370
-
371
- |parameter | type or values |
372
- |-------------|:----------------------------------|
373
- |--systemId |Integer - Unique system identifier |
374
-
375
- - optional parameters are:
376
-
377
- |parameter | type or values |
378
- |-------------------------------|:----------------------------------------------|
379
- |--filename |The artifact file name |
380
- |--controlAcronyms |String - The system acronym(s) e.g "AC-1, AC-2"|
381
- |--ccis |String - The system CCIS string numerical value|
382
- |--systemOnly |BOOLEAN - true or false|
383
-
384
- - export - Retrieves the file artifacts (if compress is true the file binary contents are returned, otherwise the file textual contents are returned.)
385
- ````
386
- $ bundle exec exe/emasser get artifacts export --systemId=SYSTEMID
387
- ````
388
- - required parameters are:
389
-
390
- |parameter | type or values |
391
- |-------------|:----------------------------------|
392
- |--systemId |Integer - Unique system identifier |
393
- |--filename |The artifact file name |
394
-
395
- - optional parameter is:
396
- |parameter | type or values |
397
- |-------------|:----------------------------------|
398
- |--compress |BOOLEAN - true or false. |
399
-
400
- [top](#api-endpoints-provided)
401
- ### ```get cac```
402
-
403
- ----
404
- To view one or many Control Approval Chain (CAC) in a system specified system ID use the following command:
405
- ```
406
- $ bundle exec exe/emasser get cac controls --systemId=SYSTEMID
407
- ```
408
- - required parameter is:
409
-
410
- |parameter | type or values |
411
- |-------------|:----------------------------------|
412
- |--systemId |Integer - Unique system identifier |
413
-
414
- - optional parameter is:
415
-
416
- |parameter | type or values |
417
- |-------------------------------|:----------------------------------------------|
418
- |--controlAcronyms |String - The system acronym(s) e.g "AC-1, AC-2"|
419
-
420
- [top](#api-endpoints-provided)
421
- ### ```get pac```
422
-
423
- ----
424
- To view one or many Package Approval Chain (PAC) in a system specified system ID use the following command:
425
-
426
- ````
427
- $ bundle exec exe/emasser get pac package --systemId=SYSTEMID
428
- ````
429
- - required parameter is:
430
-
431
- |parameter | type or values |
432
- |-------------|:----------------------------------|
433
- |--systemId |Integer - Unique system identifier |
434
-
435
- [top](#api-endpoints-provided)
436
- ### ```get cmmc```
437
-
438
- ----
439
- To view Cybersecurity Maturity Model Certification (CMMC) Assessments use the following command:
440
-
441
- $ bundle exec exe/emasser get workflow_definitions forSite --sinceDate=SINCEDATE
442
-
443
- - Required parameters are:
444
-
445
- |parameter | type or values |
446
- |----------------|:--------------------------------------|
447
- |--sinceDate |Date - The CMMC date. Unix date format |
448
-
449
- [top](#api-endpoints-provided)
450
- ### ```get workflow_definitions```
451
-
452
- ----
453
- To view Workflow Definitions use the following command:
454
-
455
- $ bundle exec exe/emasser get workflow_definitions forSite
456
-
457
- - Optional parameters are:
458
-
459
- |parameter | type or values |
460
- |---------------------|:----------------------------------------------------------------------------|
461
- |--includeInactive |BOOLEAN - true or false |
462
- |--registrationType |Possible values: assessAndAuthorize, assessOnly, guest, regular, functional, |
463
- | | cloudServiceProvider, commonControlProvider |
464
-
465
- [top](#api-endpoints-provided)
466
-
467
- ### ```get workflow_instances```
468
- ----
469
- There are two get endpoints to view workflow instances:
470
- - all
471
- $ bundle exec exe/emasser get workflow_instances all
472
-
473
- - Optional parameters are:
474
-
475
- |parameter | type or values |
476
- |-------------------|:---------------------------------------------------|
477
- |--includeComments |BOOLEAN - true or false |
478
- |--pageIndex |Integer - The page number to query |
479
- |--sinceDate |Date - The Workflow Instance date. Unix date format |
480
- |--status |Possible values: active, inactive, all |
481
-
482
- - byWorkflowInstanceId
483
- $ bundle exec exe/emasser get workflow_instances byWorkflowInstanceId --workflowInstanceId=--WORKFLOWID
484
-
485
- - required parameter is:
486
-
487
- |parameter | type or values |
488
- |---------------------|:---------------------------------------------|
489
- |--workflowInstanceId |Integer - Unique workflow instance identifier |
490
-
491
- [top](#api-endpoints-provided)
492
-
493
-
494
- ## Usage - POST
495
-
496
- ### ``post test_results``
497
- ---
498
- Test Result add (POST) endpoint API business rules.
499
-
500
- |Business Rule | Parameter/Field |
501
- |---------------------------------------------------------------------|:-----------------|
502
- | Tests Results cannot be saved if the "Test Date" is in the future. | `testDate` |
503
- | Test Results cannot be saved if a Security Control is "Inherited" in the system record. | `description` |
504
- | Test Results cannot be saved if an Assessment Procedure is "Inherited" in the system record. | `description` |
505
- | Test Results cannot be saved if the AP does not exist in the system. | `description` |
506
- | Test Results cannot be saved if the control is marked "Not Applicable" by an Overlay. | `description` |
507
- | Test Results cannot be saved if the control is required to be assessed as "Applicable" by an Overlay.| `description` |
508
- | Test Results cannot be saved if the Tests Results entered is greater than 4000 characters.|`description`|
509
- | Test Results cannot be saved if the following fields are missing data: | `complianceStatus`, `testDate`, `testedBy`, `description`|
510
- | Test results cannot be saved if there is more than one test result per CCI |`cci`|
511
-
512
- ---
513
- To add (POST) test results use the following command:
514
-
515
- ````
516
- $ bundle exec exe/emasser post test_results add --systemId [value] --cci [value] --testedBy [value] --testDate [value] --description [value] --complianceStatus [value]
517
- ````
518
- Note: If no POA&Ms or AP exist for the control (system), you will get this response:
519
- "You have entered a Non-Compliant Test Result. You must create a POA&M Item for this Control and/or AP if one does not already exist."
520
-
521
- - required parameter are:
522
-
523
- |parameter | type or values |
524
- |-------------------|:------------------------------------------------------------|
525
- |--systemId |Integer - Unique system identifier |
526
- |--cci |String - CCI associated with the test result. e.g "00221" |
527
- |--testedBy |String - Last Name, First Name. 100 Characters. |
528
- |--testDate |Date - Unix time format (e.g. 1499990400) |
529
- |--description |String - Include description of test result. 4000 Characters |
530
- |--complianceStatus |Possible values: Compliant, Non-Compliant, Not Applicable |
531
-
532
- **Note**
533
- For information at the command line use:
534
- ```
535
- $ bundle exec exe/emasser post test_results help add
536
- ```
537
- [top](#post)
538
-
539
- ### ``post poams``
540
- ---
541
- Plan of Action and Milestones (POA&M) add (POST) endpoint API business rules.
542
-
543
- The following fields are required based on the contents of the status field
544
-
545
- |status |Required Fields
546
- |----------------|--------------------------------------------------------
547
- |Risk Accepted |comments
548
- |Ongoing |scheduledCompletionDate, milestones (at least 1)
549
- |Completed |scheduledCompletionDate, comments, completionDate, milestones (at least 1)
550
- |Not Applicable |POAM can not be created
551
-
552
- If a POC email is supplied, the application will attempt to locate a user
553
- already registered within the application and pre-populate any information
554
- not explicitly supplied in the request. If no such user is found, these
555
- fields are required within the request.
556
- - pocOrganization, pocFirstName, pocLastName, pocEmail, pocPhoneNumber
557
-
558
- Business logic, the following rules apply when adding POA&Ms
559
-
560
- - POA&M Items cannot be saved if associated Security Control or AP is inherited.
561
- - POA&M Items cannot be created manually if a Security Control or AP is Not Applicable.
562
- - Completed POA&M Item cannot be saved if Completion Date is in the future.
563
- - Completed POA&M Item cannot be saved if Completion Date (completionDate) is in the future.
564
- - Risk Accepted POA&M Item cannot be saved with a Scheduled Completion Date or Milestones
565
- - POA&M Items with a review status of "Not Approved" cannot be saved if Milestone Scheduled Completion Date exceeds POA&M Item Scheduled Completion Date.
566
- - POA&M Items with a review status of "Approved" can be saved if Milestone Scheduled Completion Date exceeds POA&M Item Scheduled Completion Date.
567
- - POA&M Items that have a status of "Completed" and a status of "Ongoing" cannot be saved without Milestones.
568
- - POA&M Items that have a status of "Risk Accepted" cannot have milestones.
569
- - POA&M Items with a review status of "Approved" that have a status of "Completed" and "Ongoing" cannot update Scheduled Completion Date.
570
- - POA&M Items that have a review status of "Approved" are required to have a Severity Value assigned.
571
- - POA&M Items cannot be updated if they are included in an active package.
572
- - Archived POA&M Items cannot be updated.
573
- - POA&M Items with a status of "Not Applicable" will be updated through test result creation.
574
- - If the Security Control or Assessment Procedure does not exist in the system we may have to just import POA&M Item at the System Level.
575
-
576
-
577
- The following POA&M parameters/fields have the following character limitations:
578
- - Fields that can not exceed 100 characters:
579
- - Office / Organization (`pocOrganization`)
580
- - First Name (`pocFirstName`)
581
- - Last Name (`pocLastName`)
582
- - Email (`email`)
583
- - Phone Number (`pocPhoneNumber`)
584
- - External Unique ID (`externalUid`)
585
- - Fields that can not exceed 250 characters:
586
- - Resource (`resource`)
587
- - Fields have can not exceed 2000 character:
588
- - Vulnerability Description (`vulnerabilityDescription`)
589
- - Source Identifying Vulnerability (`sourceIdentVuln`)
590
- - Recommendations (`recommendations`)
591
- - Risk Accepted Comments (`comments`)
592
- - Milestone Description (`description`)
593
- - Mitigation Justification (`mitigation`)
594
-
595
- To add (POST) POA&Ms use the following command:
596
- ```
597
- $ bundle exec exe/emasser post poams add --systemId [value] --status [value] --vulnerabilityDescription [value] --sourceIdentVuln [value] --pocOrganization [value] --resources [value]
598
- ```
599
- **Notes:**
600
- - The above listed parameters/fields are the minimal required.
601
- - Based on the value for the status (--status) parameter additional fields are required
602
- - Refer to instructions listed above for conditional and optional fields requirements.
603
- - When a milestone is required the format is:
604
- - --milestone description:[value] scheduledCompletionDate:[value]
605
-
606
- **If a milestone Id is provided (--milestone milestoneId:[value]) the POA&M with the provided milestone Id is updated and the new POA&M milestones is set to null.**
607
-
608
- ---
609
- Client API parameters/fields (required, conditional, and optional).
610
- - required parameter are:
611
-
612
- |parameter | type or values |
613
- |---------------------------|:---------------------------------------------------------------|
614
- |--systemId |Integer - Unique system identifier |
615
- |--status |Possible Values: Ongoing,Risk Accepted,Completed,Not Applicable |
616
- |--vulnerabilityDescription |String - Vulnerability description for the POA&M Item |
617
- |--sourceIdentVuln |String - Include Source Identifying Vulnerability text |
618
- |--pocOrganization |String - Organization/Office represented |
619
- |--resources |String - List of resources used. Character Limit = 250 |
620
-
621
- ** If any poc information is provided all POC fields are required. See additional details for POC fields below.
622
-
623
- - conditional parameters are:
624
-
625
- |parameter | type or values |
626
- |--------------------------|:------------------------------------------------------------------------|
627
- |--milestones |JSON - see milestone format |
628
- |--pocFirstName |String - First name of POC |
629
- |--pocLastName |String - Last name of POC |
630
- |--pocEmail |String - Email address of POC |
631
- |--pocPhoneNumber |String - Phone number of POC (area code) ***-**** format |
632
- |--severity |Possible values - Very Low, Low, Moderate, High, Very High |
633
- |--scheduledCompletionDate |Date - Required for ongoing and completed POA&M items. Unix time format |
634
- |--completionDate |Date - Field is required for completed POA&M items. Unix time format |
635
- |--comments |String - Field is required for completed and risk accepted POA&M items. |
636
-
637
- ** If a POC email is supplied, the application will attempt to locate a user already registered within the application and pre-populate any information not explicitly supplied in the request. If no such user is found, these fields are required within the request:
638
- pocFirstName, pocLastName, pocPhoneNumber
639
-
640
- Milestone Format:
641
- - --milestone description:[value] scheduledCompletionDate:[value]
642
-
643
- - optional parameters are:
644
-
645
- |parameter | type or values |
646
- |--------------------|:-----------------------------------------------------------------------------------------|
647
- |--externalUid |String - External unique identifier for use with associating POA&M Items |
648
- |--controlAcronym |String - Control acronym associated with the POA&M Item. NIST SP 800-53 Revision 4 defined|
649
- |--cci |String - CCI associated with the test result |
650
- |--securityChecks |String - Security Checks that are associated with the POA&M |
651
- |--rawSeverity |Possible values: I, II, III |
652
- |--relevanceOfThreat |Possible values: Very Low, Low, Moderate, High, Very High |
653
- |--likelihood |Possible values: Very Low, Low, Moderate, High, Very High |
654
- |--impact |Possible values: Very Low, Low, Moderate, High, Very High |
655
- |--impactDescription |String - Include description of Security Control’s impact |
656
- |--residualRiskLevel |Possible values: Very Low, Low, Moderate, High, Very High |
657
- |--recommendations |String - Include recommendations |
658
- |--mitigation |String - Include mitigation explanation |
659
-
660
-
661
- **Note**
662
- For information at the command line use:
663
- ```
664
- $ bundle exec exe/emasser post poams help add
665
- ```
666
- [top](#post)
667
-
668
- ### ``post milestones``
669
- ---
670
- To add (POST) milestones in a system for one or more POA&M items use the following command:
671
-
672
- ````
673
- $ bundle exec exe/emasser post milestones add --systemId [value] --poamId [value] --description [value] --scheduledCompletionDate [value]
674
- ````
675
- - required parameter are:
676
-
677
- |parameter | type or values |
678
- |---------------------------|:----------------------------------------------------|
679
- |--systemId |Integer - Unique system identifier |
680
- |--poamId |Integer - Unique item identifier |
681
- |--description |String - Milestone item description. 2000 Characters |
682
- |--scheduledCompletionDate |Date - Schedule completion date. Unix date format |
683
-
684
-
685
- **Note**
686
- For information at the command line use:
687
- ```
688
- $ bundle exec exe/emasser post milestones help add
689
- ```
690
- [top](#post)
691
-
692
- ### ``post artifacts``
693
- ---
694
- The add (POST) artifacts endpoint accepts a single binary file with file extension.zip only. The command line (CI) reads the files provided and zips them before sending to eMASS.
695
-
696
- ```
697
- If no artifact is matched via filename to the application, a new artifact will be created with the following default values. Any values not specified below will be blank.
698
- - isTemplate: false
699
- - type: other
700
- - category: evidence
701
- ```
702
-
703
- Business Rules:
704
- - Artifact cannot be saved if the file does not have the following file extensions:
705
- - .docx,.doc,.txt,.rtf,.xfdl,.xml,.mht,.mhtml,.html,.htm,.pdf
706
- - .mdb,.accdb,.ppt,.pptx,.xls,.xlsx,.csv,.log
707
- - .jpeg,.jpg,.tiff,.bmp,.tif,.png,.gif
708
- - .zip,.rar,.msg,.vsd,.vsw,.vdx, .z{#}, .ckl,.avi,.vsdx
709
- - Artifact cannot be saved if File Name (fileName) exceeds 1,000 characters
710
- - Artifact cannot be saved if Description (description) exceeds 2,000 characters
711
- - Artifact cannot be saved if Reference Page Number (refPageNumber) exceeds 50 characters
712
- - Artifact version cannot be saved if an Artifact with the same file name already exist in the system.
713
- - Artifact cannot be saved if the file size exceeds 30MB.
714
- - Artifact cannot be saved if the Last Review Date is set in the future.
715
- ---
716
- To add (POST) artifacts use the following command:
717
-
718
- ```
719
- $ bundle exec exe/emasser post artifacts upload --systemId [value] [--isTemplate or --no-isTemplate] --type [value] --category [value] --files [value...value]
720
- ```
721
-
722
- - required parameter are:
723
-
724
- |parameter | type or values |
725
- |----------------|:----------------------------------------------------|
726
- |--systemId |Integer - Unique system identifier |
727
- |--isTemplate |Boolean - Indicates whether an artifact is a template|
728
- |--type |Possible Values: Procedure, Diagram, Policy, Labor, Document, Image, Other, Scan Result, Auditor Report|
729
- |--category |Possible Values: Implementation Guidance, Evidence |
730
- |--files |String - File names (to include path) to be uploaded into eMASS as artifacts |
731
-
732
- - optional parameter are:
733
-
734
- |parameter | type or values |
735
- |-------------------------|:------------------------------------------------------|
736
- |--description |String - Artifact description. 2000 Characters |
737
- |--refPageNumber |String - Artifact reference page number. 50 Characters |
738
- |--ccis |String - CCIs associated with artifact |
739
- |--controls |String - Control acronym associated with the artifact. NIST SP 800-53 Revision 4 defined|
740
- |--artifactExpirationDate |Date - Date Artifact expires and requires review. In Unix Date Format|
741
- |--lastReviewedDate |Date - Date Artifact was last reviewed. In Unix Date Format |
742
-
743
-
744
- **Note**
745
- For information at the command line use:
746
- ```
747
- $ bundle exec exe/emasser post artifacts help upload
748
- ```
749
- [top](#post)
750
-
751
- ### ``post cac``
752
- ----
753
- Submit control to second role of CAC
754
-
755
- Business Rule
756
- - Comments are not required at the first role of the CAC but are required at the second role of the CAC. Comments cannot exceed 10,000 characters.
757
-
758
- To add (POST) test CAC use the following command:
759
-
760
- ````
761
- $ bundle exec exe/emasser post pac add --systemId [value] --controlAcronym [value] --comments [value]
762
- ````
763
- - required parameter are:
764
-
765
- |parameter | type or values |
766
- |-------------------|:------------------------------------------------------------|
767
- |--systemId |Integer - Unique system identifier |
768
- |--controlAcronym |String - Control acronym associated with the POA&M Item. NIST SP 800-53 Revision 4 defined |
769
-
770
- - conditional parameter is:
771
-
772
- |parameter | type or values |
773
- |-------------------|:-------------------------------------------|
774
- |--comments |String -The control approval chain comments |
775
-
776
- **Note**
777
- For information at the command line use:
778
- ```
779
- $ bundle exec exe/emasser post cac help add
780
- ```
781
- [top](#post)
782
-
783
- ### ``post pac``
784
- ----
785
- Submit control to second role of CAC
786
-
787
- To add (POST) test PAC use the following command:
788
-
789
- ````
790
- $ bundle exec exe/emasser post pac add --systemId [value] --workflow [value] --name [value] --comments [value]
791
- ````
792
- - required parameter are:
793
-
794
- |parameter | type or values |
795
- |--------------|:--------------------------------------------------------------------------|
796
- |--systemId |Integer - Unique system identifier |
797
- |--workflow |Possible Values: Assess and Authorize, Assess Only, Security Plan Approval |
798
- |--name |String - Package name. 100 Characters |
799
- |--comments |String - Comments submitted upon initiation of the indicated workflow, 4,000 character|
800
-
801
- **Note**
802
- For information at the command line use:
803
- ```
804
- $ bundle exec exe/emasser post pac help add
805
- ```
806
- [top](#post)
807
-
808
- ### ``post static_code_scan``
809
- ----
810
- To add (POST) static code scans use the following command:
811
-
812
- ````
813
- $ bundle exec exe/emasser post scan_findings add --systemId [value] --applicationName [value] --version [value] --codeCheckName [value] --scanDate [value] --cweId [value]
814
- ````
815
- - required parameter are:
816
-
817
- |parameter | type or values |
818
- |-------------------|:-----------------------------------------------------------|
819
- |--systemId |Integer - Unique system identifier |
820
- |--applicationName |String - Name of the software application that was assessed |
821
- |--version |String - The version of the application |
822
- |--codeCheckName |Strings - Name of the software vulnerability or weakness |
823
- |--scanDate |Date - The findings scan date - Unix time format |
824
- |--cweId |String - The Common Weakness Enumerator (CWE) identifier |
825
-
826
- - optional parameters are:
827
-
828
- |parameter | type or values |
829
- |-------------------|:------------------------------------------------------|
830
- |--rawSeverity* |Possible Values: Low, Medium, Moderate, High, Critical |
831
- |--count |Integer - Number of instances observed for a specified |
832
-
833
- *rawSeverity: In eMASS, values of "Critical" will appear as "Very High", and values of "Medium" will appear as "Moderate". Any values not listed as options in the list above will map to "Unknown" and appear as blank values.
834
-
835
- To clear (POST) static code scans use the following command:
836
-
837
- ````
838
- $ bundle exec exe/emasser post scan_findings clear --systemId [value] --applicationName [value] --version [value] --clearFindings
839
- ````
840
- - required parameter are:
841
-
842
- |parameter | type or values |
843
- |-------------------|:-----------------------------------------------------------|
844
- |--systemId |Integer - Unique system identifier |
845
- |--applicationName |String - Name of the software application that was assessed |
846
- |--clearFindings* |Boolean - To clear an application's findings set it to true |
847
-
848
- *The clearFindings field is an optional field, but required with a value of "True" to clear out all application findings for a single application/version pairing.
849
-
850
- **Note**
851
- For information at the command line use:
852
- ```
853
- $ bundle exec exe/emasser post scan_findings help add
854
- ```
855
- [top](#post)
856
-
857
- ### ```post cloud_resource```
858
- ---
859
-
860
- The following Cloud Resource parameters/fields have the following character limitations:
861
- - Fields that can not exceed 50 characters:
862
- - Policy Deployment Version (`policyDeploymentVersion`)
863
- - Fields that can not exceed 100 characters:
864
- - Assessment Procedure (`assessmentProcedure`)
865
- - Security Control Acronym (`control`)
866
- - CSP Account ID (`cspAccountId`)
867
- - CSP Region (`cspRegion`)
868
- - Email of POC (`initiatedBy`)
869
- - Cloud Service Provider (`provider`)
870
- - Type of Cloud resource (`resourceType`)
871
- - Fields that can not exceed 500 characters:
872
- - CSP/Resource’s Policy ID (`cspPolicyDefinitionId`)
873
- - Policy Deployment Name (`policyDeploymentName`)
874
- - Policy Compliance ID (`resourceId`)
875
- - Cloud Resource Name (`resourceName`)
876
- - Fields that can not exceed 1000 characters:
877
- - Reason for Compliance (`complianceReason`)
878
- - Fields that can not exceed 2000 characters:
879
- - Policy Short Title (`policyDefinitionTitle`)
880
-
881
- To add a cloud resource and their scan results in the assets module for a system use the following command:
882
- ````
883
- $ bundle exec exe/emasser post cloud_resource add --systemId [value] --provider [value] --resourceId [value] --resourceName [value] --resourceType [value] --cspPolicyDefinitionId [value] --isCompliant or --is-not-Compliant --policyDefinitionTitle [value] --test [value]
884
- ````
885
- - required parameter are:
886
-
887
- |parameter | type or values |
888
- |------------------------|:--------------------------------------------------------------------------|
889
- |--systemId |Integer - Unique system identifier |
890
- |--provider |string - Cloud service provider name |
891
- |--resourceId |String - Unique identifier/resource namespace for policy compliance result |
892
- |--resourceName |String - Friendly name of Cloud resource |
893
- |--resourceType |String - Type of Cloud resource |
894
- |--cspPolicyDefinitionId |String - Unique identifier/compliance namespace for CSP/Resource\'s policy definition/compliance check|
895
- |--isCompliant | Boolean - Compliance status of the policy for the identified cloud resource |
896
- |--policyDefinitionTitle | String - Friendly policy/compliance check title. Recommend short title |
897
-
898
- - optional parameters are:
899
-
900
- |parameter | type or values |
901
- |-------------------|:------------------------------------------------------|
902
- |--initiatedBy |String - Person initiating the process email address |
903
- |--cspAccountId |String - System/owner\'s CSP account ID/number |
904
- |--cspRegion |String - CSP region of system |
905
- |--isBaseline |Boolean - Flag that indicates in results is a baseline |
906
- |Tags Object (tags)|
907
- |--text | String - Text that specifies the tag type |
908
- |Compliance Results Array Objects (complianceResults)|
909
- |--assessmentProcedure |String - Comma separated correlation to Assessment Procedure (i.e. CCI number for DoD Control Set) |
910
- |--complianceCheckTimestamp |Date - The compliance check date - Unix time format |
911
- |--complianceReason |String - Reason/comments for compliance result |
912
- |--control |String - Comma separated correlation to Security Control (e.g. exact NIST Control acronym) |
913
- |--policyDeploymentName |String - Name of policy deployment |
914
- |--policyDeploymentVersion |String - Version of policy deployment |
915
- |--severity |Possible Values: Low, Medium, High, Critical |
916
-
917
-
918
- **Note**
919
- For information at the command line use:
920
- ```
921
- $ bundle exec exe/emasser post cloud_resource help add
922
- ```
923
-
924
- [top](#post)
925
-
926
-
927
- ### ```post container```
928
- ---
929
- The following Container parameters/fields have the following character limitations:
930
- - Fields that can not exceed 100 characters:
931
- - STIG Benchmark ID (`benchmark`)
932
- - Container Namespace (`namespace`)
933
- - Kubernetes assigned IP (`podIp`)
934
- - Kubernetes Pod Name) (`podName`)
935
- - Fields that can not exceed 500 characters:
936
- - Container ID (`containerId`)
937
- - Friendly Container Name (`containerName`)
938
- - Fields that can not exceed 1000 characters:
939
- - Result Comments (`message`)
940
-
941
-
942
-
943
- To add containers and their scan results in the assets module for a system use the following command:
944
- ````
945
- $ bundle exec ruby exe/emasser post container add --systemId [value] --containerId [value] --containerName [value] --time [value] --benchmark [value] --lastSeen [value] --ruleId [value] --status [value]
946
-
947
- ````
948
-
949
- - required parameter are:
950
-
951
- |parameter | type or values |
952
- |------------------------|:--------------------------------------------------------------------------|
953
- |--systemId |Integer - Unique system identifier |
954
- |--containerId |String - Unique identifier of the container |
955
- |--containerName |String - Friendly name of the container |
956
- |--time |Date - Datetime of scan/result. Unix date format |
957
- |Bench Marks Object (benchmarks)|
958
- |--benchmark |String - Identifier of the benchmark/grouping of compliance results |
959
- |benchmarks.results |Object
960
- |--ruleId |String - Identifier for the compliance result, vulnerability, etc.
961
- |--status |String - Benchmark result status
962
- |--lastSeen |Date - Date last seen, Unix date format
963
-
964
- - optional parameters are:
965
-
966
- |parameter | type or values |
967
- |----------------------------|:------------------------------------------------------|
968
- |--podName |String - Name of pod (e.g. Kubernetes pod) |
969
- |--podIp |String - IP address of pod |
970
- |--namespace |String - Namespace of container in container orchestration (e.g. Kubernetes namespace)|
971
- |Tags Object (tags)|
972
- |--text | String - Text that specifies the tag type |
973
- |Bench Marks Object (benchmarks)
974
- |--isBaseline |Boolean - True/false flag for providing results as baseline. If true, all existing compliance results for the provided benchmark within the container will be replaced by results in the current call|
975
- |benchmarks.results |Object
976
- |--message |String - Comments for the result
977
-
978
- **Note**
979
- For information at the command line use:
980
- ```
981
- $ bundle exec exe/emasser post container help add
982
- ```
983
- [top](#post)
984
-
985
- ## Usage - PUT
986
-
987
- ### ``put controls``
988
-
989
- ----
990
- Business Rules
991
-
992
- The following fields are required based on the value of the `implementationStatus` field
993
-
994
- |Value |Required Fields
995
- |------------------------|--------------------------------------------------------
996
- |Planned or Implemented |controlDesignation, estimatedCompletionDate, responsibleEntities, slcmCriticality, slcmFrequency, slcmMethod, slcmMethod, slcmTracking, slcmComments
997
- |Not Applicable |naJustification, controlDesignation, responsibleEntities
998
- |Manually Inherited |controlDesignation, estimatedCompletionDate, responsibleEntities, slcmCriticality, slcmFrequency, slcmMethod, slcmMethod, slcmTracking, slcmComments
999
-
1000
- Implementation Plan cannot be updated if a Security Control is "Inherited" except for the following fields:
1001
- - Common Control Provider (commonControlProvider)
1002
- - Security Control Designation (controlDesignation)
1003
-
1004
- The following parameters/fields have the following character limitations:
1005
- - Implementation Plan information cannot be saved if the fields below exceed 2,000 character limits:
1006
- - N/A Justification (`naJustification`)
1007
- - Responsible Entities (`responsibleEntities`)
1008
- - Implementation Narrative (`implementationNarrative`)
1009
- - Criticality (`slcmCriticality`)
1010
- - Reporting (`slcmReporting`)
1011
- - Tracking (`slcmTracking`)
1012
- - Vulnerability Summary (`vulnerabilitySummary`)
1013
- - Recommendations (`recommendations`)
1014
- - Implementation Plan information cannot be saved if the fields below exceed 4,000 character limits:
1015
- - SLCM Comments (`slcmComments`)
1016
-
1017
- Implementation Plan information cannot be updated if Security Control does not exist in the system record.
1018
-
1019
- ---
1020
- Updating (PUT) a Control can be accomplished by invoking the following command:
1021
- ````
1022
- $ bundle exec exe/emasser put controls update [PARAMETERS]
1023
- ````
1024
- - required parameter are:
1025
-
1026
- |parameter | type or values |
1027
- |--------------------------|:-------------------------------------------------------------------------|
1028
- |--systemId |Integer - Unique system identifier |
1029
- |--acronym |String - The system acronym(s) e.g "AC-1, AC-2" |
1030
- |--responsibleEntities |String - Description of the responsible entities for the Security Control |
1031
- |--controlDesignation |Possible values: Common, System-Specific, or Hybrid |
1032
- |--estimatedCompletionDate |Date - Unix time format (e.g. 1499990400) |
1033
- |--comments |String - Security control comments |
1034
-
1035
- - optional parameters are:
1036
-
1037
- |parameter | type or values |
1038
- |-----------------------|:----------------------------------------------|
1039
- |--implementationStatus |Possible values: Planned, Implemented, Inherited, Not Applicable, or Manually Inherited|
1040
- |--severity |Possible values: Very Low, Low, Moderate, High, Very High |
1041
- |--vulnerabiltySummary |String - The security control vulnerability summary |
1042
- |--recommendations |String - The security control vulnerability recommendation |
1043
- |--relevanceOfThreat |Possible values: Very Low, Low, Moderate, High, Very High |
1044
- |--likelihood |Possible values: Very Low, Low, Moderate, High, Very High |
1045
- |--impact |Possible values: Very Low, Low, Moderate, High, Very High |
1046
- |--impactDescription |String, - Description of the security control impact |
1047
- |--residualRiskLevel |Possible values: Very Low, Low, Moderate, High, Very High |
1048
-
1049
- - conditional parameters are:
1050
-
1051
- |parameter | type or values |
1052
- |------------------------|:----------------------------------------------|
1053
- |--commonControlProvider |Possible values: DoD, Component, Enclave|
1054
- |--naJustification |String - Justification for Security Controls deemed Not Applicable to the system |
1055
- |--slcmCriticality |String - Criticality of Security Control regarding SLCM |
1056
- |--slcmFrequency |Possible values - Constantly, Daily, Weekly, Monthly, Quarterly, Semi-Annually, Annually, or Undetermined |
1057
- |--slcmMethod |Possible values: Automated, Semi-Automated, Manual, or Undetermined |
1058
- |--slcmReporting |String - The System-Level Continuous Monitoring reporting |
1059
- |--slcmTracking |String - The System-Level Continuous Monitoring tracking |
1060
- |--slcmComments |String, - Additional comments for Security Control regarding SLCM |
1061
-
1062
- **Note**
1063
- For information at the command line use:
1064
- ```
1065
- $ bundle exec exe/emasser put controls help update
1066
- ```
1067
- [top](#put)
1068
-
1069
- ### ``put poams``
1070
-
1071
- ----
1072
- Business Rules
1073
-
1074
- The following fields are required based on the value of the `status` field
1075
-
1076
- |Value |Required Fields
1077
- |----------------|--------------------------------------------------------
1078
- |Risk Accepted |comments, resources
1079
- |Ongoing |scheduledCompletionDate, resources, milestones (at least 1)
1080
- |Completed |scheduledCompletionDate, comments, resources,
1081
- | |completionDate, milestones (at least 1)
1082
- |Not Applicable |POAM can not be created
1083
-
1084
- If a POC email is supplied, the application will attempt to locate a user already registered within the application and pre-populate any information not explicitly supplied in the request. If no such user is found, these fields are required within the request.
1085
- - pocOrganization, pocFirstName, pocLastName, pocEmail, pocPhoneNumber
1086
-
1087
- Business logic, the following rules apply when adding POA&Ms
1088
-
1089
- - POA&M Item cannot be saved if associated Security Control or AP is inherited.
1090
- - POA&M Item cannot be created manually if a Security Control or AP is Not Applicable.
1091
- - Completed POA&M Item cannot be saved if Completion Date is in the future.
1092
- - Completed POA&M Item cannot be saved if Completion Date (completionDate) is in the future.
1093
- - Risk Accepted POA&M Item cannot be saved with a Scheduled Completion Date (scheduledCompletionDate) or Milestones
1094
- - POA&M Item with a review status of "Not Approved" cannot be saved if Milestone Scheduled Completion Date exceeds POA&M Item Scheduled Completion Date.
1095
- - POA&M Item with a review status of "Approved" can be saved if Milestone Scheduled Completion Date exceeds POA&M Item Scheduled Completion Date.
1096
- - POA&M Items that have a status of "Completed" and a status of "Ongoing" cannot be saved without Milestones.
1097
- - POA&M Items that have a status of "Risk Accepted" cannot have milestones.
1098
- - POA&M Items with a review status of "Approved" that have a status of "Completed" and "Ongoing" cannot update Scheduled Completion Date.
1099
- - POA&M Items that have a review status of "Approved" are required to have a Severity Value assigned.
1100
- - POA&M Items cannot be updated if they are included in an active package.
1101
- - Archived POA&M Items cannot be updated.
1102
- - POA&M Items with a status of "Not Applicable" will be updated through test result creation.
1103
- - If the Security Control or Assessment Procedure does not exist in the system we may have to just import POA&M Item at the System Level.
1104
-
1105
-
1106
- The following parameters/fields have the following character limitations:
1107
- - POA&M Item cannot be saved if the Point of Contact fields exceed 100 characters:
1108
- - Office / Organization (pocOrganization)
1109
- - First Name (pocFirstName)
1110
- - Last Name (pocLastName)
1111
- - Email (email)
1112
- - Phone Number (pocPhoneNumber)
1113
- - POA&M Item cannot be saved if Mitigation field (mitigation) exceeds 2,000 characters.
1114
- - POA&M Item cannot be saved if Source Identifying Vulnerability field (sourceIdentVuln) exceeds 2,000 characters.
1115
- - POA&M Item cannot be saved if Comments field (comments) exceeds 2,000 characters
1116
- - POA&M Item cannot be saved if Resource field (resource) exceeds 250 characters.
1117
- - POA&M Items cannot be saved if Milestone Description (description) exceeds 2,000 characters.
1118
-
1119
-
1120
- The following POA&M parameters/fields have the following character limitations:
1121
- - Fields that can not exceed 100 characters:
1122
- - Office / Organization (`pocOrganization`)
1123
- - First Name (`pocFirstName`)
1124
- - Last Name (`pocLastName`)
1125
- - Email (`email`)
1126
- - Phone Number (`pocPhoneNumber`)
1127
- - External Unique ID (`externalUid`)
1128
- - Fields that can not exceed 250 characters:
1129
- - Resource (`resource`)
1130
- - Fields have can not exceed 2000 character:
1131
- - Vulnerability Description (`vulnerabilityDescription`)
1132
- - Source Identifying Vulnerability (`sourceIdentVuln`)
1133
- - Recommendations (`recommendations`)
1134
- - Risk Accepted Comments (`comments`)
1135
- - Milestone Description (`description`)
1136
- - Mitigation Justification (`mitigation`)
1137
-
1138
-
1139
- ---
1140
- Updating (PUT) a POA&M can be accomplished by invoking the following command:
1141
- ````
1142
- $ bundle exec exe/emasser put poams update [PARAMETERS]
1143
- ````
1144
- - required parameter are:
1145
-
1146
- |parameter | type or values |
1147
- |---------------------------|:---------------------------------------------------------------|
1148
- |--systemId |Integer - Unique system identifier |
1149
- |--displayPoamId |Integer - Globally unique identifier for individual POA&M Items |
1150
- |--status |Possible Values: Ongoing,Risk Accepted,Completed,Not Applicable |
1151
- |--vulnerabilityDescription |String - Vulnerability description for the POA&M Item |
1152
- |--sourceIdentVuln |String - Include Source Identifying Vulnerability text |
1153
- |--pocOrganization |String - Organization/Office represented |
1154
- |--resources |String - List of resources used. Character Limit = 250 |
1155
-
1156
- ** If any poc information is provided all POC fields are required. See additional details for POC fields below.
1157
-
1158
- - conditional parameters are:
1159
-
1160
- |parameter | type or values |
1161
- |--------------------------|:-----------------------------------------------------------------------|
1162
- |--milestones |JSON - see milestone format |
1163
- |--pocFirstName |String - First name of POC |
1164
- |--pocLastName |String - Last name of POC |
1165
- |--pocEmail |String - Email address of POC |
1166
- |--pocPhoneNumber |String - Phone number of POC (area code) ***-**** format |
1167
- |--severity |Possible values - Very Low, Low, Moderate, High, Very High |
1168
- |--scheduledCompletionDate |Date - Required for ongoing and completed POA&M items. Unix time format |
1169
- |--completionDate |Date - Field is required for completed POA&M items. Unix time format |
1170
- |--comments |String - Field is required for completed and risk accepted POA&M items |
1171
- |--isActive |Boolean - Used to delete milestones when updating a POA&M |
1172
-
1173
- ** If a POC email is supplied, the application will attempt to locate a user already registered within the application and pre-populate any information not explicitly supplied in the request. If no such user is found, these fields are required within the request:
1174
- pocFirstName, pocLastName, pocPhoneNumber
1175
-
1176
- Milestone Format:
1177
- - --milestone milestoneId:[value] description:[value] scheduledCompletionDate:[value]
1178
- - If a milestoneId is not provide a new milestone is created
1179
-
1180
- - optional parameters are:
1181
-
1182
- |parameter | type or values |
1183
- |--------------------|:-----------------------------------------------------------------------------------------|
1184
- |--externalUid |String - External unique identifier for use with associating POA&M Items |
1185
- |--controlAcronym |String - Control acronym associated with the POA&M Item. NIST SP 800-53 Revision 4 defined|
1186
- |--cci |String - CCI associated with the test result |
1187
- |--securityChecks |String - Security Checks that are associated with the POA&M |
1188
- |--rawSeverity |Possible values: I, II, III |
1189
- |--relevanceOfThreat |Possible values: Very Low, Low, Moderate, High, Very High |
1190
- |--likelihood |Possible values: Very Low, Low, Moderate, High, Very High |
1191
- |--impact |Possible values: Very Low, Low, Moderate, High, Very High |
1192
- |--impactDescription |String - Include description of Security Control’s impact |
1193
- |--residualRiskLevel |Possible values: Very Low, Low, Moderate, High, Very High |
1194
- |--recommendations |String - Include recommendations |
1195
- |--mitigation |String - Include mitigation explanation. 2000 Characters |
1196
-
1197
- **Note**
1198
- For information at the command line use:
1199
- ```
1200
- $ bundle exec exe/emasser put poams help update
1201
- ```
1202
- [top](#put)
1203
-
1204
- ### ``put milestones``
1205
-
1206
- ----
1207
-
1208
- To add (POST) milestones in a system for one or more POA&M items use the following command:
1209
-
1210
- ````
1211
- $ bundle exec exe/emasser put milestones update [PARAMETERS]
1212
- ````
1213
- - required parameter are:
1214
-
1215
- |parameter | type or values |
1216
- |---------------------------|:----------------------------------------------------|
1217
- |--systemId |Integer - Unique system identifier |
1218
- |--poamId |Integer - Unique poam identifier |
1219
- |--milestoneId |Integer - Unique milestone identifier |
1220
- |--description |String - Milestone item description. 2000 Characters |
1221
- |--scheduledCompletionDate |Date - Schedule completion date. Unix date format |
1222
-
1223
-
1224
- **Note**
1225
- For information at the command line use:
1226
- ```
1227
- $ bundle exec exe/emasser put milestones help update
1228
- ```
1229
- [top](#put)
1230
-
1231
- ### ``put artifacts``
1232
-
1233
- ----
1234
- Business Rules
1235
-
1236
- - Artifact cannot be saved if the file does not have the following file extensions:
1237
- - .docx,.doc,.txt,.rtf,.xfdl,.xml,.mht,.mhtml,.html,.htm,.pdf
1238
- - .mdb,.accdb,.ppt,.pptx,.xls,.xlsx,.csv,.log
1239
- - .jpeg,.jpg,.tiff,.bmp,.tif,.png,.gif
1240
- - .zip,.rar,.msg,.vsd,.vsw,.vdx, .z{#}, .ckl,.avi,.vsdx
1241
- - Artifact cannot be saved if File Name (fileName) exceeds 1,000 characters
1242
- - Artifact cannot be saved if Description (description) exceeds 2,000 characters
1243
- - Artifact cannot be saved if Reference Page Number (refPageNumber) exceeds 50 characters
1244
- - Artifact cannot be saved if the file does not have an allowable file extension/type.
1245
- - Artifact version cannot be saved if an Artifact with the same file name already exist in the system.
1246
- - Artifact cannot be saved if the file size exceeds 30MB.
1247
- - Artifact cannot be saved if the Last Review Date is set in the future.
1248
-
1249
- To add (POST) milestones in a system for one or more POA&M items use the following command:
1250
-
1251
- ````
1252
- $ bundle exec exe/emasser put artifacts update [PARAMETERS]
1253
- ````
1254
- - required parameter are:
1255
-
1256
- |parameter | type or values |
1257
- |----------------|:----------------------------------------------------|
1258
- |--systemId |Integer - Unique system identifier |
1259
- |--filename |String - File name should match exactly one file within the provided zip file|
1260
- | |Binary - Application/zip file. Max 30MB per artifact |
1261
- |--isTemplate |Boolean - Indicates whether an artifact is a template|
1262
- |--type* |Possible Values: Procedure, Diagram, Policy, Labor, Document, Image, Other, Scan Result, Auditor Report|
1263
- |--category* |Possible Values: Implementation Guidance, Evidence |
1264
-
1265
- *May also accept custom artifact category values set by system administrators.
1266
-
1267
- - optional parameter are:
1268
-
1269
- |parameter | type or values |
1270
- |-------------------------|:------------------------------------------------------|
1271
- |--description |String - Artifact description. 2000 Characters |
1272
- |--refPageNumber |String - Artifact reference page number. 50 Characters |
1273
- |--ccis |String - CCIs associated with artifact |
1274
- |--controls |String - Control acronym associated with the artifact. NIST SP 800-53 Revision 4 defined|
1275
- |--artifactExpirationDate |Date - Date Artifact expires and requires review. In Unix Date Format|
1276
- |--lastReviewedDate |Date - Date Artifact was last reviewed. In Unix Date Format |
1277
-
1278
-
1279
- **Note**
1280
- For information at the command line use:
1281
- ```
1282
- $ bundle exec exe/emasser put artifacts help update
1283
- ```
1284
- [top](#put)
1285
-
1286
- ## Usage - DELETE
1287
-
1288
- ### ``delete poams``
1289
-
1290
- ----
1291
- Remove one or many poa&m items in a system
1292
-
1293
- To remove (DELETE) one or more POA&M items use the following command:
1294
- ```
1295
- bundle exec exe/emasser delete poams remove --systemId [value] --poamId [value]
1296
- ```
1297
- [top](#delete)
1298
-
1299
- ### ``delete milestones``
1300
-
1301
- ----
1302
- Remove milestones in a system for one or many POA&M items
1303
-
1304
- To delete a milestone the record must be inactive by having the field isActive set to false (isActive=false).
1305
-
1306
- The server returns an empty object upon successfully deleting a milestone.
1307
-
1308
- The last milestone can not be deleted, at-least on must exist.
1309
-
1310
- To remove (DELETE) one or more Milestones in a system use the following command:
1311
- ```
1312
- bundle exec exe/emasser delete milestones remove--systemId [value] --poamId [value] --milestoneId [value]
1313
- ```
1314
- [top](#delete)
1315
-
1316
- ### ``delete artifacts``
1317
-
1318
- ---
1319
- Remove one or many artifacts in a system
1320
-
1321
- Provide single file or a space/comma delimited list of file names to be removed from the system (systemId)
1322
-
1323
- To remove (DELETE) one or more Artifacts from a system use the following command:
1324
- ```
1325
- bundle exec exe/emasser delete artifacts remove --systemId [value] --files [value]
1326
- or
1327
- bundle exec exe/emasser delete artifacts remove --systemId [value] --files [value value...]
1328
- or
1329
- bundle exec exe/emasser delete artifacts remove --systemId [value] --files [value, value...]
1330
- ```
1
+ # emasser CLI Features
2
+
3
+ ## Environment Variables
4
+ To facilitate setting the required environment variables the `emasser `CLI utilized the zero-dependency module to load these variables from a `.env` file.
5
+
6
+ ### Configuring the `.env` File
7
+ An `.env-example` file is provided with the required and optional fields.
8
+
9
+ Modify the `.env_example` as necessary and save it as a `.env` file.
10
+
11
+ Place the file on the path where the `emasser` command is executed.
12
+
13
+ ### Required and Optional Environment Variables
14
+ The following environment variables are required:
15
+ * EMASSER_API_KEY_API_KEY=`<API key>`
16
+ * EMASSER_API_KEY_USER_UID=`<unique identifier for the API Key (EMASSER_API_KEY_API_KEY)`
17
+ * EMASSER_HOST=`<FQDN of the eMASS server>`
18
+ * EMASSER_KEY_FILE_PATH=`<path to your eMASS key in PEM format>`
19
+ * EMASSER_CERT_FILE_PATH=`<path to your eMASS certificate in PEM format>`
20
+ * EMASSER_KEY_PASSWORD=`<password for the key given in EMASSER_KEY_FILE_PATH>`
21
+
22
+ The following environment variables are *optional:
23
+ * EMASSER_CLIENT_SIDE_VALIDATION=`<client side validation - true or false (default true)>`
24
+ * EMASSER_VERIFY_SSL=`<verify SSL - true or false (default true)>`
25
+ * EMASSER_VERIFY_SSL_HOST=`<verify host SSL - true or false (default true)>`
26
+ * EMASSER_DEBUGGING=`<set debugging - true or false (default false)>`
27
+ * EMASSER_CLI_DISPLAY_NULL=`<display null value fields - true or false (default true)>`
28
+ * EMASSER_POCH_TO_DATETIME=`<convert epoch to data/time value - true or false (default false)>`
29
+
30
+ \* If not provided defaults are used
31
+
32
+ The proper format to set these variables in the `.env` files is as follows:
33
+ ```bash
34
+ export [VARIABLE_NAME]='value'
35
+ ```
36
+ ***NOTE***
37
+ `emasser` requires authentication to an eMASS instance as well as authorization to use the eMASS API. This authentication and authorization is **not** a function of `emasser` and needs to be accomplished with the eMASS instances owner organization. Further information about eMASS credential requirements refer to [Defense Counterintelligence and Security Agency](https://www.dcsa.mil/is/emass/) about eMASS access.
38
+
39
+ ---
40
+ ## Common emasser Endpoint Requests Information
41
+ - To invoke any boolean parameters use --parameterName for TRUE and --no-parameterName for FALSE
42
+ - The eMASS API provides the capability of updating multiple entries within several endpoints, however the `emasser` CLI, in some cases only supports updating one entry at the time.
43
+
44
+ ## Invoking emasser CLI Commands
45
+
46
+ The CLI invoke commands listed in this document shows them when executing from the source code (after a pull from GitHub). Please reference the [`emasser` README](https://mitre.github.io/emasser/) on how to invoke the CLI using other available executables (gem or docker).
47
+
48
+ ## API Endpoints Provided
49
+
50
+ ### GET
51
+ * [/api](#get-test-connection)
52
+ * [/api/system](#get-system)
53
+ * [/api/systems](#get-systems)
54
+ * [/api/systems/{systemId}](#get-system)
55
+ * [/api/system-roles](#get-roles)
56
+ * [/api/system-roles/{roleCategory}](#get-roles)
57
+ * [/api/systems/{systemId}/controls](#get-controls)
58
+ * [/api/systems/{systemId}/test-results](#get-testresults)
59
+ * [/api/systems/{systemId}/poams](#get-poams)
60
+ * [/api/systems/{systemId}/poams/{poamId}](#get-poams)
61
+ * [/api/systems/{systemId}/poams/{poamId}/milestones](#get-milestones)
62
+ * [/api/systems/{systemId}/poams/{poamId}/milestones/{milestoneId})](#get-milestones)
63
+ * [/api/systems/{systemId}/artifacts](#get-artifacts)
64
+ * [/api/systems/{systemId}/artifacts-export](#get-artifacts)
65
+ * [/api/systems/{systemId}/approval/cac](#get-cac)
66
+ * [/api/systems/{systemId}/approval/pac](#get-pac)
67
+ * [/api/cmmc-assessments](#get-cmmc)
68
+ * [/api/workflow-definitions](#get-workflow_definitions)
69
+ * [/api/systems/{systemId}/workflow-instances](#get-workflow_instances)
70
+ * [/api/dashboards/system-status-details](#get-dashboards)
71
+ * [/api/dashboards/system-control-compliance-summary](#get-dashboards)
72
+ * [/api/dashboards/system-security-controls-details](#get-dashboards)
73
+ * [/api/dashboards/system-assessment-procedures-details](#get-dashboards)
74
+ * [/api/dashboards/system-poam-summary](#get-dashboards)
75
+ * [/api/dashboards/system-poam-details](#get-dashboards)
76
+ * [/api/dashboards/system-hardware-summary](#get-dashboards)
77
+ * [/api/dashboards/system-hardware-details](#get-dashboards)
78
+ * [/api/dashboards/system-associations-details](#get-dashboards)
79
+ * [/api/dashboards/user-system-assignments-details](#get-dashboards)
80
+ * [/api/dashboards/system-privacy-summary](#get-dashboards)
81
+ * [/api/dashboards/va-omb-fisma-saop-summary](#get-dashboards)
82
+ * [/api/dashboards/va-system-aa-summary](#get-dashboards)
83
+ * [/api/dashboards/va-system-a2-summary](#get-dashboards)
84
+ * [/api/dashboards/va-system-pl-109-reporting-summary](#get-dashboards)
85
+ * [/api/dashboards/va-system-fisma-inventory-summary](#get-dashboards)
86
+
87
+ ### POST
88
+ * [/api/systems/{systemId}/test-results](#post-test_results)
89
+ * [/api/systems/{systemId}/poam](#post-poams)
90
+ * [/api/systems/{systemId}/poam/{poamId}/milestones](#post-milestones)
91
+ * [/api/systems/{systemId}/artifacts](#post-artifacts)
92
+ * [/api/systems/{systemId}/approval/cac](#post-cac)
93
+ * [/api/systems/{systemId}/approval/pac](#post-pac)
94
+ * [/api/systems/{systemId}/static-code-scans](#post-static_code_scan)
95
+ * [/api/systems/{systemId}/cloud-resource-results](#post-cloudresource)
96
+ * [/api/systems/{systemId}/container-scan-results](#post-container)
97
+
98
+ ### PUT
99
+ * [/api/systems/{systemId}/controls](#put-controls)
100
+ * [/api/systems/{systemId}/poams](#put-poams)
101
+ * [/api/systems/{systemId}/poams/{poamId}/milestones](#put-milestones)
102
+ * [/api/systems/{systemId}/artifacts](#put-artifacts)
103
+
104
+ ### DELETE
105
+ * [/api/systems/{systemId}/poams](#delete-poams)
106
+ * [/api/systems/{systemId}/poams/{poamId}/milestones](#delete-milestones)
107
+ * [/api/systems/{systemId}/artifacts](#delete-artifacts)
108
+
109
+ ## Endpoints CLI help
110
+
111
+ Each CLI endpoint command has several layers of help.
112
+ - Using `help` after a `get, put, post, or delete` command lists all available endpoint calls. The following command would list all available `GET` endpoints commands.
113
+
114
+ ```bash
115
+ $ bundle exec exe/emasser get help
116
+ Commands:
117
+ emasser get artifacts # Get system Artifacts
118
+ emasser get cac # Get location of one or many controls in...
119
+ emasser get cmmc # Get CMMC assessment information
120
+ emasser get controls # Get system Controls
121
+ emasser get dashboards # Get dashboard information
122
+ emasser get help [COMMAND] # Describe subcommands or one specific su...
123
+ emasser get milestones # Get system Milestones
124
+ emasser get pac # Get status of active workflows in a system
125
+ emasser get poams # Get system Poams
126
+ emasser get roles # Get all system roles or by category Id
127
+ emasser get system # Get a system ID given name/owner, or ge...
128
+ emasser get systems # Get all systems
129
+ emasser get test # Test connection to the configured eMASS...
130
+ emasser get test_results # Get system Test Results
131
+ emasser get workflow_definitions # Get workflow definitions in a site
132
+ emasser get workflow_instances # Get workflow instance by system and/or ...
133
+ ```
134
+ - Preceding any command with `help` provides help for the command. The following command would list all available sub-commands and options for the `get artifacts` endpoint command.
135
+ ```bash
136
+ $ bundle exec exe/emasser get help artifacts
137
+ commands:
138
+ emasser get artifacts export --filename=FILENAME --systemId=N # Get artifa...
139
+ emasser get artifacts forSystem --systemId=N # Get all sy...
140
+ emasser get artifacts help [COMMAND] # Describe s...
141
+ ```
142
+ - Using `help` after any command lists all available options. The following command would list all available options for the `get artifacts export` endpoint command.
143
+ ```bash
144
+ $ bundle exec exe/emasser get artifacts help export
145
+ Usage:
146
+ emasser get artifacts export --filename=FILENAME --systemId=N
147
+
148
+ Options:
149
+ --systemId=N # A numeric value representing the system identification
150
+ --filename=FILENAME # The artifact file name
151
+ [--compress], [--no-compress] # BOOLEAN - true or false.
152
+ ```
153
+ **The same format is applicable for POST, PUT and DELETE requests as well, however there may be additional help content**
154
+
155
+
156
+ ## Usage - GET
157
+
158
+ ### ```get test connection```
159
+ ---
160
+ The Test Connection endpoint provides the ability to verify connection to the web service.
161
+
162
+ $ bundle exec exe/emasser get test connection
163
+
164
+ A return of success from the call indicates that the CLI can reach the configure server URL.
165
+ References [Required Environment Variables](#required-environment-variables) for the necessary environment variables.
166
+
167
+ [top](#api-endpoints-provided)
168
+
169
+ ### ```get system```
170
+
171
+ ---
172
+ The `get system` command is not a sanctioned eMASS endpoint, it makes use of the `get systems` endpoint with added business logic.
173
+
174
+ There are two commands provided by the get system:
175
+
176
+ - The `get system id` - returns system ID's based on the system `name` or `owner`
177
+ - The `get system byId` - returns the system content for parameter system ID
178
+
179
+ ### get system id
180
+ Retrieves a system identification based on the SYSTEM_NAME (name) or SYSTEM_OWNER (systemOwner) fields.
181
+
182
+ To invoke the `get system id` use the following command:
183
+
184
+ $ bundle exec exe/emasser get system id --system_name "system name" --system_owner "system owner"
185
+
186
+ If using a platform that has `awk` installed the following command can be used to return only the system Id:
187
+
188
+ $ bundle exec exe/emasser get system --system_name "system name" --system_owner "system owner" | awk "{ print $1 }"
189
+
190
+
191
+ ### get system byId
192
+ Retrieves the system content for provided identification (ID) number. To invoke the endpoint use the following command:
193
+
194
+ $ bundle exec exe/emasser get system byId
195
+
196
+ - required parameter is:
197
+
198
+ |parameter | type or values |
199
+ |-------------|:----------------------------------|
200
+ |--systemId |Integer - Unique system identifier |
201
+
202
+ - Optional parameters are:
203
+
204
+ |parameter | type or values |
205
+ |------------------------|:----------------------------------------|
206
+ |--includePackage |BOOLEAN - true or false |
207
+ |--policy |Possible values: diacap, rmf, reporting |
208
+
209
+ [top](#api-endpoints-provided)
210
+
211
+ ### ```get systems```
212
+
213
+ ----
214
+ To retrieve controls use the following command:
215
+ - all - Retrieves all available systems
216
+ ```
217
+ $ bundle exec exe/emasser get systems all
218
+ ```
219
+
220
+ - Optional parameters are:
221
+
222
+ |parameter | type or values |
223
+ |------------------------|:----------------------------------------------------------------------------|
224
+ |--coamsId |Cyber Operational Attributes Management System (COAMS) string Id |
225
+ |--ditprId |DoD Information Technology (IT) Portfolio Repository (DITPR) string id |
226
+ |--includeDecommissioned |BOOLEAN - true or false |
227
+ |--includeDitprMetrics |BOOLEAN - true or false |
228
+ |--includePackage |BOOLEAN - true or false |
229
+ |--policy |Possible values: diacap, rmf, reporting |
230
+ |--registrationType |Possible values: assessAndAuthorize, assessOnly, guest, regular, functional, |
231
+ | | cloudServiceProvider, commonControlProvider |
232
+ |--reportsForScorecard |BOOLEAN - true or false |
233
+
234
+ [top](#api-endpoints-provided)
235
+ ### ```get roles```
236
+
237
+ ----
238
+ There are two get endpoints for system roles:
239
+ - all - Retrieves all available roles
240
+ ```
241
+ $ bundle exec exe/emasser get roles all
242
+ ```
243
+ - byCategory - Retrieves roles based on the following required parameter:
244
+ ````
245
+ $ bundle exec exe/emasser get roles byCategory --roleCategory=ROLECATEGORY --role=ROLE
246
+ ````
247
+ - required parameters are:
248
+
249
+ |parameter | type or values |
250
+ |:---------------|:------------------------------------------|
251
+ |--roleCategory |Possible values: PAC, CAC, Other |
252
+ |--role |Possible values: AO, Auditor, Artifact Manager, C&A Team, IAO, ISSO, PM/IAM, SCA, User Rep (View Only), Validator (IV&V)|
253
+
254
+ - optional parameter are:
255
+
256
+ |parameter | type or values |
257
+ |------------------------|:----------------------------------------|
258
+ |--policy |Possible values: diacap, rmf, reporting |
259
+ |--includeDecommissioned |BOOLEAN - true or false |
260
+
261
+ [top](#api-endpoints-provided)
262
+ ### ```get controls```
263
+
264
+ ----
265
+ To retrieve controls use the following command:
266
+
267
+ $ bundle exec exe/emasser get controls forSystem --systemId=SYSTEMID
268
+
269
+ - required parameter is:
270
+
271
+ |parameter | type or values |
272
+ |-------------|:----------------------------------|
273
+ |--systemId |Integer - Unique system identifier |
274
+
275
+ - optional parameter is:
276
+
277
+ |parameter | type or values |
278
+ |-------------|:------------------------------------------|
279
+ |--acronyms |The system acronym(s) e.g "AC-1, AC-2" - if not provided all controls for systemId are returned |
280
+
281
+ [top](#api-endpoints-provided)
282
+ ### ```get test_results```
283
+
284
+ ----
285
+ To retrieve test results use the following command:
286
+
287
+ $ bundle exec exe/emasser get test_results forSystem --systemId=SYSTEMID
288
+
289
+ - required parameter is:
290
+
291
+ |parameter | type or values |
292
+ |-------------|:----------------------------------|
293
+ |--systemId |Integer - Unique system identifier |
294
+
295
+ - optional parameters are:
296
+
297
+ |parameter | type or values |
298
+ |-------------------|:------------------------------------------|
299
+ |--controlAcronyms |String - The system acronym(s) e.g "AC-1, AC-2" |
300
+ |--ccis |String - The system CCIS string numerical value |
301
+ |--latestOnly |BOOLEAN - true or false|
302
+
303
+ [top](#api-endpoints-provided)
304
+ ### ```get poams```
305
+
306
+ ----
307
+ There are two get endpoints for system poams:
308
+ - forSystem - Retrieves all poams for specified system ID
309
+ ````
310
+ $ bundle exec exe/emasser get poams forSystem --systemId=SYSTEMID
311
+ ````
312
+ - required parameter is:
313
+
314
+ |parameter | type or values |
315
+ |-------------|:----------------------------------|
316
+ |--systemId |Integer - Unique system identifier |
317
+
318
+ - optional parameters are:
319
+
320
+ |parameter | type or values |
321
+ |-------------------------------|:----------------------------------------------|
322
+ |--scheduledCompletionDateStart |Date - Unix time format (e.g. 1499644800) |
323
+ |--scheduledCompletionDateEnd |Date - Unix time format (e.g. 1499990400) |
324
+ |--controlAcronyms |String - The system acronym(s) e.g "AC-1, AC-2"|
325
+ |--ccis |String - The system CCIS string numerical value|
326
+ |--systemOnly |BOOLEAN - true or false|
327
+
328
+
329
+ - byPoamId - Retrieves all poams for specified system and poam ID
330
+ ````
331
+ $ bundle exec exe/emasser get poams byPoamId --systemId=SYSTEMID --poamId=POAMID
332
+ ````
333
+ - required parameters are:
334
+
335
+ |parameter | type or values |
336
+ |-------------|:----------------------------------|
337
+ |--systemId |Integer - Unique system identifier |
338
+ |--poamId |Integer - Unique poam identifier |
339
+
340
+ [top](#api-endpoints-provided)
341
+ ### ```get milestones```
342
+
343
+ ----
344
+ There are two get endpoints for system milestones:
345
+ - byPoamId - Retrieves milestone(s) for specified system and poam ID
346
+ ````
347
+ $ bundle exec exe/emasser get milestones byPoamId --systemId=SYSTEMID --poamId=POAMID
348
+ ````
349
+ - required parameters are:
350
+
351
+ |parameter | type or values |
352
+ |-------------|:----------------------------------|
353
+ |--systemId |Integer - Unique system identifier |
354
+ |--poamId |Integer - Unique poam identifier |
355
+
356
+ - optional parameters are:
357
+
358
+ |parameter | type or values |
359
+ |-------------------------------|:----------------------------------------------|
360
+ |--scheduledCompletionDateStart |Date - Unix time format (e.g. 1499644800) |
361
+ |--scheduledCompletionDateEnd |Date - Unix time format (e.g. 1499990400) |
362
+
363
+
364
+ - byMilestoneId, Retrieve milestone(s) for specified system, poam, and milestone ID"
365
+ ````
366
+ $ bundle exec exe/emasser get poams byMilestoneId --systemId=SYSTEMID --poamId=POAMID --milestoneId=MILESTONEID
367
+ ````
368
+ - required parameters are:
369
+
370
+ |parameter | type or values |
371
+ |--------------|:-------------------------------------|
372
+ |--systemId |Integer - Unique system identifier |
373
+ |--poamId |Integer - Unique poam identifier |
374
+ |--milestoneId |Integer - Unique milestone identifier |
375
+
376
+ [top](#api-endpoints-provided)
377
+ ### ```get artifacts```
378
+
379
+ ----
380
+ There are two get endpoints that provides the ability to view existing `Artifacts` in a system:
381
+
382
+ - forSystem - Retrieves one or many artifacts in a system specified system ID
383
+ ````
384
+ $ bundle exec exe/emasser get artifacts forSystem --systemId=SYSTEMID
385
+ ````
386
+ - required parameter is:
387
+
388
+ |parameter | type or values |
389
+ |-------------|:----------------------------------|
390
+ |--systemId |Integer - Unique system identifier |
391
+
392
+ - optional parameters are:
393
+
394
+ |parameter | type or values |
395
+ |-------------------------------|:----------------------------------------------|
396
+ |--filename |The artifact file name |
397
+ |--controlAcronyms |String - The system acronym(s) e.g "AC-1, AC-2"|
398
+ |--ccis |String - The system CCIS string numerical value|
399
+ |--systemOnly |BOOLEAN - true or false|
400
+
401
+
402
+ - export - Retrieves the file artifacts (if compress is true the file binary contents are returned, otherwise the file textual contents are returned.)
403
+ ````
404
+ $ bundle exec exe/emasser get artifacts export --systemId=SYSTEMID
405
+ ````
406
+ - required parameters are:
407
+
408
+ |parameter | type or values |
409
+ |-------------|:----------------------------------|
410
+ |--systemId |Integer - Unique system identifier |
411
+ |--filename |The artifact file name |
412
+
413
+ - optional parameter is:
414
+
415
+ |parameter | type or values |
416
+ |-------------|:----------------------------------|
417
+ |--compress |BOOLEAN - true or false. |
418
+
419
+ [top](#api-endpoints-provided)
420
+ ### ```get cac```
421
+
422
+ ----
423
+ To view one or many Control Approval Chain (CAC) in a system specified system ID use the following command:
424
+ ```
425
+ $ bundle exec exe/emasser get cac controls --systemId=SYSTEMID
426
+ ```
427
+ - required parameter is:
428
+
429
+ |parameter | type or values |
430
+ |-------------|:----------------------------------|
431
+ |--systemId |Integer - Unique system identifier |
432
+
433
+ - optional parameter is:
434
+
435
+ |parameter | type or values |
436
+ |-------------------------------|:----------------------------------------------|
437
+ |--controlAcronyms |String - The system acronym(s) e.g "AC-1, AC-2"|
438
+
439
+ [top](#api-endpoints-provided)
440
+ ### ```get pac```
441
+
442
+ ----
443
+ To view one or many Package Approval Chain (PAC) in a system specified system ID use the following command:
444
+
445
+ ````
446
+ $ bundle exec exe/emasser get pac package --systemId=SYSTEMID
447
+ ````
448
+ - required parameter is:
449
+
450
+ |parameter | type or values |
451
+ |-------------|:----------------------------------|
452
+ |--systemId |Integer - Unique system identifier |
453
+
454
+ [top](#api-endpoints-provided)
455
+ ### ```get cmmc```
456
+
457
+ ----
458
+ To view Cybersecurity Maturity Model Certification (CMMC) Assessments use the following command:
459
+
460
+ $ bundle exec exe/emasser get workflow_definitions forSite --sinceDate=SINCEDATE
461
+
462
+ - Required parameter is:
463
+
464
+ |parameter | type or values |
465
+ |----------------|:--------------------------------------|
466
+ |--sinceDate |Date - The CMMC date. Unix date format |
467
+
468
+ [top](#api-endpoints-provided)
469
+ ### ```get workflow_definitions```
470
+
471
+ ----
472
+ To view Workflow Definitions use the following command:
473
+
474
+ $ bundle exec exe/emasser get workflow_definitions forSite
475
+
476
+ - Optional parameters are:
477
+
478
+ |parameter | type or values |
479
+ |---------------------|:----------------------------------------------------------------------------|
480
+ |--includeInactive |BOOLEAN - true or false |
481
+ |--registrationType |Possible values: assessAndAuthorize, assessOnly, guest, regular, functional, |
482
+ | | cloudServiceProvider, commonControlProvider |
483
+
484
+ [top](#api-endpoints-provided)
485
+ ### ```get workflow_instances```
486
+
487
+ ----
488
+ There are two get endpoints to view workflow instances:
489
+ - all
490
+ ```
491
+ $ bundle exec exe/emasser get workflow_instances all
492
+ ```
493
+ - Optional parameters are:
494
+
495
+ |parameter | type or values |
496
+ |-------------------|:---------------------------------------------------|
497
+ |--includeComments |BOOLEAN - true or false |
498
+ |--pageIndex |Integer - The page number to query |
499
+ |--sinceDate |Date - The Workflow Instance date. Unix date format |
500
+ |--status |Possible values: active, inactive, all |
501
+
502
+ - byWorkflowInstanceId
503
+ ```
504
+ $ bundle exec exe/emasser get workflow_instances byWorkflowInstanceId --workflowInstanceId=WORKFLOWID
505
+ ```
506
+ - required parameter is:
507
+
508
+ |parameter | type or values |
509
+ |---------------------|:---------------------------------------------|
510
+ |--workflowInstanceId |Integer - Unique workflow instance identifier |
511
+
512
+ [top](#api-endpoints-provided)
513
+ ### ```get dashboards```
514
+
515
+ ----
516
+ The Dashboards endpoints provide the ability to view data contained in dashboard exports. In the eMASS front end, these dashboard exports are generated as Excel exports.
517
+
518
+ All endpoint calls utilize the same parameter values, they are:
519
+ - Required parameter is:
520
+
521
+ |parameter | type or values |
522
+ |--------------|:------------------------------------------------|
523
+ |--orgId |Integer - The organization identification number |
524
+
525
+ - Optional parameters are:
526
+
527
+ |parameter | type or values |
528
+ |-------------|:--------------------------------------------------------------|
529
+ |--pageIndex |Integer - The index of the starting page (default first page 0)|
530
+ |--pageSize |Integer - The number of entries per page (default 20000) |
531
+
532
+ Available commands are:
533
+ - Get systems status detail dashboard information
534
+ ```
535
+ $ bundle exec exe/emasser get status_details --orgId=ORGID
536
+ ```
537
+ - Get systems control compliance summary dashboard information
538
+ ```
539
+ $ bundle exec exe/emasser get control_compliance_summary --orgId=ORGID
540
+ ```
541
+ - Get systems security control details dashboard information
542
+ ```
543
+ $ bundle exec exe/emasser get security_control_details --orgId=ORGID
544
+ ```
545
+ - Get systems assessment procedures details dashboard information
546
+ ```
547
+ $ bundle exec exe/emasser get assessment_procedures_details --orgId=ORGID
548
+ ```
549
+ - Get systems POA&Ms summary dashboard information
550
+ ```
551
+ $ bundle exec exe/emasser get poam_summary --orgId=ORGID
552
+ ```
553
+ - Get system POA&Ms details dashboard information
554
+ ```
555
+ $ bundle exec exe/emasser get poam_details --orgId=ORGID
556
+ ```
557
+ - Get system hardware summary dashboard information
558
+ ```
559
+ $ bundle exec exe/emasser get hardware_summary --orgId=ORGID
560
+ ```
561
+ - Get system hardware details dashboard information
562
+ ```
563
+ $ bundle exec exe/emasser get hardware_details --orgId=ORGID
564
+ ```
565
+ - Get system associations details dashboard information
566
+ ```
567
+ $ bundle exec exe/emasser get associations_details --orgId=ORGID
568
+ ```
569
+ - Get user system assignments details dashboard information
570
+ ```
571
+ $ bundle exec exe/emasser get assignments_details --orgId=ORGID
572
+ ```
573
+ - Get user system privacy summary dashboard information
574
+ ```
575
+ $ bundle exec exe/emasser get privacy_summary --orgId=ORGID
576
+ ```
577
+ - Get VA OMB-FISMA SAOP summary dashboard information
578
+ ```
579
+ $ bundle exec exe/emasser get fisma_saop_summary --orgId=ORGID
580
+ ```
581
+ - Get VA system A&A summary dashboard information
582
+ ```
583
+ $ bundle exec exe/emasser get va_aa_summary --orgId=ORGID
584
+ ```
585
+ - Get VA system A2.0 summary dashboard information
586
+ ```
587
+ $ bundle exec exe/emasser get va_a2_summary --orgId=ORGID
588
+ ```
589
+ - Get VA System P.L. 109 reporting summary dashboard information
590
+ ```
591
+ $ bundle exec exe/emasser get va_pl_109_summary --orgId=ORGID
592
+ ```
593
+ - Get VA system FISMA inventory summary dashboard information
594
+ ```
595
+ $ bundle exec exe/emasser get fisma_inventory_summary --orgId=ORGID
596
+ ```
597
+
598
+ [top](#api-endpoints-provided)
599
+
600
+ ## Usage - POST
601
+
602
+ ### ``post test_results``
603
+ ---
604
+ Test Result add (POST) endpoint API business rules.
605
+
606
+ |Business Rule | Parameter/Field |
607
+ |---------------------------------------------------------------------|:-----------------|
608
+ | Tests Results cannot be saved if the "Test Date" is in the future. | `testDate` |
609
+ | Test Results cannot be saved if a Security Control is "Inherited" in the system record. | `description` |
610
+ | Test Results cannot be saved if an Assessment Procedure is "Inherited" in the system record. | `description` |
611
+ | Test Results cannot be saved if the AP does not exist in the system. | `description` |
612
+ | Test Results cannot be saved if the control is marked "Not Applicable" by an Overlay. | `description` |
613
+ | Test Results cannot be saved if the control is required to be assessed as "Applicable" by an Overlay.| `description` |
614
+ | Test Results cannot be saved if the Tests Results entered is greater than 4000 characters.|`description`|
615
+ | Test Results cannot be saved if the following fields are missing data: | `complianceStatus`, `testDate`, `testedBy`, `description`|
616
+ | Test results cannot be saved if there is more than one test result per CCI |`cci`|
617
+
618
+ ---
619
+ To add (POST) test results use the following command:
620
+
621
+ ````
622
+ $ bundle exec exe/emasser post test_results add --systemId [value] --cci [value] --testedBy [value] --testDate [value] --description [value] --complianceStatus [value]
623
+ ````
624
+ Note: If no POA&Ms or AP exist for the control (system), you will get this response:
625
+ "You have entered a Non-Compliant Test Result. You must create a POA&M Item for this Control and/or AP if one does not already exist."
626
+
627
+ - required parameter are:
628
+
629
+ |parameter | type or values |
630
+ |-------------------|:------------------------------------------------------------|
631
+ |--systemId |Integer - Unique system identifier |
632
+ |--cci |String - CCI associated with the test result. e.g "00221" |
633
+ |--testedBy |String - Last Name, First Name. 100 Characters. |
634
+ |--testDate |Date - Unix time format (e.g. 1499990400) |
635
+ |--description |String - Include description of test result. 4000 Characters |
636
+ |--complianceStatus |Possible values: Compliant, Non-Compliant, Not Applicable |
637
+
638
+ **Note**
639
+ For information at the command line use:
640
+ ```
641
+ $ bundle exec exe/emasser post test_results help add
642
+ ```
643
+ [top](#post)
644
+
645
+ ### ``post poams``
646
+ ---
647
+ Plan of Action and Milestones (POA&M) add (POST) endpoint API business rules.
648
+
649
+ The following fields are required based on the contents of the status field
650
+
651
+ |status |Required Fields
652
+ |----------------|--------------------------------------------------------
653
+ |Risk Accepted |comments
654
+ |Ongoing |scheduledCompletionDate, milestones (at least 1)
655
+ |Completed |scheduledCompletionDate, comments, completionDate, milestones (at least 1)
656
+ |Not Applicable |POAM can not be created
657
+
658
+ If a POC email is supplied, the application will attempt to locate a user
659
+ already registered within the application and pre-populate any information
660
+ not explicitly supplied in the request. If no such user is found, these
661
+ fields are required within the request.
662
+ - pocOrganization, pocFirstName, pocLastName, pocEmail, pocPhoneNumber
663
+
664
+ Business logic, the following rules apply when adding POA&Ms
665
+
666
+ - POA&M Items cannot be saved if associated Security Control or AP is inherited.
667
+ - POA&M Items cannot be created manually if a Security Control or AP is Not Applicable.
668
+ - Completed POA&M Item cannot be saved if Completion Date is in the future.
669
+ - Completed POA&M Item cannot be saved if Completion Date (completionDate) is in the future.
670
+ - Risk Accepted POA&M Item cannot be saved with a Scheduled Completion Date or Milestones
671
+ - POA&M Items with a review status of "Not Approved" cannot be saved if Milestone Scheduled Completion Date exceeds POA&M Item Scheduled Completion Date.
672
+ - POA&M Items with a review status of "Approved" can be saved if Milestone Scheduled Completion Date exceeds POA&M Item Scheduled Completion Date.
673
+ - POA&M Items that have a status of "Completed" and a status of "Ongoing" cannot be saved without Milestones.
674
+ - POA&M Items that have a status of "Risk Accepted" cannot have milestones.
675
+ - POA&M Items with a review status of "Approved" that have a status of "Completed" and "Ongoing" cannot update Scheduled Completion Date.
676
+ - POA&M Items that have a review status of "Approved" are required to have a Severity Value assigned.
677
+ - POA&M Items cannot be updated if they are included in an active package.
678
+ - Archived POA&M Items cannot be updated.
679
+ - POA&M Items with a status of "Not Applicable" will be updated through test result creation.
680
+ - If the Security Control or Assessment Procedure does not exist in the system we may have to just import POA&M Item at the System Level.
681
+
682
+
683
+ The following POA&M parameters/fields have the following character limitations:
684
+ - Fields that can not exceed 100 characters:
685
+ - Office / Organization (`pocOrganization`)
686
+ - First Name (`pocFirstName`)
687
+ - Last Name (`pocLastName`)
688
+ - Email (`email`)
689
+ - Phone Number (`pocPhoneNumber`)
690
+ - External Unique ID (`externalUid`)
691
+ - Fields that can not exceed 250 characters:
692
+ - Resource (`resource`)
693
+ - Fields have can not exceed 2000 character:
694
+ - Vulnerability Description (`vulnerabilityDescription`)
695
+ - Source Identifying Vulnerability (`sourceIdentVuln`)
696
+ - Recommendations (`recommendations`)
697
+ - Risk Accepted Comments (`comments`)
698
+ - Milestone Description (`description`)
699
+ - Mitigation Justification (`mitigation`)
700
+
701
+ To add (POST) POA&Ms use the following command:
702
+ ```
703
+ $ bundle exec exe/emasser post poams add --systemId [value] --status [value] --vulnerabilityDescription [value] --sourceIdentVuln [value] --pocOrganization [value] --resources [value]
704
+ ```
705
+ **Notes:**
706
+ - The above listed parameters/fields are the minimal required.
707
+ - Based on the value for the status (--status) parameter additional fields are required
708
+ - Refer to instructions listed above for conditional and optional fields requirements.
709
+ - When a milestone is required the format is:
710
+ - --milestone description:[value] scheduledCompletionDate:[value]
711
+
712
+ **If a milestone Id is provided (--milestone milestoneId:[value]) the POA&M with the provided milestone Id is updated and the new POA&M milestones is set to null.**
713
+
714
+ ---
715
+ Client API parameters/fields (required, conditional, and optional).
716
+ - required parameter are:
717
+
718
+ |parameter | type or values |
719
+ |---------------------------|:---------------------------------------------------------------|
720
+ |--systemId |Integer - Unique system identifier |
721
+ |--status |Possible Values: Ongoing,Risk Accepted,Completed,Not Applicable |
722
+ |--vulnerabilityDescription |String - Vulnerability description for the POA&M Item |
723
+ |--sourceIdentVuln |String - Include Source Identifying Vulnerability text |
724
+ |--pocOrganization |String - Organization/Office represented |
725
+ |--resources |String - List of resources used. Character Limit = 250 |
726
+
727
+ ** If any poc information is provided all POC fields are required. See additional details for POC fields below.
728
+
729
+ - conditional parameters are:
730
+
731
+ |parameter | type or values |
732
+ |--------------------------|:------------------------------------------------------------------------|
733
+ |--milestones |JSON - see milestone format |
734
+ |--pocFirstName |String - First name of POC |
735
+ |--pocLastName |String - Last name of POC |
736
+ |--pocEmail |String - Email address of POC |
737
+ |--pocPhoneNumber |String - Phone number of POC (area code) ***-**** format |
738
+ |--severity |Possible values - Very Low, Low, Moderate, High, Very High |
739
+ |--scheduledCompletionDate |Date - Required for ongoing and completed POA&M items. Unix time format |
740
+ |--completionDate |Date - Field is required for completed POA&M items. Unix time format |
741
+ |--comments |String - Field is required for completed and risk accepted POA&M items. |
742
+
743
+ ** If a POC email is supplied, the application will attempt to locate a user already registered within the application and pre-populate any information not explicitly supplied in the request. If no such user is found, these fields are required within the request:
744
+ pocFirstName, pocLastName, pocPhoneNumber
745
+
746
+ Milestone Format:
747
+ - --milestone description:[value] scheduledCompletionDate:[value]
748
+
749
+ - optional parameters are:
750
+
751
+ |parameter | type or values |
752
+ |--------------------|:-----------------------------------------------------------------------------------------|
753
+ |--externalUid |String - External unique identifier for use with associating POA&M Items |
754
+ |--controlAcronym |String - Control acronym associated with the POA&M Item. NIST SP 800-53 Revision 4 defined|
755
+ |--cci |String - CCI associated with the test result |
756
+ |--securityChecks |String - Security Checks that are associated with the POA&M |
757
+ |--rawSeverity |Possible values: I, II, III |
758
+ |--relevanceOfThreat |Possible values: Very Low, Low, Moderate, High, Very High |
759
+ |--likelihood |Possible values: Very Low, Low, Moderate, High, Very High |
760
+ |--impact |Possible values: Very Low, Low, Moderate, High, Very High |
761
+ |--impactDescription |String - Include description of Security Control’s impact |
762
+ |--residualRiskLevel |Possible values: Very Low, Low, Moderate, High, Very High |
763
+ |--recommendations |String - Include recommendations |
764
+ |--mitigation |String - Include mitigation explanation |
765
+
766
+
767
+ **Note**
768
+ For information at the command line use:
769
+ ```
770
+ $ bundle exec exe/emasser post poams help add
771
+ ```
772
+ [top](#post)
773
+
774
+ ### ``post milestones``
775
+ ---
776
+ To add (POST) milestones in a system for one or more POA&M items use the following command:
777
+
778
+ ````
779
+ $ bundle exec exe/emasser post milestones add --systemId [value] --poamId [value] --description [value] --scheduledCompletionDate [value]
780
+ ````
781
+ - required parameter are:
782
+
783
+ |parameter | type or values |
784
+ |---------------------------|:----------------------------------------------------|
785
+ |--systemId |Integer - Unique system identifier |
786
+ |--poamId |Integer - Unique item identifier |
787
+ |--description |String - Milestone item description. 2000 Characters |
788
+ |--scheduledCompletionDate |Date - Schedule completion date. Unix date format |
789
+
790
+
791
+ **Note**
792
+ For information at the command line use:
793
+ ```
794
+ $ bundle exec exe/emasser post milestones help add
795
+ ```
796
+ [top](#post)
797
+
798
+ ### ``post artifacts``
799
+ ---
800
+ The add (POST) artifacts endpoint accepts a single binary file with file extension.zip only. The command line (CI) reads the files provided and zips them before sending to eMASS.
801
+
802
+ ```
803
+ If no artifact is matched via filename to the application, a new artifact will be created with the following default values. Any values not specified below will be blank.
804
+ - isTemplate: false
805
+ - type: other
806
+ - category: evidence
807
+ ```
808
+
809
+ Business Rules:
810
+ - Artifact cannot be saved if the file does not have the following file extensions:
811
+ - .docx,.doc,.txt,.rtf,.xfdl,.xml,.mht,.mhtml,.html,.htm,.pdf
812
+ - .mdb,.accdb,.ppt,.pptx,.xls,.xlsx,.csv,.log
813
+ - .jpeg,.jpg,.tiff,.bmp,.tif,.png,.gif
814
+ - .zip,.rar,.msg,.vsd,.vsw,.vdx, .z{#}, .ckl,.avi,.vsdx
815
+ - Artifact cannot be saved if File Name (fileName) exceeds 1,000 characters
816
+ - Artifact cannot be saved if Description (description) exceeds 2,000 characters
817
+ - Artifact cannot be saved if Reference Page Number (refPageNumber) exceeds 50 characters
818
+ - Artifact version cannot be saved if an Artifact with the same file name already exist in the system.
819
+ - Artifact cannot be saved if the file size exceeds 30MB.
820
+ - Artifact cannot be saved if the Last Review Date is set in the future.
821
+ ---
822
+ To add (POST) artifacts use the following command:
823
+
824
+ ```
825
+ $ bundle exec exe/emasser post artifacts upload --systemId [value] [--isTemplate or --no-isTemplate] --type [value] --category [value] --files [value...value]
826
+ ```
827
+
828
+ - required parameter are:
829
+
830
+ |parameter | type or values |
831
+ |----------------|:----------------------------------------------------|
832
+ |--systemId |Integer - Unique system identifier |
833
+ |--isTemplate |Boolean - Indicates whether an artifact is a template|
834
+ |--type |Possible Values: Procedure, Diagram, Policy, Labor, Document, Image, Other, Scan Result, Auditor Report|
835
+ |--category |Possible Values: Implementation Guidance, Evidence |
836
+ |--files |String - File names (to include path) to be uploaded into eMASS as artifacts |
837
+
838
+ - optional parameter are:
839
+
840
+ |parameter | type or values |
841
+ |-------------------------|:------------------------------------------------------|
842
+ |--description |String - Artifact description. 2000 Characters |
843
+ |--refPageNumber |String - Artifact reference page number. 50 Characters |
844
+ |--ccis |String - CCIs associated with artifact |
845
+ |--controls |String - Control acronym associated with the artifact. NIST SP 800-53 Revision 4 defined|
846
+ |--artifactExpirationDate |Date - Date Artifact expires and requires review. In Unix Date Format|
847
+ |--lastReviewedDate |Date - Date Artifact was last reviewed. In Unix Date Format |
848
+
849
+
850
+ **Note**
851
+ For information at the command line use:
852
+ ```
853
+ $ bundle exec exe/emasser post artifacts help upload
854
+ ```
855
+ [top](#post)
856
+
857
+ ### ``post cac``
858
+ ----
859
+ Submit control to second role of CAC
860
+
861
+ Business Rule
862
+ - Comments are not required at the first role of the CAC but are required at the second role of the CAC. Comments cannot exceed 10,000 characters.
863
+
864
+ To add (POST) test CAC use the following command:
865
+
866
+ ````
867
+ $ bundle exec exe/emasser post pac add --systemId [value] --controlAcronym [value] --comments [value]
868
+ ````
869
+ - required parameter are:
870
+
871
+ |parameter | type or values |
872
+ |-------------------|:------------------------------------------------------------|
873
+ |--systemId |Integer - Unique system identifier |
874
+ |--controlAcronym |String - Control acronym associated with the POA&M Item. NIST SP 800-53 Revision 4 defined |
875
+
876
+ - conditional parameter is:
877
+
878
+ |parameter | type or values |
879
+ |-------------------|:-------------------------------------------|
880
+ |--comments |String -The control approval chain comments |
881
+
882
+ **Note**
883
+ For information at the command line use:
884
+ ```
885
+ $ bundle exec exe/emasser post cac help add
886
+ ```
887
+ [top](#post)
888
+
889
+ ### ``post pac``
890
+ ----
891
+ Submit control to second role of CAC
892
+
893
+ To add (POST) test PAC use the following command:
894
+
895
+ ````
896
+ $ bundle exec exe/emasser post pac add --systemId [value] --workflow [value] --name [value] --comments [value]
897
+ ````
898
+ - required parameter are:
899
+
900
+ |parameter | type or values |
901
+ |--------------|:--------------------------------------------------------------------------|
902
+ |--systemId |Integer - Unique system identifier |
903
+ |--workflow |Possible Values: Assess and Authorize, Assess Only, Security Plan Approval |
904
+ |--name |String - Package name. 100 Characters |
905
+ |--comments |String - Comments submitted upon initiation of the indicated workflow, 4,000 character|
906
+
907
+ **Note**
908
+ For information at the command line use:
909
+ ```
910
+ $ bundle exec exe/emasser post pac help add
911
+ ```
912
+ [top](#post)
913
+
914
+ ### ``post static_code_scan``
915
+ ----
916
+ To add (POST) static code scans use the following command:
917
+
918
+ ````
919
+ $ bundle exec exe/emasser post scan_findings add --systemId [value] --applicationName [value] --version [value] --codeCheckName [value] --scanDate [value] --cweId [value]
920
+ ````
921
+ - required parameter are:
922
+
923
+ |parameter | type or values |
924
+ |-------------------|:-----------------------------------------------------------|
925
+ |--systemId |Integer - Unique system identifier |
926
+ |--applicationName |String - Name of the software application that was assessed |
927
+ |--version |String - The version of the application |
928
+ |--codeCheckName |Strings - Name of the software vulnerability or weakness |
929
+ |--scanDate |Date - The findings scan date - Unix time format |
930
+ |--cweId |String - The Common Weakness Enumerator (CWE) identifier |
931
+
932
+ - optional parameters are:
933
+
934
+ |parameter | type or values |
935
+ |-------------------|:------------------------------------------------------|
936
+ |--rawSeverity* |Possible Values: Low, Medium, Moderate, High, Critical |
937
+ |--count |Integer - Number of instances observed for a specified |
938
+
939
+ *rawSeverity: In eMASS, values of "Critical" will appear as "Very High", and values of "Medium" will appear as "Moderate". Any values not listed as options in the list above will map to "Unknown" and appear as blank values.
940
+
941
+ To clear (POST) static code scans use the following command:
942
+
943
+ ````
944
+ $ bundle exec exe/emasser post scan_findings clear --systemId [value] --applicationName [value] --version [value] --clearFindings
945
+ ````
946
+ - required parameter are:
947
+
948
+ |parameter | type or values |
949
+ |-------------------|:-----------------------------------------------------------|
950
+ |--systemId |Integer - Unique system identifier |
951
+ |--applicationName |String - Name of the software application that was assessed |
952
+ |--clearFindings* |Boolean - To clear an application's findings set it to true |
953
+
954
+ *The clearFindings field is an optional field, but required with a value of "True" to clear out all application findings for a single application/version pairing.
955
+
956
+ **Note**
957
+ For information at the command line use:
958
+ ```
959
+ $ bundle exec exe/emasser post scan_findings help add
960
+ ```
961
+ [top](#post)
962
+
963
+ ### ```post cloud_resource```
964
+ ---
965
+
966
+ The following Cloud Resource parameters/fields have the following character limitations:
967
+ - Fields that can not exceed 50 characters:
968
+ - Policy Deployment Version (`policyDeploymentVersion`)
969
+ - Fields that can not exceed 100 characters:
970
+ - Assessment Procedure (`assessmentProcedure`)
971
+ - Security Control Acronym (`control`)
972
+ - CSP Account ID (`cspAccountId`)
973
+ - CSP Region (`cspRegion`)
974
+ - Email of POC (`initiatedBy`)
975
+ - Cloud Service Provider (`provider`)
976
+ - Type of Cloud resource (`resourceType`)
977
+ - Fields that can not exceed 500 characters:
978
+ - CSP/Resource’s Policy ID (`cspPolicyDefinitionId`)
979
+ - Policy Deployment Name (`policyDeploymentName`)
980
+ - Policy Compliance ID (`resourceId`)
981
+ - Cloud Resource Name (`resourceName`)
982
+ - Fields that can not exceed 1000 characters:
983
+ - Reason for Compliance (`complianceReason`)
984
+ - Fields that can not exceed 2000 characters:
985
+ - Policy Short Title (`policyDefinitionTitle`)
986
+
987
+ To add a cloud resource and their scan results in the assets module for a system use the following command:
988
+ ````
989
+ $ bundle exec exe/emasser post cloud_resource add --systemId [value] --provider [value] --resourceId [value] --resourceName [value] --resourceType [value] --cspPolicyDefinitionId [value] --isCompliant or --is-not-Compliant --policyDefinitionTitle [value] --test [value]
990
+ ````
991
+ - required parameter are:
992
+
993
+ |parameter | type or values |
994
+ |------------------------|:--------------------------------------------------------------------------|
995
+ |--systemId |Integer - Unique system identifier |
996
+ |--provider |string - Cloud service provider name |
997
+ |--resourceId |String - Unique identifier/resource namespace for policy compliance result |
998
+ |--resourceName |String - Friendly name of Cloud resource |
999
+ |--resourceType |String - Type of Cloud resource |
1000
+ |--cspPolicyDefinitionId |String - Unique identifier/compliance namespace for CSP/Resource\'s policy definition/compliance check|
1001
+ |--isCompliant | Boolean - Compliance status of the policy for the identified cloud resource |
1002
+ |--policyDefinitionTitle | String - Friendly policy/compliance check title. Recommend short title |
1003
+
1004
+ - optional parameters are:
1005
+
1006
+ |parameter | type or values |
1007
+ |-------------------|:------------------------------------------------------|
1008
+ |--initiatedBy |String - Person initiating the process email address |
1009
+ |--cspAccountId |String - System/owner\'s CSP account ID/number |
1010
+ |--cspRegion |String - CSP region of system |
1011
+ |--isBaseline |Boolean - Flag that indicates in results is a baseline |
1012
+ |Tags Object (tags)|
1013
+ |--text | String - Text that specifies the tag type |
1014
+ |Compliance Results Array Objects (complianceResults)|
1015
+ |--assessmentProcedure |String - Comma separated correlation to Assessment Procedure (i.e. CCI number for DoD Control Set) |
1016
+ |--complianceCheckTimestamp |Date - The compliance check date - Unix time format |
1017
+ |--complianceReason |String - Reason/comments for compliance result |
1018
+ |--control |String - Comma separated correlation to Security Control (e.g. exact NIST Control acronym) |
1019
+ |--policyDeploymentName |String - Name of policy deployment |
1020
+ |--policyDeploymentVersion |String - Version of policy deployment |
1021
+ |--severity |Possible Values: Low, Medium, High, Critical |
1022
+
1023
+
1024
+ **Note**
1025
+ For information at the command line use:
1026
+ ```
1027
+ $ bundle exec exe/emasser post cloud_resource help add
1028
+ ```
1029
+
1030
+ [top](#post)
1031
+
1032
+
1033
+ ### ```post container```
1034
+ ---
1035
+ The following Container parameters/fields have the following character limitations:
1036
+ - Fields that can not exceed 100 characters:
1037
+ - STIG Benchmark ID (`benchmark`)
1038
+ - Container Namespace (`namespace`)
1039
+ - Kubernetes assigned IP (`podIp`)
1040
+ - Kubernetes Pod Name) (`podName`)
1041
+ - Fields that can not exceed 500 characters:
1042
+ - Container ID (`containerId`)
1043
+ - Friendly Container Name (`containerName`)
1044
+ - Fields that can not exceed 1000 characters:
1045
+ - Result Comments (`message`)
1046
+
1047
+
1048
+
1049
+ To add containers and their scan results in the assets module for a system use the following command:
1050
+ ````
1051
+ $ bundle exec ruby exe/emasser post container add --systemId [value] --containerId [value] --containerName [value] --time [value] --benchmark [value] --lastSeen [value] --ruleId [value] --status [value]
1052
+
1053
+ ````
1054
+
1055
+ - required parameter are:
1056
+
1057
+ |parameter | type or values |
1058
+ |------------------------|:--------------------------------------------------------------------------|
1059
+ |--systemId |Integer - Unique system identifier |
1060
+ |--containerId |String - Unique identifier of the container |
1061
+ |--containerName |String - Friendly name of the container |
1062
+ |--time |Date - Datetime of scan/result. Unix date format |
1063
+ |Bench Marks Object (benchmarks)|
1064
+ |--benchmark |String - Identifier of the benchmark/grouping of compliance results |
1065
+ |benchmarks.results |Object
1066
+ |--ruleId |String - Identifier for the compliance result, vulnerability, etc.
1067
+ |--status |String - Benchmark result status
1068
+ |--lastSeen |Date - Date last seen, Unix date format
1069
+
1070
+ - optional parameters are:
1071
+
1072
+ |parameter | type or values |
1073
+ |----------------------------|:------------------------------------------------------|
1074
+ |--podName |String - Name of pod (e.g. Kubernetes pod) |
1075
+ |--podIp |String - IP address of pod |
1076
+ |--namespace |String - Namespace of container in container orchestration (e.g. Kubernetes namespace)|
1077
+ |Tags Object (tags)|
1078
+ |--text | String - Text that specifies the tag type |
1079
+ |Bench Marks Object (benchmarks)
1080
+ |--isBaseline |Boolean - True/false flag for providing results as baseline. If true, all existing compliance results for the provided benchmark within the container will be replaced by results in the current call|
1081
+ |benchmarks.results |Object
1082
+ |--message |String - Comments for the result
1083
+
1084
+ **Note**
1085
+ For information at the command line use:
1086
+ ```
1087
+ $ bundle exec exe/emasser post container help add
1088
+ ```
1089
+ [top](#post)
1090
+
1091
+ ## Usage - PUT
1092
+
1093
+ ### ``put controls``
1094
+
1095
+ ----
1096
+ Business Rules
1097
+
1098
+ The following fields are required based on the value of the `implementationStatus` field
1099
+
1100
+ |Value |Required Fields
1101
+ |------------------------|--------------------------------------------------------
1102
+ |Planned or Implemented |controlDesignation, estimatedCompletionDate, responsibleEntities, slcmCriticality, slcmFrequency, slcmMethod, slcmMethod, slcmTracking, slcmComments
1103
+ |Not Applicable |naJustification, controlDesignation, responsibleEntities
1104
+ |Manually Inherited |controlDesignation, estimatedCompletionDate, responsibleEntities, slcmCriticality, slcmFrequency, slcmMethod, slcmMethod, slcmTracking, slcmComments
1105
+
1106
+ Implementation Plan cannot be updated if a Security Control is "Inherited" except for the following fields:
1107
+ - Common Control Provider (commonControlProvider)
1108
+ - Security Control Designation (controlDesignation)
1109
+
1110
+ The following parameters/fields have the following character limitations:
1111
+ - Implementation Plan information cannot be saved if the fields below exceed 2,000 character limits:
1112
+ - N/A Justification (`naJustification`)
1113
+ - Responsible Entities (`responsibleEntities`)
1114
+ - Implementation Narrative (`implementationNarrative`)
1115
+ - Criticality (`slcmCriticality`)
1116
+ - Reporting (`slcmReporting`)
1117
+ - Tracking (`slcmTracking`)
1118
+ - Vulnerability Summary (`vulnerabilitySummary`)
1119
+ - Recommendations (`recommendations`)
1120
+ - Implementation Plan information cannot be saved if the fields below exceed 4,000 character limits:
1121
+ - SLCM Comments (`slcmComments`)
1122
+
1123
+ Implementation Plan information cannot be updated if Security Control does not exist in the system record.
1124
+
1125
+ ---
1126
+ Updating (PUT) a Control can be accomplished by invoking the following command:
1127
+ ````
1128
+ $ bundle exec exe/emasser put controls update [PARAMETERS]
1129
+ ````
1130
+ - required parameter are:
1131
+
1132
+ |parameter | type or values |
1133
+ |--------------------------|:-------------------------------------------------------------------------|
1134
+ |--systemId |Integer - Unique system identifier |
1135
+ |--acronym |String - The system acronym(s) e.g "AC-1, AC-2" |
1136
+ |--responsibleEntities |String - Description of the responsible entities for the Security Control |
1137
+ |--controlDesignation |Possible values: Common, System-Specific, or Hybrid |
1138
+ |--estimatedCompletionDate |Date - Unix time format (e.g. 1499990400) |
1139
+ |--comments |String - Security control comments |
1140
+
1141
+ - optional parameters are:
1142
+
1143
+ |parameter | type or values |
1144
+ |-----------------------|:----------------------------------------------|
1145
+ |--implementationStatus |Possible values: Planned, Implemented, Inherited, Not Applicable, or Manually Inherited|
1146
+ |--severity |Possible values: Very Low, Low, Moderate, High, Very High |
1147
+ |--vulnerabiltySummary |String - The security control vulnerability summary |
1148
+ |--recommendations |String - The security control vulnerability recommendation |
1149
+ |--relevanceOfThreat |Possible values: Very Low, Low, Moderate, High, Very High |
1150
+ |--likelihood |Possible values: Very Low, Low, Moderate, High, Very High |
1151
+ |--impact |Possible values: Very Low, Low, Moderate, High, Very High |
1152
+ |--impactDescription |String, - Description of the security control impact |
1153
+ |--residualRiskLevel |Possible values: Very Low, Low, Moderate, High, Very High |
1154
+
1155
+ - conditional parameters are:
1156
+
1157
+ |parameter | type or values |
1158
+ |------------------------|:----------------------------------------------|
1159
+ |--commonControlProvider |Possible values: DoD, Component, Enclave|
1160
+ |--naJustification |String - Justification for Security Controls deemed Not Applicable to the system |
1161
+ |--slcmCriticality |String - Criticality of Security Control regarding SLCM |
1162
+ |--slcmFrequency |Possible values - Constantly, Daily, Weekly, Monthly, Quarterly, Semi-Annually, Annually, or Undetermined |
1163
+ |--slcmMethod |Possible values: Automated, Semi-Automated, Manual, or Undetermined |
1164
+ |--slcmReporting |String - The System-Level Continuous Monitoring reporting |
1165
+ |--slcmTracking |String - The System-Level Continuous Monitoring tracking |
1166
+ |--slcmComments |String, - Additional comments for Security Control regarding SLCM |
1167
+
1168
+ **Note**
1169
+ For information at the command line use:
1170
+ ```
1171
+ $ bundle exec exe/emasser put controls help update
1172
+ ```
1173
+ [top](#put)
1174
+
1175
+ ### ``put poams``
1176
+
1177
+ ----
1178
+ Business Rules
1179
+
1180
+ The following fields are required based on the value of the `status` field
1181
+
1182
+ |Value |Required Fields
1183
+ |----------------|--------------------------------------------------------
1184
+ |Risk Accepted |comments, resources
1185
+ |Ongoing |scheduledCompletionDate, resources, milestones (at least 1)
1186
+ |Completed |scheduledCompletionDate, comments, resources,
1187
+ | |completionDate, milestones (at least 1)
1188
+ |Not Applicable |POAM can not be created
1189
+
1190
+ If a POC email is supplied, the application will attempt to locate a user already registered within the application and pre-populate any information not explicitly supplied in the request. If no such user is found, these fields are required within the request.
1191
+ - pocOrganization, pocFirstName, pocLastName, pocEmail, pocPhoneNumber
1192
+
1193
+ Business logic, the following rules apply when adding POA&Ms
1194
+
1195
+ - POA&M Item cannot be saved if associated Security Control or AP is inherited.
1196
+ - POA&M Item cannot be created manually if a Security Control or AP is Not Applicable.
1197
+ - Completed POA&M Item cannot be saved if Completion Date is in the future.
1198
+ - Completed POA&M Item cannot be saved if Completion Date (completionDate) is in the future.
1199
+ - Risk Accepted POA&M Item cannot be saved with a Scheduled Completion Date (scheduledCompletionDate) or Milestones
1200
+ - POA&M Item with a review status of "Not Approved" cannot be saved if Milestone Scheduled Completion Date exceeds POA&M Item Scheduled Completion Date.
1201
+ - POA&M Item with a review status of "Approved" can be saved if Milestone Scheduled Completion Date exceeds POA&M Item Scheduled Completion Date.
1202
+ - POA&M Items that have a status of "Completed" and a status of "Ongoing" cannot be saved without Milestones.
1203
+ - POA&M Items that have a status of "Risk Accepted" cannot have milestones.
1204
+ - POA&M Items with a review status of "Approved" that have a status of "Completed" and "Ongoing" cannot update Scheduled Completion Date.
1205
+ - POA&M Items that have a review status of "Approved" are required to have a Severity Value assigned.
1206
+ - POA&M Items cannot be updated if they are included in an active package.
1207
+ - Archived POA&M Items cannot be updated.
1208
+ - POA&M Items with a status of "Not Applicable" will be updated through test result creation.
1209
+ - If the Security Control or Assessment Procedure does not exist in the system we may have to just import POA&M Item at the System Level.
1210
+
1211
+
1212
+ The following parameters/fields have the following character limitations:
1213
+ - POA&M Item cannot be saved if the Point of Contact fields exceed 100 characters:
1214
+ - Office / Organization (pocOrganization)
1215
+ - First Name (pocFirstName)
1216
+ - Last Name (pocLastName)
1217
+ - Email (email)
1218
+ - Phone Number (pocPhoneNumber)
1219
+ - POA&M Item cannot be saved if Mitigation field (mitigation) exceeds 2,000 characters.
1220
+ - POA&M Item cannot be saved if Source Identifying Vulnerability field (sourceIdentVuln) exceeds 2,000 characters.
1221
+ - POA&M Item cannot be saved if Comments field (comments) exceeds 2,000 characters
1222
+ - POA&M Item cannot be saved if Resource field (resource) exceeds 250 characters.
1223
+ - POA&M Items cannot be saved if Milestone Description (description) exceeds 2,000 characters.
1224
+
1225
+
1226
+ The following POA&M parameters/fields have the following character limitations:
1227
+ - Fields that can not exceed 100 characters:
1228
+ - Office / Organization (`pocOrganization`)
1229
+ - First Name (`pocFirstName`)
1230
+ - Last Name (`pocLastName`)
1231
+ - Email (`email`)
1232
+ - Phone Number (`pocPhoneNumber`)
1233
+ - External Unique ID (`externalUid`)
1234
+ - Fields that can not exceed 250 characters:
1235
+ - Resource (`resource`)
1236
+ - Fields have can not exceed 2000 character:
1237
+ - Vulnerability Description (`vulnerabilityDescription`)
1238
+ - Source Identifying Vulnerability (`sourceIdentVuln`)
1239
+ - Recommendations (`recommendations`)
1240
+ - Risk Accepted Comments (`comments`)
1241
+ - Milestone Description (`description`)
1242
+ - Mitigation Justification (`mitigation`)
1243
+
1244
+
1245
+ ---
1246
+ Updating (PUT) a POA&M can be accomplished by invoking the following command:
1247
+ ````
1248
+ $ bundle exec exe/emasser put poams update [PARAMETERS]
1249
+ ````
1250
+ - required parameter are:
1251
+
1252
+ |parameter | type or values |
1253
+ |---------------------------|:---------------------------------------------------------------|
1254
+ |--systemId |Integer - Unique system identifier |
1255
+ |--displayPoamId |Integer - Globally unique identifier for individual POA&M Items |
1256
+ |--status |Possible Values: Ongoing,Risk Accepted,Completed,Not Applicable |
1257
+ |--vulnerabilityDescription |String - Vulnerability description for the POA&M Item |
1258
+ |--sourceIdentVuln |String - Include Source Identifying Vulnerability text |
1259
+ |--pocOrganization |String - Organization/Office represented |
1260
+ |--resources |String - List of resources used. Character Limit = 250 |
1261
+
1262
+ ** If any poc information is provided all POC fields are required. See additional details for POC fields below.
1263
+
1264
+ - conditional parameters are:
1265
+
1266
+ |parameter | type or values |
1267
+ |--------------------------|:-----------------------------------------------------------------------|
1268
+ |--milestones |JSON - see milestone format |
1269
+ |--pocFirstName |String - First name of POC |
1270
+ |--pocLastName |String - Last name of POC |
1271
+ |--pocEmail |String - Email address of POC |
1272
+ |--pocPhoneNumber |String - Phone number of POC (area code) ***-**** format |
1273
+ |--severity |Possible values - Very Low, Low, Moderate, High, Very High |
1274
+ |--scheduledCompletionDate |Date - Required for ongoing and completed POA&M items. Unix time format |
1275
+ |--completionDate |Date - Field is required for completed POA&M items. Unix time format |
1276
+ |--comments |String - Field is required for completed and risk accepted POA&M items |
1277
+ |--isActive |Boolean - Used to delete milestones when updating a POA&M |
1278
+
1279
+ ** If a POC email is supplied, the application will attempt to locate a user already registered within the application and pre-populate any information not explicitly supplied in the request. If no such user is found, these fields are required within the request:
1280
+ pocFirstName, pocLastName, pocPhoneNumber
1281
+
1282
+ Milestone Format:
1283
+ - --milestone milestoneId:[value] description:[value] scheduledCompletionDate:[value]
1284
+ - If a milestoneId is not provide a new milestone is created
1285
+
1286
+ - optional parameters are:
1287
+
1288
+ |parameter | type or values |
1289
+ |--------------------|:-----------------------------------------------------------------------------------------|
1290
+ |--externalUid |String - External unique identifier for use with associating POA&M Items |
1291
+ |--controlAcronym |String - Control acronym associated with the POA&M Item. NIST SP 800-53 Revision 4 defined|
1292
+ |--cci |String - CCI associated with the test result |
1293
+ |--securityChecks |String - Security Checks that are associated with the POA&M |
1294
+ |--rawSeverity |Possible values: I, II, III |
1295
+ |--relevanceOfThreat |Possible values: Very Low, Low, Moderate, High, Very High |
1296
+ |--likelihood |Possible values: Very Low, Low, Moderate, High, Very High |
1297
+ |--impact |Possible values: Very Low, Low, Moderate, High, Very High |
1298
+ |--impactDescription |String - Include description of Security Control’s impact |
1299
+ |--residualRiskLevel |Possible values: Very Low, Low, Moderate, High, Very High |
1300
+ |--recommendations |String - Include recommendations |
1301
+ |--mitigation |String - Include mitigation explanation. 2000 Characters |
1302
+
1303
+ **Note**
1304
+ For information at the command line use:
1305
+ ```
1306
+ $ bundle exec exe/emasser put poams help update
1307
+ ```
1308
+ [top](#put)
1309
+
1310
+ ### ``put milestones``
1311
+
1312
+ ----
1313
+
1314
+ To add (POST) milestones in a system for one or more POA&M items use the following command:
1315
+
1316
+ ````
1317
+ $ bundle exec exe/emasser put milestones update [PARAMETERS]
1318
+ ````
1319
+ - required parameter are:
1320
+
1321
+ |parameter | type or values |
1322
+ |---------------------------|:----------------------------------------------------|
1323
+ |--systemId |Integer - Unique system identifier |
1324
+ |--poamId |Integer - Unique poam identifier |
1325
+ |--milestoneId |Integer - Unique milestone identifier |
1326
+ |--description |String - Milestone item description. 2000 Characters |
1327
+ |--scheduledCompletionDate |Date - Schedule completion date. Unix date format |
1328
+
1329
+
1330
+ **Note**
1331
+ For information at the command line use:
1332
+ ```
1333
+ $ bundle exec exe/emasser put milestones help update
1334
+ ```
1335
+ [top](#put)
1336
+
1337
+ ### ``put artifacts``
1338
+
1339
+ ----
1340
+ Business Rules
1341
+
1342
+ - Artifact cannot be saved if the file does not have the following file extensions:
1343
+ - .docx,.doc,.txt,.rtf,.xfdl,.xml,.mht,.mhtml,.html,.htm,.pdf
1344
+ - .mdb,.accdb,.ppt,.pptx,.xls,.xlsx,.csv,.log
1345
+ - .jpeg,.jpg,.tiff,.bmp,.tif,.png,.gif
1346
+ - .zip,.rar,.msg,.vsd,.vsw,.vdx, .z{#}, .ckl,.avi,.vsdx
1347
+ - Artifact cannot be saved if File Name (fileName) exceeds 1,000 characters
1348
+ - Artifact cannot be saved if Description (description) exceeds 2,000 characters
1349
+ - Artifact cannot be saved if Reference Page Number (refPageNumber) exceeds 50 characters
1350
+ - Artifact cannot be saved if the file does not have an allowable file extension/type.
1351
+ - Artifact version cannot be saved if an Artifact with the same file name already exist in the system.
1352
+ - Artifact cannot be saved if the file size exceeds 30MB.
1353
+ - Artifact cannot be saved if the Last Review Date is set in the future.
1354
+
1355
+ To add (POST) milestones in a system for one or more POA&M items use the following command:
1356
+
1357
+ ````
1358
+ $ bundle exec exe/emasser put artifacts update [PARAMETERS]
1359
+ ````
1360
+ - required parameter are:
1361
+
1362
+ |parameter | type or values |
1363
+ |----------------|:----------------------------------------------------|
1364
+ |--systemId |Integer - Unique system identifier |
1365
+ |--filename |String - File name should match exactly one file within the provided zip file|
1366
+ | |Binary - Application/zip file. Max 30MB per artifact |
1367
+ |--isTemplate |Boolean - Indicates whether an artifact is a template|
1368
+ |--type* |Possible Values: Procedure, Diagram, Policy, Labor, Document, Image, Other, Scan Result, Auditor Report|
1369
+ |--category* |Possible Values: Implementation Guidance, Evidence |
1370
+
1371
+ *May also accept custom artifact category values set by system administrators.
1372
+
1373
+ - optional parameter are:
1374
+
1375
+ |parameter | type or values |
1376
+ |-------------------------|:------------------------------------------------------|
1377
+ |--description |String - Artifact description. 2000 Characters |
1378
+ |--refPageNumber |String - Artifact reference page number. 50 Characters |
1379
+ |--ccis |String - CCIs associated with artifact |
1380
+ |--controls |String - Control acronym associated with the artifact. NIST SP 800-53 Revision 4 defined|
1381
+ |--artifactExpirationDate |Date - Date Artifact expires and requires review. In Unix Date Format|
1382
+ |--lastReviewedDate |Date - Date Artifact was last reviewed. In Unix Date Format |
1383
+
1384
+
1385
+ **Note**
1386
+ For information at the command line use:
1387
+ ```
1388
+ $ bundle exec exe/emasser put artifacts help update
1389
+ ```
1390
+ [top](#put)
1391
+
1392
+ ## Usage - DELETE
1393
+
1394
+ ### ``delete poams``
1395
+
1396
+ ----
1397
+ Remove one or many poa&m items in a system
1398
+
1399
+ To remove (DELETE) one or more POA&M items use the following command:
1400
+ ```
1401
+ bundle exec exe/emasser delete poams remove --systemId [value] --poamId [value]
1402
+ ```
1403
+ [top](#delete)
1404
+
1405
+ ### ``delete milestones``
1406
+
1407
+ ----
1408
+ Remove milestones in a system for one or many POA&M items
1409
+
1410
+ To delete a milestone the record must be inactive by having the field isActive set to false (isActive=false).
1411
+
1412
+ The server returns an empty object upon successfully deleting a milestone.
1413
+
1414
+ The last milestone can not be deleted, at-least on must exist.
1415
+
1416
+ To remove (DELETE) one or more Milestones in a system use the following command:
1417
+ ```
1418
+ bundle exec exe/emasser delete milestones remove--systemId [value] --poamId [value] --milestoneId [value]
1419
+ ```
1420
+ [top](#delete)
1421
+
1422
+ ### ``delete artifacts``
1423
+
1424
+ ---
1425
+ Remove one or many artifacts in a system
1426
+
1427
+ Provide single file or a space/comma delimited list of file names to be removed from the system (systemId)
1428
+
1429
+ To remove (DELETE) one or more Artifacts from a system use the following command:
1430
+ ```
1431
+ bundle exec exe/emasser delete artifacts remove --systemId [value] --files [value]
1432
+ or
1433
+ bundle exec exe/emasser delete artifacts remove --systemId [value] --files [value value...]
1434
+ or
1435
+ bundle exec exe/emasser delete artifacts remove --systemId [value] --files [value, value...]
1436
+ ```
1331
1437
  [top](#delete)