Return the given hash, with only the first ``show`` number shown. The rest are masked with ``char`` for security reasons.
(hash, show=6, char="*")
| 193 | |
| 194 | |
| 195 | def mask_hash(hash, show=6, char="*"): |
| 196 | """ |
| 197 | Return the given hash, with only the first ``show`` number shown. The |
| 198 | rest are masked with ``char`` for security reasons. |
| 199 | """ |
| 200 | masked = hash[:show] |
| 201 | masked += char * len(hash[show:]) |
| 202 | return masked |
| 203 | |
| 204 | |
| 205 | def must_update_salt(salt, expected_entropy): |
no outgoing calls
no test coverage detected