santuario-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject DO NOT REPLY [Bug 49458] New: StorageResolver always exhausted after first use
Date Thu, 17 Jun 2010 16:23:00 GMT

           Summary: StorageResolver always exhausted after first use
           Product: Security
           Version: unspecified
          Platform: PC
        OS/Version: Windows NT
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Encryption
        Depends on: 49456

Created an attachment (id=25608)
 --> (
source code patch with augmented junit

The StorageResolver creates an iterator once and always returns the same
iterator afterwards. After the iterator is traversed once, it will always
appear empty. Even if the implementation would be changed to reset the iterator
to the beginning, the single iterator instance approach will never
be thread-safe.

To reproduce use the junit in attachment.

The solution is to return a new iterator each time.
Since the methods StorageResolver.hasNext() and cannot
use this solution, they have been marked deprecated.
The KeyResolvers have been changed to call StorageResolver.getIterator()

This patch assumes the patch in Bug 49456 has already been applied.

Configure bugmail:
------- You are receiving this mail because: -------
You are the assignee for the bug.

View raw message