Commit Graph

1227 Commits

Author SHA1 Message Date
Jens Langhammer 0ca7579d19 ci: attempt to fix e2e not a tty error 2020-06-07 19:57:01 +02:00
Jens Langhammer 2291ae98c3 e2e: fix lint error 2020-06-07 19:50:01 +02:00
Jens Langhammer 16c6e29801 root: add missing selenium 2020-06-07 19:44:28 +02:00
Jens Langhammer fc2eb003ea e2e: add apply_default_data to load data from migrations after tables have been truncated 2020-06-07 19:31:16 +02:00
Jens Langhammer aa440c17b7 Merge branch 'master' into e2e 2020-06-07 17:52:51 +02:00
Jens L 4915205678
WIP Use Flows for Sources and Providers (#32)
* core: start migrating to flows for authorisation

* sources/oauth: start type-hinting

* core: create default user

* core: only show user delete button if an unenrollment flow exists

* flows: Correctly check initial policies on flow with context

* policies: add more verbosity to engine

* sources/oauth: migrate to flows

* sources/oauth: fix typing errors

* flows: add more tests

* sources/oauth: start implementing unittests

* sources/ldap: add option to disable user sync, move connection init to model

* sources/ldap: re-add default PropertyMappings

* providers/saml: re-add default PropertyMappings

* admin: fix missing stage count

* stages/identification: fix sources not being shown

* crypto: fix being unable to save with private key

* crypto: re-add default self-signed keypair

* policies: rewrite cache_key to prevent wrong cache

* sources/saml: migrate to flows for auth and enrollment

* stages/consent: add new stage

* admin: fix PropertyMapping widget not rendering properly

* core: provider.authorization_flow is mandatory

* flows: add support for "autosubmit" attribute on form

* flows: add InMemoryStage for dynamic stages

* flows: optionally allow empty flows from FlowPlanner

* providers/saml: update to authorization_flow

* sources/*: fix flow executor URL

* flows: fix pylint error

* flows: wrap responses in JSON object to easily handle redirects

* flow: dont cache plan's context

* providers/oauth: rewrite OAuth2 Provider to use flows

* providers/*: update docstrings of models

* core: fix forms not passing help_text through safe

* flows: fix HttpResponses not being converted to JSON

* providers/oidc: rewrite to use flows

* flows: fix linting
2020-06-07 16:35:08 +02:00
Jens Langhammer f91e02a0ec flows: allow username for default flow 2020-06-05 20:30:47 +02:00
Jens Langhammer c62794c738 admin: fix PropertyMapping widget not rendering properly 2020-06-05 20:27:18 +02:00
Jens Langhammer 7067d1f236 docs: fix typo'd URL 2020-06-05 12:10:28 +02:00
Jens L 73116b9d1a
policies/expression: migrate to raw python instead of jinja2 (#49)
* policies/expression: migrate to raw python instead of jinja2

* lib/expression: create base evaluator, custom subclass for policies

* core: rewrite propertymappings to use python

* providers/saml: update to new PropertyMappings

* sources/ldap: update to new PropertyMappings

* docs: update docs for new propertymappings

* root: remove jinja2

* root: re-add jinja to lock file as its implicitly required
2020-06-05 12:00:27 +02:00
dependabot-preview[bot] 147212a5f9
build(deps): bump boto3 from 1.13.22 to 1.13.23 (#53)
Bumps [boto3](https://github.com/boto/boto3) from 1.13.22 to 1.13.23.
- [Release notes](https://github.com/boto/boto3/releases)
- [Changelog](https://github.com/boto/boto3/blob/develop/CHANGELOG.rst)
- [Commits](https://github.com/boto/boto3/compare/1.13.22...1.13.23)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-06-05 10:27:07 +02:00
dependabot-preview[bot] 5502c319d4
build(deps): bump celery from 4.4.2 to 4.4.4 (#50)
Bumps [celery](https://github.com/celery/celery) from 4.4.2 to 4.4.4.
- [Release notes](https://github.com/celery/celery/releases)
- [Changelog](https://github.com/celery/celery/blob/master/Changelog.rst)
- [Commits](https://github.com/celery/celery/compare/4.4.2...v4.4.4)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-06-04 09:15:42 +02:00
dependabot-preview[bot] d18b76a47d
build(deps): bump boto3 from 1.13.21 to 1.13.22 (#51)
Bumps [boto3](https://github.com/boto/boto3) from 1.13.21 to 1.13.22.
- [Release notes](https://github.com/boto/boto3/releases)
- [Changelog](https://github.com/boto/boto3/blob/develop/CHANGELOG.rst)
- [Commits](https://github.com/boto/boto3/compare/1.13.21...1.13.22)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-06-04 09:15:31 +02:00
dependabot-preview[bot] 90ce704def
build(deps): bump django from 3.0.6 to 3.0.7 (#52)
Bumps [django](https://github.com/django/django) from 3.0.6 to 3.0.7.
- [Release notes](https://github.com/django/django/releases)
- [Commits](https://github.com/django/django/compare/3.0.6...3.0.7)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-06-04 09:15:11 +02:00
Jens Langhammer 790139f8bc stages/email: Add test to check if user is pending 2020-06-03 21:00:04 +02:00
dependabot-preview[bot] f4be007803
build(deps): bump boto3 from 1.13.20 to 1.13.21 (#47)
Bumps [boto3](https://github.com/boto/boto3) from 1.13.20 to 1.13.21.
- [Release notes](https://github.com/boto/boto3/releases)
- [Changelog](https://github.com/boto/boto3/blob/develop/CHANGELOG.rst)
- [Commits](https://github.com/boto/boto3/compare/1.13.20...1.13.21)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-06-03 08:56:13 +02:00
dependabot-preview[bot] 448ca62661
build(deps): bump kombu from 4.6.9 to 4.6.10 (#48)
Bumps [kombu](https://kombu.readthedocs.io) from 4.6.9 to 4.6.10.

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-06-03 08:55:23 +02:00
Jens Langhammer ef913abc7a sources/ldap: add option to disable user sync, move connection init to model 2020-06-02 17:15:59 +02:00
Jens Langhammer 55fc5a6068 policies: rewrite cache_key to prevent wrong cache
# Conflicts:
#	passbook/core/signals.py
#	passbook/policies/engine.py
#	passbook/policies/process.py
2020-06-02 17:06:18 +02:00
Jens Langhammer f22c89c998 crypto: re-add default self-signed keypair 2020-06-02 17:01:15 +02:00
Jens Langhammer 2a78d2d0a0 crypto: fix being unable to save with private key 2020-06-02 17:01:15 +02:00
Jens Langhammer b0ddc6a8c0 admin: fix missing stage count 2020-06-02 17:00:26 +02:00
Jens Langhammer 8080b0380e providers/saml: re-add default PropertyMappings 2020-06-02 17:00:03 +02:00
Jens Langhammer ddfa2abbaa sources/ldap: re-add default PropertyMappings 2020-06-02 17:00:03 +02:00
Jens Langhammer 5fc5e54f47 sources/oauth: fix typing errors
# Conflicts:
#	passbook/sources/oauth/clients.py
2020-06-02 16:57:38 +02:00
Jens Langhammer 7462d56182 policies/engine: add more verbosity 2020-06-02 16:56:58 +02:00
Jens Langhammer 3f92d1c420 flows: Correctly check initial policies on flow with context
# Conflicts:
#	passbook/flows/planner.py
#	passbook/flows/tests/test_planner.py
#	passbook/flows/tests/test_views.py
#	passbook/flows/views.py
2020-06-02 16:53:40 +02:00
Jens Langhammer d4fa60f509 core: only show user delete button if an unenrollment flow exists 2020-06-02 16:44:29 +02:00
Jens Langhammer 052bf88c3d core: create default user
# Conflicts:
#	README.md
2020-06-02 16:42:44 +02:00
Jens Langhammer 07d047c887 stages/identification: fix *_flows missing in edit form 2020-06-02 16:39:55 +02:00
Jens Langhammer 1912b29dc5 policies/expression: fix lint error 2020-06-02 15:20:02 +02:00
dependabot-preview[bot] 46410428d9
build(deps): bump boto3 from 1.13.19 to 1.13.20 (#45)
Bumps [boto3](https://github.com/boto/boto3) from 1.13.19 to 1.13.20.
- [Release notes](https://github.com/boto/boto3/releases)
- [Changelog](https://github.com/boto/boto3/blob/develop/CHANGELOG.rst)
- [Commits](https://github.com/boto/boto3/compare/1.13.19...1.13.20)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-06-02 09:38:17 +02:00
dependabot-preview[bot] 1774e33c24
build(deps): bump kombu from 4.6.8 to 4.6.9 (#46)
Bumps [kombu](https://kombu.readthedocs.io) from 4.6.8 to 4.6.9.

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-06-02 09:37:53 +02:00
Jens Langhammer c961327d27 stages/identification: fix recovery template 2020-06-01 19:08:14 +02:00
Jens Langhammer fe1ff7fc76 core: fix form not showing general errors 2020-06-01 19:08:01 +02:00
Jens Langhammer 82d12ecfdf policies/expression: use pb_message() for messages instead of returning a tuple 2020-06-01 15:25:38 +02:00
dependabot-preview[bot] 6ed822fa38
build(deps-dev): bump autopep8 from 1.5.2 to 1.5.3 (#44)
Bumps [autopep8](https://github.com/hhatto/autopep8) from 1.5.2 to 1.5.3.
- [Release notes](https://github.com/hhatto/autopep8/releases)
- [Commits](https://github.com/hhatto/autopep8/compare/v1.5.2...v1.5.3)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-06-01 12:40:08 +02:00
Jens Langhammer 4d1658b35e stages/identification: explicitly define enrollment and recovery 2020-05-31 23:01:08 +02:00
dependabot-preview[bot] 8b4558fcd0
build(deps): bump boto3 from 1.13.18 to 1.13.19 (#41)
Bumps [boto3](https://github.com/boto/boto3) from 1.13.18 to 1.13.19.
- [Release notes](https://github.com/boto/boto3/releases)
- [Changelog](https://github.com/boto/boto3/blob/develop/CHANGELOG.rst)
- [Commits](https://github.com/boto/boto3/compare/1.13.18...1.13.19)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-05-29 08:53:41 +02:00
Jens Langhammer 27728abe99 e2e: start implementing e2e tests 2020-05-29 00:45:56 +02:00
Jens Langhammer 467b95cf02 Merge branch 'master' into e2e 2020-05-29 00:23:47 +02:00
Jens Langhammer 80a36a3441 stages/user_write: don't use create_user, create empty object and set attributes 2020-05-28 23:22:15 +02:00
Jens Langhammer b1b63fbb7f stages/prompt: add prompt order field 2020-05-28 23:21:43 +02:00
Jens Langhammer 0302a95dd7 Squashed commit of the following:
commit fe6bfb1620
Author: Jens Langhammer <jens.langhammer@beryju.org>
Date:   Thu May 28 22:44:42 2020 +0200

    stages/identification: fix wrong link
2020-05-28 22:44:59 +02:00
Jens Langhammer fe6bfb1620 stages/identification: fix wrong link 2020-05-28 22:44:42 +02:00
Jens Langhammer 3cad746407 Merge branch 'master' into e2e 2020-05-28 22:43:56 +02:00
Jens Langhammer e6d64bf5b3 stages/identification: fix sources and recovery/enrollment not being shown 2020-05-28 22:43:44 +02:00
Jens Langhammer 8dd05d5431 Squashed commit of the following:
commit 270739a45a
Author: Jens Langhammer <jens.langhammer@beryju.org>
Date:   Thu May 28 21:50:43 2020 +0200

    admin: fix policy testing form not showing the correct result

commit df8995deed
Author: Jens L <jens@beryju.org>
Date:   Thu May 28 21:45:54 2020 +0200

    policies/*: remove Policy.negate, order, timeout (#39)

    policies: rewrite engine to use PolicyBinding for order/negate/timeout
    policies: rewrite engine to use PolicyResult instead of tuple

commit fdfc6472d2
Author: Jens Langhammer <jens.langhammer@beryju.org>
Date:   Thu May 28 10:36:10 2020 +0200

    admin: fixup some urls

commit bc495828e7
Author: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Date:   Thu May 28 09:39:28 2020 +0200

    build(deps): bump django-redis from 4.11.0 to 4.12.1 (#38)

    Bumps [django-redis](https://github.com/jazzband/django-redis) from 4.11.0 to 4.12.1.
    - [Release notes](https://github.com/jazzband/django-redis/releases)
    - [Changelog](https://github.com/jazzband/django-redis/blob/master/CHANGES.rst)
    - [Commits](https://github.com/jazzband/django-redis/compare/4.11.0...4.12.1)

    Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

    Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>

commit fa138a273f
Author: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Date:   Thu May 28 08:59:19 2020 +0200

    build(deps): bump boto3 from 1.13.17 to 1.13.18 (#37)

    Bumps [boto3](https://github.com/boto/boto3) from 1.13.17 to 1.13.18.
    - [Release notes](https://github.com/boto/boto3/releases)
    - [Changelog](https://github.com/boto/boto3/blob/develop/CHANGELOG.rst)
    - [Commits](https://github.com/boto/boto3/compare/1.13.17...1.13.18)

    Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

    Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-05-28 21:56:18 +02:00
Jens Langhammer 270739a45a admin: fix policy testing form not showing the correct result 2020-05-28 21:50:43 +02:00
Jens L df8995deed
policies/*: remove Policy.negate, order, timeout (#39)
policies: rewrite engine to use PolicyBinding for order/negate/timeout
policies: rewrite engine to use PolicyResult instead of tuple
2020-05-28 21:45:54 +02:00