Changes to a plugin interface might cause recursion
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Zope PAS |
Fix Released
|
Medium
|
Unassigned |
Bug Description
If a plugin declared and was activated for a specific interface, and then suddenly stops providing that interface and removes the method from its implementation, PAS might end up acquiring the method from itself and recursing.
An example:
- LDAPMultiPlugins used to provide and implement ICredentialsUpdate
- An instance of LDAPMultiPlugins exists inside the database, activated to ICredentialsUpdate
- LDAPMultiPlugins then removed the updateCredentials method and stopped declaring the ICredentialsUpdate interface.
- Existing sites get a recursion error on login, because PAS tries to call <ldapmultiplugi
A proposed fix is attached, just checks that the object actually provides the interface it's declared for when doing listPlugins.
FWIW, the patch is for PluginRegistry.