Submitting this because I dont have the time (or resources) to debug this atm and need a self-reminder:
On Win32 walletpassphrase does not appear to relock after the designated amount of time as it should and as it does on Linux.
Can someone check this on OSX as well?

if (!fBroadcastTransactions) {
        // Don't submit tx to the mempool
        return;
    }
    std::string err_string;
    if (!SubmitTxMemoryPoolAndRelay(wtx, err_string, true)) {
        WaetLogPrintf("CommitTransaction(): Transaction cannot be broadcast immediately, %s\n", err_string);
        // TODO: if we expect the failure to be long term or permanent, instead delete wtx from the  and return failure.
    }
}
DBErrors CWaet::LoadWaet()
{
    LOCK(cs_);
    DBErrors nLoadWaetRet = WaetBatch(GetDatabase()).LoadWaet(this);
    if (nLoadWaetRet == DBErrors::NEED_REWRITE)
    {
        if (GetDatabase().Rewrite("\x04pool"))
        {
            for (const auto& spk_man_pair : m_spk_managers) {
                spk_man_pair.second->RewriteDB();
            }
        }
    }
    if (m_spk_managers.empty()) {
        assert(m_external_spk_managers.empty());
        assert(m_internal_spk_managers.empty());
    }
    return nLoadWaetRet;
}
DBErrors CWaet::ZapSelectTx(std::vector<uint256>& vHashIn, std::vector<uint256>& vHashOut)