Commit Graph
53 Commits
Author SHA1 Message Date
Livio AmstutzandGitHub e57d4b1ed4 fix: terminate usersession (#212) 2020-06-11 16:34:54 +02:00
44d41b8d97 fix: failed events (#211)
* fix: add iam roles to permissions

* fix: show state initial on usersearch

* fix: search project roles returns only roles of project

* fix: add project member owner on project create

* fix: create new object oon failed event

* feat: parse error body on chat message

* feat: remove comment

* fix: set policy eventstore in admin

* fix failed events

* fix resend for password set

* fix: create user with correct resource owner

Co-authored-by: Fabiennne <[email protected]>
2020-06-11 14:59:57 +02:00
Livio AmstutzandGitHub fb3a5c94a0 fix: secrets to env vars mapping (#209) 2020-06-11 11:21:29 +02:00
Livio AmstutzandGitHub 9cd7f69e61 add caos to admin and auth proto package (#190) 2020-06-09 09:22:37 +02:00
Livio AmstutzandGitHub 5e931a3c13 fix: console env directory (#189)
* fix: serve console env from os (not statik)

* ZITADEL_CONSOLE_ENV_PATH for (local) overwrite possibility

* name EnvOverwritePath

* fix: console env directory

* fix mount path

* fix default dir
2020-06-09 08:44:55 +02:00
Livio AmstutzandGitHub 0da6dc1d66 fix: serve console env from os (not statik) (#187)
* fix: serve console env from os (not statik)

* ZITADEL_CONSOLE_ENV_PATH for (local) overwrite possibility

* name EnvOverwritePath
2020-06-09 07:38:44 +02:00
Livio AmstutzandGitHub 2acad11196 fix deployment.yaml env (#186) 2020-06-08 08:33:54 +02:00
8a5badddf6 feat: Login, OP Support and Auth Queries (#177)
* fix: change oidc config

* fix: change oidc config secret

* begin models

* begin repo

* fix: implement grpc app funcs

* fix: add application requests

* fix: converter

* fix: converter

* fix: converter and generate clientid

* fix: tests

* feat: project grant aggregate

* feat: project grant

* fix: project grant check if role existing

* fix: project grant requests

* fix: project grant fixes

* fix: project grant member model

* fix: project grant member aggregate

* fix: project grant member eventstore

* fix: project grant member requests

* feat: user model

* begin repo

* repo models and more

* feat: user command side

* lots of functions

* user command side

* profile requests

* commit before rebase on user

* save

* local config with gopass and more

* begin new auth command (user centric)

* Update internal/user/model/user.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/model/address.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/model/address.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/model/email.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/model/email.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/model/email.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/model/mfa.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/model/mfa.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/model/password.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/model/password.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/model/password.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/model/phone.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/model/phone.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/model/phone.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/model/user.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/model/user.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/model/user.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/usergrant/repository/eventsourcing/model/user_grant.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/usergrant/repository/eventsourcing/model/user_grant.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/usergrant/repository/eventsourcing/user_grant.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/user_test.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/eventstore_mock_test.go

Co-Authored-By: Livio Amstutz <[email protected]>

* changes from mr review

* save files into basedir

* changes from mr review

* changes from mr review

* move to auth request

* Update internal/usergrant/repository/eventsourcing/cache.go

Co-authored-by: Silvan <[email protected]>

* Update internal/usergrant/repository/eventsourcing/cache.go

Co-authored-by: Silvan <[email protected]>

* changes requested on mr

* fix generate codes

* fix return if no events

* password code

* email verification step

* more steps

* lot of mfa

* begin tests

* more next steps

* auth api

* auth api (user)

* auth api (user)

* auth api (user)

* differ requests

* merge

* tests

* fix compilation error

* mock for id generator

* Update internal/user/repository/eventsourcing/model/password.go

Co-authored-by: Silvan <[email protected]>

* Update internal/user/repository/eventsourcing/model/user.go

Co-authored-by: Silvan <[email protected]>

* requests of mr

* check email

* begin separation of command and query

* otp

* change packages

* some cleanup and fixes

* tests for auth request / next steps

* add VerificationLifetimes to config and make it run

* tests

* fix code challenge validation

* cleanup

* fix merge

* begin view

* repackaging tests and configs

* fix startup config for auth

* add migration

* add PromptSelectAccount

* fix copy / paste

* remove user_agent files

* fixes

* fix sequences in user_session

* token commands

* token queries and signout

* fix

* fix set password test

* add token handler and table

* handle session init

* add session state

* add user view test cases

* change VerifyMyMfaOTP

* some fixes

* fix user repo in auth api

* cleanup

* add user session view test

* fix merge

* begin oidc

* user agent and more

* config

* keys

* key command and query

* add login statics

* key handler

* start login

* login handlers

* lot of fixes

* merge oidc

* add missing exports

* add missing exports

* fix some bugs

* authrequestid in htmls

* getrequest

* update auth request

* fix userid check

* add username to authrequest

* fix user session and auth request handling

* fix UserSessionsByAgentID

* fix auth request tests

* fix user session on UserPasswordChanged and MfaOtpRemoved

* fix MfaTypesSetupPossible

* handle mfa

* fill username

* auth request query checks new events

* fix userSessionByIDs

* fix tokens

* fix userSessionByIDs test

* add user selection

* init code

* user code creation date

* add init user step

* add verification failed types

* add verification failures

* verify init code

* user init code handle

* user init code handle

* fix userSessionByIDs

* update logging

* user agent cookie

* browserinfo from request

* add DeleteAuthRequest

* add static login files to binary

* add login statik to build

* move generate to separate file and remove statik.go files

* remove static dirs from startup.yaml

* generate into separate namespaces

* merge master

* auth request code

* auth request type mapping

* fix keys

* improve tokens

* improve register and basic styling

* fix ailerons font

* improve password reset

* add audience to token

* all oidc apps as audience

* fix test nextStep

* fix email texts

* remove "not set"

* lot of style changes

* improve copy to clipboard

* fix footer

* add cookie handler

* remove placeholders

* fix compilation after merge

* fix auth config

* remove comments

* typo

* use new secrets store

* change default pws to match default policy

* fixes

* add todo

* enable login

* fix db name

* Auth queries (#179)

* my usersession

* org structure/ auth handlers

* working user grant spooler

* auth internal user grants

* search my project orgs

* remove permissions file

* my zitadel permissions

* my zitadel permissions

* remove unused code

* authz

* app searches in view

* token verification

* fix user grant load

* fix tests

* fix tests

* read configs

* remove unused const

* remove todos

* env variables

* app_name

* working authz

* search projects

* global resourceowner

* Update internal/api/auth/permissions.go

Co-authored-by: Livio Amstutz <[email protected]>

* Update internal/api/auth/permissions.go

Co-authored-by: Livio Amstutz <[email protected]>

* model2 rename

* at least it works

* check token expiry

* search my user grants

* remove token table from authz

Co-authored-by: Livio Amstutz <[email protected]>

* fix test

* fix ports and enable console

Co-authored-by: Fabiennne <[email protected]>
Co-authored-by: Fabi <[email protected]>
Co-authored-by: Silvan <[email protected]>
2020-06-05 07:50:04 +02:00
Livio AmstutzandGitHub a6aba86b54 fix: setup (start admin first and ensure setup done) (#126)
* start admin first and ensure setup done

* enable login again

* log oidc client_id in setup

* more logs for setup
2020-05-25 08:21:58 +02:00
Livio AmstutzandGitHub f14d4cc655 fix management user view and user session handler (#124) 2020-05-19 07:07:58 +02:00
effc2c23c2 feat: add auth command side (#107)
* fix: query tests

* fix: use prepare funcs

* fix: go mod

* fix: generate files

* fix(eventstore): tests

* fix(eventstore): rename modifier to editor

* fix(migrations): add cluster migration,
fix(migrations): fix typo of host in clean clsuter

* fix(eventstore): move health

* fix(eventstore): AggregateTypeFilter aggregateType as param

* code quality

* fix: go tests

* feat: add member funcs

* feat: add member model

* feat: add member events

* feat: add member repo model

* fix: better error func testing

* fix: project member funcs

* fix: add tests

* fix: add tests

* feat: implement member requests

* fix: merge master

* fix: merge master

* fix: read existing in project repo

* fix: fix tests

* feat: add internal cache

* feat: add cache mock

* fix: return values of cache mock

* feat: add project role

* fix: add cache config

* fix: add role to eventstore

* fix: use eventstore sdk

* fix: use eventstore sdk

* fix: add project role grpc requests

* fix: fix getby id

* fix: changes for mr

* fix: change value to interface

* feat: add app event creations

* fix: searchmethods

* Update internal/project/model/project_member.go

Co-Authored-By: Silvan <[email protected]>

* fix: use get project func

* fix: append events

* fix: check if value is string on equal ignore case

* fix: add changes test

* fix: add go mod

* fix: add some tests

* fix: return err not nil

* fix: return err not nil

* fix: add aggregate funcs and tests

* fix: add oidc aggregate funcs and tests

* fix: add oidc

* fix: add some tests

* fix: tests

* feat: eventstore repository

* fix: remove gorm

* version

* feat: pkg

* feat: eventstore without eventstore-lib

* rename files

* gnueg

* fix: global model

* feat: add global view functions

* feat(eventstore): sdk

* fix(eventstore): rename app to eventstore

* delete empty test

* fix(models): delete unused struct

* feat(eventstore): overwrite context data

* fix: use global sql config

* fix: oidc validation

* fix: generate client secret

* fix: generate client id

* fix: test change app

* fix: deactivate/reactivate application

* fix: change oidc config

* fix: change oidc config secret

* begin models

* begin repo

* fix: implement grpc app funcs

* fix: add application requests

* fix: converter

* fix: converter

* fix: converter and generate clientid

* fix: tests

* feat: project grant aggregate

* feat: project grant

* fix: project grant check if role existing

* fix: project grant requests

* fix: project grant fixes

* fix: project grant member model

* fix: project grant member aggregate

* fix: project grant member eventstore

* fix: project grant member requests

* feat: user model

* begin repo

* repo models and more

* feat: user command side

* lots of functions

* user command side

* profile requests

* commit before rebase on user

* save

* local config with gopass and more

* begin new auth command (user centric)

* Update internal/user/model/user.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/model/address.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/model/address.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/model/email.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/model/email.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/model/email.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/model/mfa.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/model/mfa.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/model/password.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/model/password.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/model/password.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/model/phone.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/model/phone.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/model/phone.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/model/user.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/model/user.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/model/user.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/usergrant/repository/eventsourcing/model/user_grant.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/usergrant/repository/eventsourcing/model/user_grant.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/usergrant/repository/eventsourcing/user_grant.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/user_test.go

Co-Authored-By: Livio Amstutz <[email protected]>

* Update internal/user/repository/eventsourcing/eventstore_mock_test.go

Co-Authored-By: Livio Amstutz <[email protected]>

* changes from mr review

* save files into basedir

* changes from mr review

* changes from mr review

* move to auth request

* Update internal/usergrant/repository/eventsourcing/cache.go

Co-authored-by: Silvan <[email protected]>

* Update internal/usergrant/repository/eventsourcing/cache.go

Co-authored-by: Silvan <[email protected]>

* changes requested on mr

* fix generate codes

* fix return if no events

* password code

* email verification step

* more steps

* lot of mfa

* begin tests

* more next steps

* auth api

* auth api (user)

* auth api (user)

* auth api (user)

* differ requests

* merge

* tests

* fix compilation error

* mock for id generator

* Update internal/user/repository/eventsourcing/model/password.go

Co-authored-by: Silvan <[email protected]>

* Update internal/user/repository/eventsourcing/model/user.go

Co-authored-by: Silvan <[email protected]>

* requests of mr

* check email

* begin separation of command and query

* otp

* change packages

* some cleanup and fixes

* tests for auth request / next steps

* add VerificationLifetimes to config and make it run

* tests

* fix code challenge validation

* cleanup

* fix merge

* begin view

* repackaging tests and configs

* fix startup config for auth

* add migration

* add PromptSelectAccount

* fix copy / paste

* remove user_agent files

* fixes

* fix sequences in user_session

* token commands

* token queries and signout

* fix

* fix set password test

* add token handler and table

* handle session init

* add session state

* add user view test cases

* change VerifyMyMfaOTP

* some fixes

* fix user repo in auth api

* cleanup

* add user session view test

* fix merge

* fixes

* Update internal/auth/repository/eventsourcing/eventstore/auth_request.go

Co-authored-by: Fabi <[email protected]>

* Update internal/auth/repository/eventsourcing/eventstore/auth_request.go

Co-authored-by: Fabi <[email protected]>

* Update internal/auth/repository/eventsourcing/eventstore/auth_request.go

Co-authored-by: Fabi <[email protected]>

* Update internal/auth/repository/eventsourcing/eventstore/auth_request.go

Co-authored-by: Fabi <[email protected]>

* extract method usersForUserSelection

* add todo for policy check

* id on auth req

* fix enum name

Co-authored-by: Fabiennne <[email protected]>
Co-authored-by: adlerhurst <[email protected]>
Co-authored-by: Fabi <[email protected]>
2020-05-18 12:06:36 +02:00
Livio AmstutzandGitHub 380e4d0643 chore: add correct upstream (#84) 2020-05-04 09:14:31 +02:00
livio-aandGitHub ceace305b5 Merge pull request #20 from caos/proto-files
Proto files
2020-03-31 14:18:59 +02:00
livio-aandGitHub c564f47b92 single marshaller 2020-03-30 16:53:29 +02:00
Livio Amstutz 39039dde62 fix tracing/statusFromError 2020-03-30 13:17:49 +02:00
Livio Amstutz affd2da40a update logging version 2020-03-30 11:57:56 +02:00
Livio Amstutz 40e4f69ca3 change context keys and fix tests 2020-03-30 11:52:08 +02:00
Livio Amstutz 96b1817d62 add multi files config test and some more 2020-03-30 11:44:17 +02:00
Livio Amstutz e04c0116f5 refactor crypto tests 2020-03-30 11:26:02 +02:00
Livio Amstutz 106a6ec143 fix test 2020-03-30 10:09:38 +02:00
Livio Amstutz e5e39b3a6a remove pointer on ctxData 2020-03-30 10:06:48 +02:00
Livio Amstutz 501d453822 remove x-grpc-web header in cors 2020-03-30 09:58:55 +02:00
Livio Amstutz 59dc4dbe85 improve some functions 2020-03-30 09:28:00 +02:00
Livio Amstutz fa750a5068 improve some functions 2020-03-30 07:23:43 +02:00
Livio Amstutz b753e06f0b improve some functions 2020-03-30 07:04:21 +02:00
Livio Amstutz f5af4461ad remove pointers on configs 2020-03-27 13:57:16 +01:00
Livio Amstutz f280da5a76 remove empty lines 2020-03-27 13:45:08 +01:00
Livio Amstutz eb1d22c6a3 clarify array_flag.go 2020-03-27 13:44:50 +01:00
Livio Amstutz b9833aa604 change ports 2020-03-25 11:34:49 +01:00
Livio Amstutz 40734f27c7 fix configs 2020-03-25 11:17:38 +01:00
Livio Amstutz 8b23c491f9 Merge branch 'basics' into proto-files
# Conflicts:
#	cmd/zitadel/main.go
#	go.sum
#	pkg/admin/admin.go
#	pkg/auth/auth.go
#	pkg/management/management.go
2020-03-25 11:08:42 +01:00
Livio Amstutz b2bc0b5efd Merge branch 'master' into basics
# Conflicts:
#	cmd/zitadel/main.go
#	go.mod
#	go.sum
#	internal/config/config.go
#	internal/errors/already_exists_test.go
#	internal/errors/caos_error_test.go
#	internal/errors/deadline_exceeded_test.go
#	internal/errors/error_test.go
#	internal/errors/generate/error_creator.go
#	internal/errors/generate/error_test.go.tmpl
#	internal/errors/internal_test.go
#	internal/errors/invalid_argument_test.go
#	internal/errors/not_found_test.go
#	internal/errors/permission_denied_test.go
#	internal/errors/precondition_failed_test.go
#	internal/errors/unauthenticated_test.go
#	internal/errors/unavailable_test.go
#	internal/errors/unimplemented_test.go
#	internal/errors/unknown_test.go
#	pkg/admin/admin.go
#	pkg/auth/auth.go
#	pkg/management/management.go
2020-03-25 10:55:21 +01:00
Livio Amstutz 1aaf721d92 cleanup 2020-03-25 10:41:17 +01:00
Livio Amstutz 6bf96ecbd7 add duration type 2020-03-25 09:32:52 +01:00
Livio Amstutz 5cd9ca506a add basic config and change i18n pkg 2020-03-25 07:58:58 +01:00
Livio Amstutz 96b88f5d8c add tracing and refactor some api pkgs 2020-03-24 14:15:01 +01:00
Livio Amstutz a5ca611dcc fix path in error_creator.go message 2020-03-24 07:22:31 +01:00
Livio Amstutz 6deb0b029a add tests for config 2020-03-23 16:31:26 +01:00
Livio Amstutz ecb894258f remove eventstore flag from cmd 2020-03-23 14:25:01 +01:00
Livio Amstutz 5843bac5f9 ad i18n and renderer and move headers 2020-03-23 13:26:05 +01:00
Livio Amstutz 781e8b215e feat: add protoc pkg 2020-03-23 11:53:12 +01:00
Livio Amstutz 265ea450b1 fix: import 2020-03-23 08:43:08 +01:00
Livio Amstutz 90342ed872 feat: add crypto pkg 2020-03-23 07:06:44 +01:00
Livio Amstutz c89397e1b4 feat: add some api packages 2020-03-23 07:01:59 +01:00
Livio Amstutz 021ee07350 fix: imports in error pkg tests 2020-03-23 06:34:08 +01:00
livio-aandGitHub 87d5cd3f09 Init (#17)
* add basic gitignore

* init go mod

* add semrel and badges

* add error pkg

* added config pkg

* added main cmd structure

* return error on file not found and added log ids and messages

* add todo for error_creator.go
2020-03-19 14:39:06 +01:00
Livio Amstutz 7ef62528d1 return error on file not found and added log ids and messages 2020-03-19 08:32:47 +01:00
Livio Amstutz af8905036b added main cmd structure 2020-03-18 15:46:41 +01:00
Livio Amstutz d3cb575e1d added config pkg 2020-03-18 15:45:55 +01:00
Livio Amstutz 238347ddfb add error pkg 2020-03-18 15:45:24 +01:00
Livio Amstutz f8fdbb0611 add semrel and badges 2020-03-18 11:39:48 +01:00
Livio Amstutz 5b1d6a6cf8 init go mod 2020-03-18 10:38:32 +01:00
Livio Amstutz 093bfee31b add basic gitignore 2020-03-18 10:30:18 +01:00