1. 19 Mar, 2019 3 commits
    • Jérome Perrin's avatar
    • Jérome Perrin's avatar
      ERP5Security: make ERP5AccessTokenExtractionPlugin work with user ids · fdea2ac5
      Jérome Perrin authored
      Because this was broken, we took the liberty to introduce a breaking
      change to fix naming, now type based scripts are *_getUserValue and must
      return a user document, with a getUserId method returning the user id.
      
      Make this plugin also an IAuthenticationPlugin which does all the job of
      returning the user id.
      It does not really make sense to delegate this to default authenticator.
      A side effect is that token can still authenticate users with no
      assignments, since tokens are scriptable, if this is a requirement, it
      can be implemented in scripts.
      
      also update test:
      
       - plugin must be enabled for IAuthenticationPlugin
       - check complete authentication sequence, not just extraction
       - update scripts to new names
       - simplify transaction management
       - don't set self.person, it was not used anywhere
       - update _createPerson to reindex, as said in docstring
       - merge all tests in on test component
      fdea2ac5
    • Jérome Perrin's avatar
      42b320a9
  2. 25 Feb, 2019 2 commits
  3. 22 Feb, 2019 2 commits
  4. 21 Feb, 2019 2 commits
  5. 20 Feb, 2019 4 commits
  6. 18 Feb, 2019 3 commits
  7. 16 Feb, 2019 1 commit
  8. 15 Feb, 2019 7 commits
  9. 14 Feb, 2019 3 commits
  10. 13 Feb, 2019 5 commits
  11. 12 Feb, 2019 1 commit
    • Arnaud Fontaine's avatar
      ZODB Components: Likewise Document, add Mixin (erp5.component.mixin) and... · e84d2b51
      Arnaud Fontaine authored
      ZODB Components: Likewise Document, add Mixin (erp5.component.mixin) and Interface (erp5.component.interface).
      
      * One Mixin/Interface class per ZODB Component.
        => Already the case for FS Mixin, not for Interfaces.
      * ZODB Components module name ('reference' property) and class name:
        + Mixin: FooMixin.
        + Interface: IFoo.
      
      Rationale:
        + Avoid current FS hacks: registry (Mixins, mixin_class_registry) or import
          all classes explicitly in __init__.py (Products.ERP5Type.interfaces).
        + Consistent naming.
        + Consistent with ZODB Documents Components.
      
      Also, modify pylint checker to handle Zope Interfaces:
        + E: 4, 0: Inheriting 'Interface', which is not a class. (inherit-non-class)
        + E: 5, 2: Method has no argument (no-method-argument)
      e84d2b51
  12. 11 Feb, 2019 3 commits
  13. 08 Feb, 2019 1 commit
  14. 07 Feb, 2019 3 commits