Skip to content

Commit 327469b

Browse files
chore: document MongoDB replSet config.
This also cleans up the Markdown formatting of the top-level project README.md. Signed-off-by: Andrew Lilley Brinker <abrinker@mitre.org>
1 parent 40db61f commit 327469b

File tree

1 file changed

+111
-42
lines changed

1 file changed

+111
-42
lines changed

README.md

Lines changed: 111 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -20,19 +20,24 @@
2020

2121
## The CVE Services Project
2222

23-
This repository contains services that support the [CVE Program's mission](https://www.cve.org/About/Overview) to "identify, define, and catalog publicly disclosed cybersecurity vulnerabilities."
23+
This repository contains services that support the [CVE Program's
24+
mission][cve_mission] to "identify, define, and catalog publicly disclosed
25+
cybersecurity vulnerabilities."
2426

2527
There are many ways one can assist:
2628

2729
### OSS Contributor
2830

29-
Developers can contribute code directly. Getting started can be as fast as choosing an issue on our [board](https://github.com/CVEProject/cve-services/issues?q=is%3Aissue+is%3Aopen).
31+
Developers can contribute code directly. Getting started can be as fast as
32+
choosing an issue on our [board][cve_issue_tracker].
3033

31-
Please read our [contributor's guide](https://github.com/CVEProject/cve-services/blob/dev/CONTRIBUTING.md) for more details. We welcome all contributions!
34+
Please read our [contributor's guide](./CONTRIBUTING.md) for more details. We
35+
welcome all contributions!
3236

3337
### Working Groups
3438

35-
The CVE project operates as multiple focused working groups. Visit the CVE Website [working groups page](https://www.cve.org/ProgramOrganization/WorkingGroups) for more information.
39+
The CVE project operates as multiple focused working groups. Visit the CVE
40+
Website [working groups page](cve_wg) for more information.
3641

3742
### Security
3843

@@ -41,34 +46,37 @@ The CVE project operates as multiple focused working groups. Visit the CVE Websi
4146
>**Warning**
4247
>Do not put vulnerability information in a GitHub issue.
4348
44-
Please consult our [SECURITY.md](https://github.com/CVEProject/cve-services/blob/dev/SECURITY.md) for specific instructions on reporting a vulnerability that exists in the CVE Services.
49+
Please consult our [SECURITY.md](./SECURITY.md) for specific instructions on
50+
reporting a vulnerability that exists in the CVE Services.
4551

4652
## Development
4753

4854
### Technologies
4955

5056
This project uses or depends on software from
5157

52-
- [NodeJS](https://nodejs.org/)
53-
- [Express](https://github.com/expressjs)
54-
- [MongoDB for locally run instances](https://www.mongodb.com/)
55-
- [Mongoose.js](https://mongoosejs.com)
58+
- [NodeJS][nodejs]
59+
- [Express][express]
60+
- [MongoDB for locally run instances][mongodb]
61+
- [Mongoose.js][mongoose]
5662

5763
### Style Guidelines
5864

59-
This project follows the [JavaScript Standard Style](https://github.com/standard/standard).
65+
This project follows the [JavaScript Standard Style][js_standard].
6066

6167
### Setup
6268

6369
#### Docker
6470

65-
See the Docker README found in the repo here: https://github.com/CVEProject/cve-services/blob/dev/docker/README.md
71+
See [the Docker README found in the repo](./docker/README.md).
6672

6773
#### Local Development
6874

69-
>**Warning**
75+
> **Warning**
7076
>
71-
>DO NOT use the dev configuration on a public network. The dev environment includes credentials to enable rapid development and is not secure for public deployment.
77+
> DO NOT use the dev configuration on a public network. The dev environment
78+
> includes credentials to enable rapid development and is not secure for public
79+
> deployment.
7280
7381
1. Install required node modules
7482

@@ -83,13 +91,18 @@ npm install
8391

8492
Install MongoDB locally
8593

86-
- https://docs.mongodb.com/manual/administration/install-community/
94+
- <https://docs.mongodb.com/manual/administration/install-community/>
8795

8896
Download MongoDB Compass (MongoDB GUI)
8997

90-
- https://www.mongodb.com/download-center/compass
98+
- <https://www.mongodb.com/download-center/compass>
99+
100+
For transaction support, MongoDB needs to be configured with a replica set. You
101+
can do this by setting [`replication.replSetName`][mongodb_replset] in the
102+
`mongod.conf` file and restarting the MongoDB service.
91103

92-
Create a `cve_dev` database in Compass. The collections will be automatically created when the API starts storing documents.
104+
Create a `cve_dev` database in Compass. The collections will be automatically
105+
created when the API starts storing documents.
93106

94107
You can populate the database with test data using:
95108

@@ -108,34 +121,48 @@ npm run start:dev
108121

109122
### API Documentation
110123

111-
API documentation is generated using [swagger-autogen](https://github.com/davibaltar/swagger-autogen) which ensures that we keep the API specification up to date with any major changes to API routes. Extra information for each API route is defined as a comment in the `index.js` files under the respective controller and all request and response schemas are stored under the `schemas` folder served up by `schemas.controller`.
124+
API documentation is generated using [swagger-autogen][swagger_autogen] which
125+
ensures that we keep the API specification up to date with any major changes to
126+
API routes. Extra information for each API route is defined as a comment in the
127+
`index.js` files under the respective controller and all request and response
128+
schemas are stored under the `schemas` folder served up by
129+
`schemas.controller`.
112130

113-
To ensure you are using the correct API specification the following endpoints can be used:
114-
- [Test Instance](https://cveawg-test.mitre.org/api-docs/)
115-
- [Production](https://cveawg.mitre.org/api-docs/)
131+
To ensure you are using the correct API specification the following endpoints
132+
can be used:
116133

117-
Note: The specification file stored in GitHub will only be correct for that branch; there could be differences between branches and production.
134+
- [Test Instance][cve_instance_test]
135+
- [Production][cve_instance_prod]
118136

119-
If you are developer and want to test changes to the API specification you can generate a specification in one of two ways:
137+
Note: The specification file stored in GitHub will only be correct for that
138+
branch; there could be differences between branches and production.
139+
140+
If you are developer and want to test changes to the API specification you can
141+
generate a specification in one of two ways:
120142

121143
1. Preferred
122144

123-
When you start your local development server using `npm run start:dev` the specification file will be generated. Subsequent changes require reloading the server.
145+
When you start your local development server using `npm run start:dev` the
146+
specification file will be generated. Subsequent changes require reloading the
147+
server.
124148

125149
2. Manual
126150

127151
You can use `npm run swagger-autogen` to generate a new specification file.
128152

129153
### CVE Record Submission Validation Rules
130154

131-
As part of the submission processing, CVE Services "validates" that specific requirements are met prior to accepting the submission and posting the CVE Record to the CVE List. Validation rules for CVE Record Submission are noted [here](https://github.com/CVEProject/automation-working-group/blob/master/meeting-notes/files/CVERules.md).
155+
As part of the submission processing, CVE Services "validates" that specific
156+
requirements are met prior to accepting the submission and posting the CVE
157+
Record to the CVE List. Validation rules for CVE Record Submission are noted
158+
[here][cve_validation_rules].
132159

133160
### Unit Testing
134161

135162
This project uses the following for unit testing
136163

137-
- https://mochajs.org/
138-
- https://www.chaijs.com/
164+
- <https://mochajs.org/>
165+
- <https://www.chaijs.com/>
139166

140167
In order to run the unit tests:
141168

@@ -145,31 +172,73 @@ npm run start:test
145172

146173
### User Registry
147174

148-
The CVE Automation Working Group (on behalf of the CVE Program) is currently working on a new automation capability: the User Registry. The objective of the User Registry is to modernize how CVE Program Organizations (e.g., CNAs, Roots, Top level Roots, the Secretariat) manage/update their organizational properties and user pools. The new capability will ultimately allow CNAs, Roots, Top Level Roots to better manage their own data/user pools with more robust information. It is targeted to be implemented in a series of incremental deployments to CVE Services in the Fall/2025 through Summer/2026.
175+
The CVE Automation Working Group (on behalf of the CVE Program) is currently
176+
working on a new automation capability: the User Registry. The objective of the
177+
User Registry is to modernize how CVE Program Organizations (e.g., CNAs, Roots,
178+
Top level Roots, the Secretariat) manage/update their organizational properties
179+
and user pools. The new capability will ultimately allow CNAs, Roots,
180+
Top Level Roots to better manage their own data/user pools with more robust
181+
information. It is targeted to be implemented in a series of incremental
182+
deployments to CVE Services in the Fall/2025 through Summer/2026.
149183

150184
#### Current Status:
151185

152-
The release candidate for the first User Registry increment (termed the User Registry MVP) is now available for testing/review in the CVE Program Testing Environment. (Note that this release IS NOT a PRODUCTION Release and will not be visible in the CVE Program PRODUCTION environment).
153-
This release candidate establishes a new, more robust User/Organizations databases (and associated APIs) while maintaining full backwards compatibility with the current User/Organizational management functions (meaning that current CVE Services clients will not be required to be modified with the deployment of this candidate). It was discussed at the [6/10/2025 CVE Program AWG meeting](https://github.com/CVEProject/automation-working-group/blob/master/meeting-notes/2025-06-10.md).
186+
The release candidate for the first User Registry increment (termed the User
187+
Registry MVP) is now available for testing/review in the CVE Program Testing
188+
Environment. (Note that this release IS NOT a PRODUCTION Release and will not
189+
be visible in the CVE Program PRODUCTION environment).
154190

155-
#### HowTo:
191+
This release candidate establishes a new, more robust User/Organizations
192+
databases (and associated APIs) while maintaining full backwards compatibility
193+
with the current User/Organizational management functions (meaning that current
194+
CVE Services clients will not be required to be modified with the deployment of
195+
this candidate). It was discussed at the [6/10/2025 CVE Program AWG
196+
meeting][cve_awg_meeting].
156197

157-
Credentialed users of CVE Services Test Environment will be able to use the new capabilities via the API endpoints which are described [here](https://cveawg-test.mitre.org/api-docs/) (Be sure to scroll down to the bottom of the page to review the new User Registry interfaces).
198+
#### How To:
158199

159-
Credentialed users can access the APIs by
200+
Credentialed users of CVE Services Test Environment will be able to use the new
201+
capabilities via the API endpoints which are described
202+
[here][cve_instance_test] (Be sure to scroll down to the bottom of the page to
203+
review the new User Registry interfaces).
160204

161-
- installing/using common web application API testing tools such as [curl](https://curl.se/) or [postman](https://www.postman.com/) OR
205+
Credentialed users can access the APIs by
162206

163-
- installing/using the [User Registry Client](https://github.com/CVEProject/cve-user-registry-client) which provides a GUI interface to exercise the basic functions of the User Registry.
207+
- installing/using common web application API testing tools such as [curl] or
208+
[postman] OR
209+
- installing/using the [User Registry Client][cve_ur_client] which provides a
210+
GUI interface to exercise the basic functions of the User Registry.
164211

165-
Note that there is no support for these new endpoints in many currently available CVE Services “client” tools (e.g, Vulnogram) and hence they should not be relied upon to examine/test these interfaces.
212+
Note that there is no support for these new endpoints in many currently
213+
available CVE Services “client” tools (e.g, Vulnogram) and hence they should
214+
not be relied upon to examine/test these interfaces.
166215

167216
#### Next Steps:
168217

169-
The AWG is taking comments/questions on this release candidate. You can provide feedback in three ways:
170-
171-
- Send comments/questions to AWG+owner@CVE-CWE-Programs.groups.io,
172-
173-
- Post Issues/Questions to the CVE Services Issue Board (please attach a “user registry” label to your post).
174-
175-
- Attend (virtually) an AWG meeting which meets every week on Tuesday at 4:00 PM Eastern US Time. Send a request for the link to AWG+owner@CVE-CWE-Programs.groups.io.
218+
The AWG is taking comments/questions on this release candidate. You can provide
219+
feedback in three ways:
220+
221+
- Send comments/questions to `AWG+owner@CVE-CWE-Programs.groups.io`,
222+
- Post Issues/Questions to the CVE Services Issue Board (please attach a “user
223+
registry” label to your post).
224+
- Attend (virtually) an AWG meeting which meets every week on Tuesday at 4:00
225+
PM Eastern US Time. Send a request for the link to
226+
`AWG+owner@CVE-CWE-Programs.groups.io`.
227+
228+
[curl]: https://curl.se/
229+
[cve_awg_meeting]: https://github.com/CVEProject/automation-working-group/blob/master/meeting-notes/2025-06-10.md
230+
[cve_instance_prod]: https://cveawg.mitre.org/api-docs/
231+
[cve_instance_test]: https://cveawg-test.mitre.org/api-docs/
232+
[cve_issue_tracker]: https://github.com/CVEProject/cve-services/issues?q=is%3Aissue+is%3Aopen
233+
[cve_mission]: https://www.cve.org/About/Overview
234+
[cve_ur_client]: https://github.com/CVEProject/cve-user-registry-client
235+
[cve_validation_rules]: https://github.com/CVEProject/automation-working-group/blob/master/meeting-notes/files/CVERules.md
236+
[cve_wg]: https://www.cve.org/ProgramOrganization/WorkingGroups
237+
[express]: https://github.com/expressjs
238+
[js_standard]: https://github.com/standard/standard
239+
[mongodb]: https://www.mongodb.com/
240+
[mongodb_replset]: https://www.mongodb.com/docs/manual/reference/configuration-options/#mongodb-setting-replication.replSetName
241+
[mongoose]: https://mongoosejs.com
242+
[nodejs]: https://nodejs.org/
243+
[postman]: https://www.postman.com/
244+
[swagger_autogen]: https://github.com/davibaltar/swagger-autogen

0 commit comments

Comments
 (0)