Skip to content
Snippets Groups Projects
This project is mirrored from https://github.com/metabase/metabase. Pull mirroring updated .
  1. Jun 02, 2022
    • adam-james's avatar
      Adjust JWT and SAML fetch-and-update user to save new attributes (#23005) · 174afe58
      adam-james authored
      * Adjust JWT and SAML fetch-and-update user to save new attributes
      
      Before this change, JWT/SAML logins would attempt to update attributes, but never considered the first-name or
      last-name attributes.
      
      * Attempts to fix tests to prevent pulluting test users with "Unknown"
      
      * No deleting users.
      
      * Unit tests checking that first/last names are updated for SSO users
      
      When an SSO user is first logged in, they might not have first_name and/or last_name keys. This is allowed, but the
      names will be "Unknown" in the app-db. Subsequently, a User may log in again with SSO but have fisrt/last name
      attributes, which should update the Metabase user data in the app-db.
      
      These unit tests set up such a scenario to check that the :first_name and :last_name keys are indeed updated.
      
      * Adjust Enterprise LDAP to also use SSO-UTILS
      
      Trying to unify the LDAP implementation with JWT/SAML a bit here.
      
      * Lint error
      
      * Reverting LDAP n...
      Unverified
      174afe58
  2. May 13, 2022
    • Howon Lee's avatar
      No open redirects for enterprise SSO's (#22622) · f3f9c627
      Howon Lee authored
      Open redirects means doing some sso with a built-in redirect, and redirecting into an unhappy place (aka, a non-MB place) afterwards so that someone gets phished or other bad things happen. This is already prevented for OSS sso's but not EE - prevents this for EE sso's by forcing redirects to be in MB `site-url` set domain.
      Unverified
      f3f9c627
  3. May 02, 2022
    • Braden Shepherdson's avatar
      One Clojure lint to rule them all (#22213) · 390d10e5
      Braden Shepherdson authored
      Background:
      
      We had two lint configs: lint-config.edn which was enfored by Github Actions, and
      .clj-kondo/config.edn, the default location used by editors.
      
      
      Problem:
      
      Patchy enforcement of the (larger) config in .clj-kondo/config.edn since not
      everyone uses an editor.
      
      Some new lint, like canonical namespace aliases (#21738, #19930) is not enforced
      automatically and has begun to bit-rot.
      
      Solution:
      
      Combine both configs, fix any outstanding lint, and update our tooling to use
      the unified config.
      
      Caveats:
      
      Anyone who has their local editor configured to use lint-config.edn will have
      their linting broken by this change.
      Unverified
      390d10e5
  4. Apr 19, 2022
    • Braden Shepherdson's avatar
      Make namespace aliasing consistent everywhere; enforce with clj-kondo (#21738) · 19beda53
      Braden Shepherdson authored
      * Make namespace aliasing consistent everywhere; enforce with clj-kondo
      
      See the table of aliases in .clj-kondo/config.edn
      
      Notable patterns:
      - `[metabase.api.foo :as api.foo]`
      - `[metabase.models.foo :as foo]`
      - `[metabase.query-processor.foo :as qp.foo]`
      - `[metabase.server.middleware.foo :as mw.foo]`
      - `[metabase.util.foo :as u.foo]`
      - `[clj-http.client :as http]` and `[metabase.http-client :as client]`
      
      Fixes #19930.
      Unverified
      19beda53
  5. Apr 07, 2022
    • Ngoc Khuat's avatar
      Fix SSO failed to sync admin group (#20991) · 0708ce0a
      Ngoc Khuat authored
      * fix failed to sync admin group
      
      * address noah's comments and add migration script
      
      * document for run-with-data-migration-index
      
      * update comments
      
      * fix name space
      
      * adding data_migrations tests
      
      * add docg
      
      * make sure we don't remove admin group if sso and ldap are not configured
      
      * fix tests for be-ee
      
      * fix tests for oss
      
      * misc docs updates
      
      * remove data-migration-index
      
      * return some newlines
      
      * is it failling here?
      
      * update data_migration docs
      
      * update data_migration docs
      
      * fix all styling comments
      
      * make migration to run both in oss and enterprise and make sure the tests are accounted for that
      
      * fix failed namespace checks
      
      * Add a comment to the test
      
      * fix per comments
      
      * Update permissions.clj
      
      * tweaking with the :warning: icon
      
      * refactor with-temporary-raw-setting-values
      
      * update comments
      
      * Add extension for cert file
      
      * address Noah's comments
      Unverified
      0708ce0a
  6. Jan 04, 2022
    • adam-james's avatar
      JWT Login URL configured by user may have URL parameters (#19381) · 4448b34d
      adam-james authored
      * JWT Login URL configured by user may have URL parameters
      Since params may already exist in the login URL, a check is performed to make sure the generated URL
      with 'return_to' param formats correctly. If a param already exists, all subsequent params should
      have an '&
      character.
      
      * Sorted ns to pass linting
      
      * added issue number to test string for added context.
      Unverified
      4448b34d
  7. Dec 28, 2021
    • Cam Saul's avatar
      Database-local Settings (#19399) · b9bee5dc
      Cam Saul authored
      * Rename setting/get and setting/all; GeoJSON via env var tests
      
      * Fix typo (thanks @noahmoss)
      
      * Support Database-local Settings in metabase.models.setting itself
      
      * Rework Settings code so it can handle possibly-already-deserialized values
      
      * Database-local Settings
      
      * Remove empty part of docstring
      
      * Appease linters
      
      * Update dox again
      
      * Use text.type for the new column
      
      * Test fixes :wrench:
      
      * Test fix :wrench:
      
      * Test fix :wrench:
      
      * All negative integer values when setting :integer Setting with a string
      Unverified
      b9bee5dc
  8. Sep 29, 2021
  9. Jun 10, 2021
  10. Jun 08, 2021
  11. May 03, 2021
    • Noah Moss's avatar
      Return 401 on auth failure instead of 400 (#15883) · e02187e5
      Noah Moss authored
      * Change 400 errors to 401s on failed authentication
      
      * remove TODO comment
      
      * return 401 for expired JWT in enterprise code
      
      * keep existing exception message when JWT is expired
      
      * fix test failures
      
      * remove comment about timeout on CI that's no longer relevant
      Unverified
      e02187e5
  12. Mar 31, 2021
    • Cam Saul's avatar
      Fix SAML redirect to with certain URLs e.g. /collection/root (#15410) · 18d1e9cf
      Cam Saul authored
      * Fix SAML redirect to /collection/root/
      
      * Test util HTTP client should automatically URL-encode query parameters.
      
      * Simplify HTTP client
      
      * Minor tweaks
      
      * Remove *url-encode-query-parameters?*
      
      * experimental CI fix: cache build script deps
      
      * Fix typo
      
      * Fix Circle config again
      
      * Fetch BE deps if deps.edn files change
      
      * Use CI executor for be-deps, so we have the Clojure CLI
      Unverified
      18d1e9cf
    • Cam Saul's avatar
      Fix exports not being in report timezone :calendar: (#15415) · fd8b5544
      Cam Saul authored
      * Bump a few dep versions and add missing exclusions
      
      * Fix export timezones; fix Excel time values
      
      * Text fixes & other improvements
      
      * Test fix :wrench:
      
      * Move some XLSX/CSV specific tests into appropriate test namespaces
      
      * Fix SQLite parsing of date-only values
      
      * address PR feedback
      Unverified
      fd8b5544
  13. Mar 19, 2021
    • Cam Saul's avatar
      Record login history (#15129) · 3a5eface
      Cam Saul authored
      * Record login history [WIP]
      
      * WIP
      
      * Add API endpoint and ugly React component
      
      * Fix fn name
      
      * Lookin good
      
      * Test fixes :wrench:
      
      * Prettier
      
      * Test fix
      
      * Test fixes :wrench:
      
      * Better login history info
      
      * Less ugly login history & tests
      
      * Update migration numbers
      
      * Deduplicate https-request? util function from metabase.server.middleware .session & .util
      
      * Refactor -- new Ring request utils namespace
      
      * Test fixes :wrench:
      
      * Reorganize stuff a bit; API endpoint tests
      
      * Tests for login/logout recording history
      
      * Test fix :wrench:
      
      * Test fixes :wrench:
      
      * Test fix :wrench:
      
      * Copy FE test fixture DB so it stops getting changed every time we run tests
      
      * Test fixes :wrench:
      
      
      
      * layout and code style tweaks
      
      * Fix ns sorting
      
      Co-authored-by: default avatarKyle Doherty <5248953+kdoh@users.noreply.github.com>
      Unverified
      3a5eface
  14. Mar 01, 2021
  15. Jan 07, 2021
  16. Oct 23, 2020
Loading