def METHOD_NAME(signer: CryptoSigner, secret_key: str | List[str]):
    old_secret_key = signer.secret_key
    signer.init_app(signer.app, secret_key, signer.salt)
    try:
        yield
    finally:
        signer.init_app(signer.app, old_secret_key, signer.salt)