Commit Graph
44 Commits
Author SHA1 Message Date
Tim BruijnzeelsandGitHub 25fa398ec7 Mark roas lost resources (#602) 2021-08-04 12:51:49 +02:00
Tim Bruijnzeels 41a23742a3 Update UI to latest. 2021-05-11 15:47:14 +02:00
Tim Bruijnzeels 04f2e159e5 Update UI - only show repository details if they had been set. 2021-05-03 16:14:42 +02:00
Tim Bruijnzeels bf75652db8 Update UI with fix to show the repository now that 'embedded' no longer applies. 2021-04-30 15:13:17 +02:00
Ximon EighteenandGitHub 13b6f7d1f3 Security tweaks (#382) (#484)
* Encrypt session state using ChaCha20-Poly1305 instead of AES-GCM.
* Replace config file users login use of insecure unsalted SHA2 password hashing with secure scrypt salted password hashing.
* Log the start of the request before determining the actor.
* Allow sufficient time for password hashing delays during login with config file user based tests..
* Synced with Lagosta commit b49f23de.
2021-04-20 00:47:22 +02:00
67ca2f4914 Disable update existing repository (#481)
* Disallow updating a repository if it had been set before
* Check that a repository is available before adding it
* Use "krillc repo configure" because it describes the action better

Co-authored-by: Ximon Eighteen <3304436+ximon18@users.noreply.github.com>
2021-04-19 16:10:35 +02:00
Ximon EighteenandGitHub a06e36d827 Push password field down so username error does not overlap. (#474)
Synced with Lagosta master commit a0502d63.
2021-04-15 13:17:34 +02:00
8a36517126 Error handling fixes and improvements (#464)
Fixes:
* Just use the token we have if we would ideally refresh before expiration but don't have a refresh token.
* Don't hide useful OpenID Connect error details (such as self-signed cert rejected instead of just request failed). (fixes #427)
* Lagosta fixes from branch issue-379-handle-connection-issues commit 58f5ccc7 (relates to #442).

Functional improvements:
* Return or log less in some error scenarios (#419).
* Upgrade to Oso 0.11.2 to get a MUCH better error report when a ?= query in a .polar file fails, plus the Mutex around Oso is no longer needed.
* Log when OIDC discovery completes successfully.
* Be cautious, just log connection issues to the OpenID Connect provider for now, don't retry discovery.
* Use a lower timeout for the OpenID Connect HTTP client than the normal Krill HTTP client.
* Log more cause chains where available.

Code quality improvements:
* Apply review feddback: unwrap locks and crash out via panic to be consistent with the rest of Krill.
* Factor out the repeated RAII guard handling.
* Split login() out into helper methods.
* Removed TODO comment.

Testing improvements:
* Removed left-behind debug screenshot.
* Add a test to show a bug whereby access is wrongly denied if a token is pending expiration and has no refresh token. 
* Add a test to make sure Krill handles timeout of requests to the OIDC provider correctly. Also adds support for a lower timeout in test mode ala how it's done elsewhere in Krill, and more faithfully replicates the normal Krill HTTP client configuration when configuring the OIDC HTTP client. Also factored the OIDC HTTP client code out as it is getting too large to live in provider.rs.
* Extend the OpenID Connect provider not available test to show that Krill copes with the provider being unavailable and coming back to life again.
* Re-worked the test/mock relationship so that the mock no longer has hard-coded users and username based behaviour activation but rather now the test sets the desired behaviour and is thus easier to understand and more flexible.
* Extended the OpenID Connect mock so that its endpoints can be disabled and enabled during tests, and be disabled before Krill even does initial discovery.
* Use example.com based bad ACR ID token.
* Remove support for the NoResponse mock failure mode as it blocks the tiny http server thread indefinitely also preventing a test using it from exiting, and adds little no perceived benefit over the SlowResponse failure mode (which does at least stop blocking within the expected test run time).
* The mock OpenID Connect provider must be shutdown before the UI test result is asserted, otherwise the test process never terminates.
* Use the expected OpenID Connect provider timeout when in test mode.
* Extend the openid connect test to test the 'hybrid' user attributes case.
* Give the login more time to complete before expiring the access token. (#466).
* Wait for the right backend status BEFORE clicking the ROAs tab. (#465)

Other:
* OpenID Connect log message consistency tweaks.
* Sync with updated correspoinding Lagosta branch commit d2a92fe1 with latest Lagosta master merged in and a yarn build empty catch block fix.
* Sync with commit b9a2f5b3 in the corresponding PR branch in Lagosta to get a testbed REST API client fix.

Co-authored-by: Tim Bruijnzeels <tim@nlnetlabs.nl>
2021-04-13 12:13:18 +02:00
7cb5674033 Stabilize API and CLI (#330 and #360)
* Move child_request API endpoint for conststency. (#330)
* Move get RFC 8183 Publisher Request API endpoints (#330)
* Accept XML and json to add/update parent on same endpoints (#330)
* Simplify the JSON to add a child and remove unused fields. (#330)
* Update path to child_request in openapi spec.
* Update path to publisher request.
* Update api spec and documentation.
* Fix update parent API documentation and call by CLI.
* CLI stability
* Update pubd OpenAPI spec t o match changes made to the Krill API.
* Update the e2e test client code to submit only the id_cert and not the whole RFC8183 request, as required by changes made to the Krill API.

Co-authored-by: Ximon Eighteen <3304436+ximon18@users.noreply.github.com>
2021-04-12 17:24:41 +02:00
e662c1553b Change to a hybrid event sourcing model for CAs and Repository. (#426)
This allows us to keep the full history of semantically important events, while not spamming the history and avoiding excessive use of disk space. See issues #370 and #423.

This is a substantial change. Highlights follow:
* Added a developer documentation section
* No longer using events for manifest/crl generation (#370)
* No longer using events for publication deltas (#423)
* Removed pre 0.6.0 migration code - people will have to upgrade to at least 0.6.0 first
* Added migration code for 0.6.0-0.8.1 to this
* Migrate repository by doing a keyroll. (#370)
* Remove archiving code for commands (no longer applicable)

Minor other fixes:
* Use a swap file when writing (avoid corrupt json if disk is full) (#370)
* Make removing publisher content idempotent for publishers already removed.

Co-authored-by: Ximon Eighteen <3304436+ximon18@users.noreply.github.com>
Co-authored-by: Jasper den Hertog <jasper@plainspace.com>
2021-03-17 12:08:36 +01:00
Ximon EighteenandGitHub bbfe9a824a Testbed mode should be more liberal in handling formatting variations in child and publisher registration XML. (#369) (#403)
Testbed mode should be more liberal in handling formatting variations in child and publisher registration XML. Synced with Lagosta commit d94470db. (#369, #403)
2021-01-29 17:11:30 +01:00
Ximon Eighteen 87cdf7962f FIX: Pass user attributes to Lagosta, not just the role. Synced with Lagosta master branch commit ac2dab37. 2021-01-09 14:55:06 +01:00
Ximon Eighteen db8647b60f FIX: Initial rough implementation: Don't fail Krill startup if the OpenID Connect provider is unavailable. Synced with Lagosta master commit 5f61a5c9. Also includes some minor log / error consistency/cleanup tweaks. 2021-01-06 13:56:39 +01:00
Ximon Eighteen b2cf7535dd Error handling tweaks. 2020-12-30 15:46:08 +01:00
Ximon Eighteen c12512c64b Take latest Lagosta fixes (title case user attribte keys and properly store refreshed token). 2020-12-15 15:25:51 +01:00
Ximon Eighteen 0bdb082b3a Commit local Lagosta files which are unexpectedly different to those in Git. 2020-12-07 18:18:08 +01:00
Ximon Eighteen 472a0e4751 Merge multi-user branch. Uses Lagosta master branch commit a7e73cba which includes multi-user support. 2020-12-07 16:55:40 +01:00
Tim Bruijnzeels e57bcad61e Fix ROA (without BGP Info) view. 2020-11-10 09:23:54 +01:00
Tim Bruijnzeels aef4188de9 Use a single line for the ROA suggestions warning and link. 2020-11-09 15:48:01 +01:00
Tim Bruijnzeels f18751fd31 Add reason column to the ROA analysis dialog 2020-11-08 21:59:02 +01:00
Tim Bruijnzeels 4b312e98cc UI fixes for 0.8.1-rc1 2020-11-08 16:50:08 +01:00
Tim Bruijnzeels ef71416381 Add clear status for ROAs that only disallow announcements (#344) 2020-11-06 09:30:20 +01:00
Tim Bruijnzeels 3bb70bdbe3 Allow creating redundant ROAs (#341) 2020-11-05 16:15:49 +01:00
Tim Bruijnzeels 3c85407c1e Allow overlapping AS0 ROAs, suggest to remove redundant AS0 ROAs. (#342) 2020-11-04 10:45:19 +01:00
Tim Bruijnzeels fcd38dd168 Upgrade lagosta before 0.8.0-rc1 2020-10-09 13:06:45 +02:00
Tim Bruijnzeels 3ad42f6b12 Update lagosta with 'add parent errors' 2020-10-08 21:31:54 +02:00
Tim Bruijnzeels 363e40008e Update lagosta 2020-10-08 09:08:22 +02:00
Tim Bruijnzeels 764a963b54 Update lagosta UI. 2020-10-06 13:18:21 +02:00
Tim Bruijnzeels c49f5277a5 Update lagosta. 2020-09-25 10:12:51 +02:00
Tim Bruijnzeels cf34f01a6c Update lagosta. 2020-09-24 14:18:04 +02:00
Tim Bruijnzeels 3d476be151 Update to latest lagosta 'suggestions' 2020-09-16 16:23:02 +02:00
Tim Bruijnzeels 9777b6aa68 Include latest lagosta suggestions branch. 2020-09-04 09:47:06 +02:00
Tim Bruijnzeels 1eed011aea Update to latest UI with German translations. 2020-06-28 22:43:34 +02:00
Tim BruijnzeelsandGitHub e706465d45 Change roa stale to roa unseen (#267) 2020-06-24 11:43:21 +02:00
Tim Bruijnzeels 9b55f5e320 Update to Lagosta 0.7. 2020-06-23 15:57:38 +02:00
Tim Bruijnzeels 91ea0c05a2 Update to pre-release Lagosta.
Still needs translations and minor fixes.
2020-06-22 13:51:39 +02:00
Tim Bruijnzeels 9a284f64ae Update to Lagosta UI with initial BGP support. 2020-06-12 10:52:24 +02:00
Tim Bruijnzeels 7610ae2dcc Update to Lagosta 0.6.0 2020-05-06 16:28:45 +02:00
Tim Bruijnzeels 25c0653646 Update to latest lagosta which removes the ARIN toggle. 2020-04-02 12:29:12 +02:00
Tim Bruijnzeels 9d0f30210b Updating to latest Lagosta - prep for 0.5.1 release. 2020-03-10 14:45:05 +01:00
Tim Bruijnzeels 5c8bdc693f Update to Lagosta 0.1.0 'Fritto Misto' 2020-02-25 10:38:08 +01:00
Tim Bruijnzeels f417b3b6c3 Push fix for ARIN XML toggle. 2020-02-20 10:50:52 +01:00
Tim Bruijnzeels 1636a33065 Update lagosta to 0.1 release candidate. 2020-02-19 17:19:39 +01:00
Tim Bruijnzeels bf9ba749b8 Serve lagosta files in Krill (closes: #204) 2020-02-14 15:54:05 +01:00