* adds constants util for wizards and updates service to use WizardId type
* updates wizards to use WIZARD_ID_MAP values
* updates wizard tests to use the service for dismissal
* updates playwright setup to add all wizard ids as dismissed in localStorage
* removes wizard dismissal step from existing playwright tests
* fixes issues accessing owner in beforeEach hooks of namespaces acceptance tests
Co-authored-by: Jordan Reimer <zofskeez@gmail.com>
* rework UI CI workflow to partition JS tests (#11967)
* add setup-pnpm action
* remove reading vault keys from vault server output
* update ci workflow to build app and go binary first, then run tests in partitions
* fix errant tests
* address PR feedback
* Apply suggestions from code review
Co-authored-by: Ryan Cragun <me@ryan.ec>
* more feedback changes
* restore test-helper.js
* restore auth test helpers
* check in ui/tests/helpers/vault-keys.js
* use v7 of download-artifact action
* make test-ui reusable workflow
* add status job
---------
Co-authored-by: Ryan Cragun <me@ryan.ec>
* update new UI tests to run CE tests on the CE branch (#12537)
---------
Co-authored-by: Matthew Irish <39469+meirish@users.noreply.github.com>
Co-authored-by: Ryan Cragun <me@ryan.ec>
Add automated form config generation from OpenAPI specs.
Generator script can be utilized by passing API method name
which will then parse the OAS and generate the necessary form
configuration to be used with the upcoming V2 Form systems.
Co-authored-by: Angelo Cordon <angelo.cordon@hashicorp.com>
* make router-lookup helper
* add policyPaths arg to flyout and update route cache to map
* update kv flyouts and test coverage
* round out test coverage, rename method from get to lookup
Co-authored-by: claire bontempo <68122737+hellobontempo@users.noreply.github.com>
* improve dismissal logic, use AutomationSnippet component, use wizard service for tracking dismissal
* use class helper to check for multiple nodes when rendering tree chart, add test coverage
* update comments
* add modal for namespace intro and improve reusability
* style updates and general reusability updates
* make intro pages more generic and rename welcome to intro
* update tests
* update styles, use service to track intro visibility, rename components
* Update arg docs
Co-authored-by: lane-wetmore <lane.wetmore@hashicorp.com>
* [VAULT-33083] support mount external engine
* add "Plugin type" and "Plugin version" fields to the enable mount page
* add changelog
* address copilot review comments
* address PR comments, code cleanup
* fix test failures
* Add support for external plugins registered without a plugin version
* external plugin should be enabled for enterprise only, plugin version should be mandatory for external plugins
* fix tests
* address copilot feedback
* fix failing tests, add unit test coverage
* address PR comments
* address PR comments
* remove dead code
* move no external versions alert
* Only show un-versioned plugin message if there are un-versioned plugins in the catalog.
* address PR comments
* use ApiService instead of custom PluginPinsService; fix failing tests
* revert changes to forms/mount.ts and forms/auth/method.ts
Co-authored-by: Shannon Roberts (Beagin) <beagins@users.noreply.github.com>
* improve dismissal logic, use AutomationSnippet component, use wizard service for tracking dismissal
* use class helper to check for multiple nodes when rendering tree chart, add test coverage
* update comments
* add wizard service unit test coverage
* move item filtering into helper func
Co-authored-by: lane-wetmore <lane.wetmore@hashicorp.com>
* updates flags service to use api service
* converts clients index route to ts
* updates clients config workflows to use api service
* updates clients date-range component to handle Date objects rather than ISO strings
* updates clients page-header component to handle Date objects and use api and capabilities services
* updates clients route to use api and capabilities services
* updates types in client-counts helpers
* updates client counts route to use api service
* updates types for client-counts serializers
* updates date handling in client counts page component
* updates clients overview page component
* converts clients page-header component to ts
* fixes type errors in clients page-header component
* updates client counts tests
* updates client-count-card component to use api service
* converts client-count-card component to ts
* removes model-form-fields test that uses clients/config model
* removes clients/version-history model usage from client-counts helpers tests
* removes migrated models from adapter and model registries
* removes clients ember data models, adapters and serializers
* updates clients date-range component to format dates in time zone
* cleans up references to activityError in client counts route
* adds clients/activity mirage model
* updates activation flags assertions in sync overview tests
* fixes issue selecting current period in clients date-range component and adds test
* fixes issues with enabled state for client counts
* updates parseAPITimestamp to handle date object formatting
* removes unnecesarry type casting for format return in parseAPITimestamp util
* updates parseAPITimestamp to use formatInTimeZone for strings
* updates parseAPITimestamp comment
* updates enabled value in clients config component to boolean
* adds date-fns-tz to core addon
* removes parseISO from date-formatters util in favor of new Date
* updates comments for client counts
* updates retention months validation for client counts config
* updates comment and min retention months default for client counts config
Co-authored-by: Jordan Reimer <zofskeez@gmail.com>
* remove cluster route and model boundary route mixins
* add copyright header
* remove old unit test
* change replication/application route
* don't use cluster route in replication
* why have a base class at all?
* test tweaks
* remove afterModel redirect in replication
* refactor targetRouteName to use derived state
* Update route class name on replication-dr-promote.js
---------
Co-authored-by: Matthew Irish <39469+meirish@users.noreply.github.com>
Co-authored-by: claire bontempo <68122737+hellobontempo@users.noreply.github.com>
* convert to typescript
* move getOptions to namespace service
* delete unneeded ts file
* add test coverage and cleanup getOptions method
* use new admin const
Co-authored-by: claire bontempo <68122737+hellobontempo@users.noreply.github.com>
Allow for console error and warn and fail for everything else.
Remove disable rules for console.
Co-authored-by: Angelo Cordon <angelo.cordon@hashicorp.com>
* updates kmip scope roles route to ts
* updates kmip scope roles route to use api service and adds page component
* converts kmip role route to ts
* fixes a11y error in kmip header-credentials component
* updates kmip role route to use api service and adds page component
* removes kmip operation-field-display component that was moved into role page component
* converts kmip role create route to ts
* moves kmip role form component to component directory root
* converts kmip role form component to ts
* adds operation-groups helper and refactors kmip role page to use it
* adds operation-label helper and updates kmip role page to use it
* converts kmip edit role route to ts
* updates kmip role test to use operation-groups helper
* adds kmip role form
* updates kmip role edit and create routes to use api service and form class
* updates kmip role form component to work with form class
* updates kmip acceptance tests
* converts kmip credentials index route to ts
* updates kmip credentials route to use api service
* adds kmip credentials page component
* converts kmip credentials show route to ts
* updates kmip credentials show route to use api service and adds page component
* fixes flash message issue on kmip role form submit success
* converts kmip credentials generate route to ts
* reverts kmip credentials show page component in favor of details-credentials component which is also used in generate route
* fixes kmip details-credentials tests
* update kmip credentials generate route to use api service and updates page component
* removes store and pagination services from kmip engine
* converts kmip breadcrumb component to ts
* converts kmip header scope component to ts
* removes kmip Ember Data models and adapters
* removes store reference from kmip acceptance tests
* fixes issues routing back to secrets engine via breadcrumb in kmip roles and credentials routes
* removes kmip role adapter test
* updates open api helpers tests
Co-authored-by: Jordan Reimer <zofskeez@gmail.com>
* add support for initializing with capability paths
* only render flyout for enterprise versions
* update PolicyStanza to support object
* add policy generator to kv
* only set preset stanzas if no changes have been made
* add test coverage for kv adding policy generate to page headers
* add community test
* add test coverage to capabilities service
* add changelog
* add close callback
Co-authored-by: claire bontempo <68122737+hellobontempo@users.noreply.github.com>
* [VAULT-33083] UI: followup pr to update helper syntax to follow best practices
* fix test failures
Co-authored-by: Shannon Roberts (Beagin) <beagins@users.noreply.github.com>
* [VAULT-33083] UI: support builtin plugins as external plugins
* address copilot review comments
* add changelog
* remove unused id property
* address some nits & add test coverage
* should use utils instead of mixins
* update comments
* move/consolidate logic for 'transform' engine type into ENGINE_TYPE_TO_MODEL_TYPE_MAP, added/updated test coverage
* cleanup: extract transform engine model type logic into helper functions
* address pr comment
* separation of concerns - move relevant vars/fns from all engines metadata to external plugin helpers & secret engine model helpers files
* add TODO; remove unnecessary exports
* rename secret-engine-model-helpers to secret-engine-helpers
* update unknown engine metadata from var to fn to handle a methodType param
* remove unnecessary test
* update changelog; return methodType for unknown engine metadata, simplify code for readability
* add optional chaining for fail-safe
* address kvv1 edge case - on exit configuration, kvv1 should redirect to list-root while kvv2 should redirect to the engineRoute defined in all-engines-metadata
* add ibm header
* fix test failure after updating unknown engine type
Co-authored-by: Shannon Roberts (Beagin) <beagins@users.noreply.github.com>
* converts kubernetes overview page component to ts
* converts kubernetes role index controller to ts
* updates kubernetes overview to use api service
* removes store service from kubernetes engine
* removes kubernetes models, adapters and serializers
* removes unused types
* updates removed type references
* removes fetch-secrets-config decorator
Co-authored-by: Jordan Reimer <zofskeez@gmail.com>
* removes withConfig decorator and moves check to application route
* updates backendModel references in ldap engine to secretsEngine
* adds ldap config form class
* updates ldap config type in application route
* updates ldap configure and configuration routes to use api service
* adds capabilities service to ldap engine
* updates ldap mirage handler and scenario
* adds ldap capabilities constants and helper for fetching capabilities for roles
* updates ldap roles view to use api service
* updates ldap role details view to use api service
* updates ldap role create/edit views to use api service and form classes
* updates ldap role subdirectory view to use api service
* updates ldap role credentials view to use api service
* updates ldap libraries list views to use api service
* updates ldap library details view to use api service
* updates ldap library details accounts view to use api service
* updates ldap library details accounts check out view to use api service
* updates ldap library details configuration view to use api service
* updates ldap library create/edit workflows to use api service and form class
* fixes lint errors
* updates ldap overview to use api service
* updates ldap overview tests
* removes store and pagination services from ldap engine
* removes ldap related ember data files
* updates path_to_library var casing
Co-authored-by: Jordan Reimer <zofskeez@gmail.com>
* removes store query from pki config route
* updates pki overview route to use api service
* removes remaining references to store in pki tests
* removes unused store service injections in pki components
* removes store dependency from pki engine
* removes ember data related unit tests for pki
* removes pki ember data models, adapters and serializers
* removes unused pagination service injections in config-ui, kv, pki and sync engines
* removes unused store service injections from pki engine
* updates dashboard quick-actions-card component to fetch options using api service
* removes path-help test using pki model
Co-authored-by: Jordan Reimer <zofskeez@gmail.com>
* license: update headers to IBM Corp.
* `make proto`
* update offset because source file changed
Signed-off-by: Ryan Cragun <me@ryan.ec>
Co-authored-by: Ryan Cragun <me@ryan.ec>
* updating routes from mounts/ to enable and updates to breadcrumbs
* updating all relevant tests
* leftover tests
Co-authored-by: Dan Rivera <dan.rivera@hashicorp.com>
* UI Fix: UI permissions banner and side bar nav gating respect Vault glob semantics (+, deny precedence) (#9522)
* add in empty states when no permissions error but no list values found.
* wip
* wip cont.
* a lot closer... I think
* looking good, now to smoke test (Again)
* welp revert fix to adapter that borked it.
* add changelog
* test coverage—a lot
* fix some issues with root vs fallback show sidebar nav
* address pr comments and clean up comments and left over duplicate methods in permission service
* Apply suggestion from @hellobontempo
Co-authored-by: claire bontempo <68122737+hellobontempo@users.noreply.github.com>
* add resultant-acl in canary paths
* remove from canary and use capability check instead inside permissionsBanner
* clean up
* fix merge things
---------
Co-authored-by: claire bontempo <68122737+hellobontempo@users.noreply.github.com>
* add conditional for enterprise vs ce
---------
Co-authored-by: Angel Garbarino <Monkeychip@users.noreply.github.com>
Co-authored-by: claire bontempo <68122737+hellobontempo@users.noreply.github.com>
Co-authored-by: Angel Garbarino <argarbarino@gmail.com>
* adds error handling for control groups to api service as post request middleware
* updates kv list route to use api service
* updates kv config route to use api service
* updates kv secrets overview route to use api service
* updates kv secret details route to use api service
* adds kv form
* updates kv metadata details route to use api service
* updates kv paths and version history routes to use api service
* refactors kv-data-fields component to form component
* updates kv secret create route to use api service
* updates kv secret edit route to use api service
* updates kv metadata edit route to use api service
* adds waitFor to async middleware in api service to attempt to fix race conditions in tests
* adds kvMetadata path to capabilities path map
* fixes kv list item delete test selector
* removes kv models, adapters and serializers
* removes store from kv addon
* removes ember data related test helpers from kv-run-commands
* updates comments that referred to kv ember data models
* updates kv-page-header tests
* updates model-form-fields test to use totp-key model rather than kv/data
* removes another reference to kv/data model from path-help test
* fixes kv v2 workflow create tests
* fixes issue returning metadata for secret when latest version is deleted
* decodes uri in path returned by api service parseError method
* fixes kv v2 edge cases tests
* fixes issue deleteing control group token in api service
* decodes url for control group token lookup in api service
* fixes version history linked block link
* defaults cas to 0 when creating new secret
* removes log
* adds ember-template-lint to kv engine
* more test fixes
* updates kv-suggestion-input component to use api service
* removes kv metadata model reference from quick actions card
* fixes sync destination sync secrets tests
* updates kv helpers from classic format
* updates kv helpers imports
* reverts to use secret.version in details edit route
* fixes isDeleted import in kv version history test
* adds waitFor to api service parseError method
* reverts removing async from addQueryParams api method
* attempts to fix test flakiness requesting custom metadata from data endpoint
* more tweaks to requesting metadata from data
* adds waitFor to requestData method
Co-authored-by: Jordan Reimer <zofskeez@gmail.com>
* adds error handling for control groups to api service as post request middleware
* updates kv list route to use api service
* updates kv config route to use api service
* updates kv secrets overview route to use api service
* updates kv secret details route to use api service
* adds kv form
* updates kv metadata details route to use api service
* updates kv paths and version history routes to use api service
* refactors kv-data-fields component to form component
* updates kv secret create route to use api service
* updates kv secret edit route to use api service
* updates kv metadata edit route to use api service
* adds waitFor to async middleware in api service to attempt to fix race conditions in tests
* adds kvMetadata path to capabilities path map
* fixes kv list item delete test selector
* fixes kv v2 workflow create tests
* fixes issue returning metadata for secret when latest version is deleted
* decodes uri in path returned by api service parseError method
* fixes kv v2 edge cases tests
* fixes issue deleteing control group token in api service
* decodes url for control group token lookup in api service
* fixes version history linked block link
* defaults cas to 0 when creating new secret
* removes log
* adds ember-template-lint to kv engine
* more test fixes
* updates kv helpers from classic format
* updates kv helpers imports
* reverts to use secret.version in details edit route
* fixes isDeleted import in kv version history test
* adds waitFor to api service parseError method
* reverts removing async from addQueryParams api method
Co-authored-by: Jordan Reimer <zofskeez@gmail.com>
* adds error handling for control groups to api service as post request middleware
* adds waitFor to async middleware in api service to attempt to fix race conditions in tests
Co-authored-by: Jordan Reimer <zofskeez@gmail.com>
* add error handling for permission denied
* one more for the error handling business
* remove date range alert
* add more test coverage to date formatters
* update date querying and test coverage
* one more lil cleanup
Co-authored-by: claire bontempo <68122737+hellobontempo@users.noreply.github.com>
* removes api client in favor of dependency
* removes api-client path from ignore files and configs
* removes normalize keys method from api service
* removes normalize keys test for api service
* updates api client vars to snake_case for custom messages
* updates api client vars to snake_case for tools
* updates api client vars to snake_case for sync
* updates api client vars to snake_case for secrets engine
* updates api client vars to snake_case for auth
* updates api client vars to snake_case for usage
* updates api client dep to point to gh repo
* fixes custom-messages service unit tests
* fixes configure-ssh test
* fixes configure-ssh test...again
* test coverage for namespace capabilities checks;
* set namespace header with appropriate context
* add more test coverage, restore stub
* add changelog
* change entity_id to camel casing, remove "backends" key from stored auth data
* fix tokenExpirationEpoch returning NaN, use authSuccess in auth service tests
* camel case mfa_requirement references
* refactor auth service
* implement api service for token method
* implement api service in standard auth methods
* add lookupSelf request to persistAuthData method in auht service instead of calling in components
* implement api service in oidc-jwt component
* implement api service in okta component
* implement api service in saml component
* use api service for wrapped_token query param
* remaining test updates, enterprise tests and stabilize auth helpers
* upate renew() to use new persistAuthData method, add a test
* revert as this will be addressed upstream
* rename supported-login-methods to auth-form-helpers and delete old supported-auth-backends helper, update tests
* cleanup normalize after testing mfa validation for each auth method
* update type declarations, set displayName in each method component
* stabilize redirect tests by waiting for login before asserting url
* stabilize tests
* modernize typescript syntax, move error const to util
* use mirage instead of vault server to resolve test race conditions
* fix file import
* [UI] Ember Data Migration - Secrets Engine Resource (#30791)
* adds base factory for resources and secrets engine resource
* updates dashboard and secret-engine list route to fetch mounts from api service
* updates secret backends routes to use api service
* updates secrets engine config routes to use api service
* updates secrets backend route to use internal mounts endpoint and fixes error handling
* updates property casing in config details card component
* fixes dashboard tests
* fixes issues with engine configuration
* updates api service to only set token header if value is defined in auth service
* fixes more tests
* Update ui/app/routes/vault/cluster/secrets/backend/configuration/index.js
Co-authored-by: Angel Garbarino <Monkeychip@users.noreply.github.com>
* removes alwaysRender from publicKey field in secret engine configuration details component
* removes unused hideToggle arg from secret engine mount config template
* updates kv config route to load secret-engine model
* fixes kv config route
---------
Co-authored-by: Angel Garbarino <Monkeychip@users.noreply.github.com>
* [UI] Ember Data Migration - Secrets Engine Forms (#30951)
* adds secrets engine form class
* updates mount-secret-backend route and form component to use secrets engine form class and api service
* updates to form class proxy for nested form data properties
* adds form classes for configurable secrets engines
* updates secrets engine config edit route and components to use form classes and api service
* adds missing copyright header
* fixes tests
* fixes type error
* updates configure-ssh component to use form class and api service
* updates configure-ssh tests
* updates configuration-wif component tests
* fixes mount secret backend and form tests
* adds method to normalize request key casing to api service
* addresses pr review feedback
* removes unused secrets engine config models, adapters and serializers (#30980)
* fixes azure config tests
* fixes more ent tests
---------
Co-authored-by: Angel Garbarino <Monkeychip@users.noreply.github.com>
* add dummy provider and wire it into the app
* add tests for analytics service
* add posthog provider
* wire in posthog
* add HVD limitation for analytics and add unit test
* filter out sensitive event properties
* add changelog
* run copywrite headers
* update logging tests for analytics service
* update changelog format
* disable telemetry in test mode
* remove unnecessary test
* self review
* Update vault-reporting addon with analytics tracking changes
* address review feedback
---------
Co-authored-by: Jim Wright <jim.wright@hashicorp.com>
* UI: Move `wrapped_token` login functionality to route (#30465)
* move token unwrap functionality to page component
* update mfa test
* remove wrapped_token logic from page component
* more cleanup to relocate unwrap logic
* move wrapped_token to route
* move unwrap tests to acceptance
* move mfa form back
* add some padding
* update mfa-form tests
* get param from params
* wait for auth form on back
* run rests
* UI: Add MFA support for SSO methods (#30489)
* initial implementation of mfa validation for sso methods
* update typescript interfaces
* add stopgap changes to auth service
* switch order backend is defined
* update login form for tests even though it will be deleted
* attempt to stabilize wrapped_query test
* =update login form test why not
* Update ui/app/components/auth/form/saml.ts
Co-authored-by: lane-wetmore <lane.wetmore@hashicorp.com>
---------
Co-authored-by: lane-wetmore <lane.wetmore@hashicorp.com>
* Move CSP error to page component (#30492)
* initial implementation of mfa validation for sso methods
* update typescript interfaces
* add stopgap changes to auth service
* switch order backend is defined
* update login form for tests even though it will be deleted
* attempt to stabilize wrapped_query test
* =update login form test why not
* move csp error to page component
* move csp error to page component
* Move fetching unauthenticated mounts to the route (#30509)
* rename namespace arg to namespaceQueryParam
* move fetch mounts to route
* add margin to sign in button spacing
* update selectors for oidc provider test
* add todo delete comments
* fix arg typo in test
* change method name
* fix args handling tab click
* remove tests that no longer relate to components functionality
* add tests for preselectedAuthType functionality
* move typescript interfaces, fix selector
* add await
* oops
* move format method down, make private
* move tab formatting to the route
* move to page object
* fix token unwrap aborting transition
* not sure what that is doing there..
* add comments
* rename to presetAuthType
* use did-insert instead
* UI: Implement `Auth::FormTemplate` (#30521)
* replace Auth::LoginForm with Auth::FormTemplate
* first round of test updates
* return null if mounts object is empty
* add comment and test for empty sys/internal/mounts data
* more test updates
* delete listing_visibility test, delete login-form component test
* update divs to Hds::Card::Container
* add overflow class
* remove unused getters
* move requesting stored auth type to page component
* fix typo
* Update ui/app/components/auth/form/oidc-jwt.ts
make comment make more sense
* small cleanup items, update imports
* Delete old auth components (#30527)
* delete old components
* update codeowners
* Update `with` query param functionality (#30537)
* update path input to type=hidden
* add test coverage
* update page test
* update auth route
* delete login form
* update ent test
* consolidate logic in getter
* add more comments
* more comments..
* rename selector
* refresh model as well
* redirect for invalid query params
* move unwrap to redirect
* only redirect on invalid query params
* add tests for query param
* test selector updates
* remove todos, update relevant ones with initials
* add changelog
---------
Co-authored-by: lane-wetmore <lane.wetmore@hashicorp.com>
* improves path handling in capabilities service
* converts has-capability to class helper and adds pathKey and params args
* adds api service to sync engine
* updates sync types
* improves typings in paginate-list util
* adds api client error handling to error page component
* adds api utils for sync
* updates sync overview route and page component to use api service
* updates sync destinations route and page component to use api service
* adds missing copyright header
* fixes paginate-list regression
* fixes return type for has-capability helper
* Apply suggestions from code review
Co-authored-by: Angel Garbarino <Monkeychip@users.noreply.github.com>
* fixes page error tests
* resolves suggestions from review
* fixes has-capability usage errors
* fixes comment in capabilities service
* more test fixes
---------
Co-authored-by: Angel Garbarino <Monkeychip@users.noreply.github.com>