def _cellRecognized(payload, relay_crypto):
    if len(payload) < 9 or payload[2:4] != RECOGNIZED:
        return False
    digest = payload[5:9]
    test_payload = _makePayloadWithDigest(payload)
    test_digest = relay_crypto.backward_digest.copy()
    test_digest.update(test_payload)
    # no danger of timing attack here since we just
    # drop the cell if it's not recognized
    return test_digest.digest()[:4] == digest


# TODO: fix documentation
Return 403 if user is not authenticated.
dataset/ETHPy150Open nskinkel/oppy/oppy/crypto/util.py/_cellRecognized--crossover with--dataset/ETHPy150Open caktus/django-scribbler/scribbler/tests/test_views.py/EditFieldTestCase.test_login_required