def METHOD_NAME(request: HttpRequest) -> bool:
    last_auth_str = request.session.get(LAST_AUTH_KEY)
    if not last_auth_str:
        return False
    try:
        last_auth = datetime.fromisoformat(last_auth_str)
    except ValueError:
        return False
    now = timezone.now()
    diff = now - last_auth
    if request.method == "GET":
        # Shorter duration for GET request
        return diff <= RECENT_AUTH_DURATION
    # Slightly longer duration for other requests
    # So you can submit a form from a page
    return diff <= RECENT_AUTH_POST_DURATION