(self, session_data)
| 134 | ) |
| 135 | |
| 136 | def decode(self, session_data): |
| 137 | try: |
| 138 | return signing.loads( |
| 139 | session_data, salt=self.key_salt, serializer=self.serializer |
| 140 | ) |
| 141 | except signing.BadSignature: |
| 142 | logger = logging.getLogger("django.security.SuspiciousSession") |
| 143 | logger.warning("Session data corrupted") |
| 144 | except Exception: |
| 145 | # ValueError, unpickling exceptions. If any of these happen, just |
| 146 | # return an empty dictionary (an empty session). |
| 147 | pass |
| 148 | return {} |
| 149 | |
| 150 | def update(self, dict_): |
| 151 | self._session.update(dict_) |
no test coverage detected