Commit a514a367 authored by Jan Köster's avatar Jan Köster
Browse files

test

parent 97cc9d06
Loading
Loading
Loading
Loading
+4 −9
Changes for src/blogi.cpp: 4 added lines, 9 removed lines.
Original line number Diff line number Diff line
@@ -128,15 +128,10 @@ static std::string cookieDomain(libhttppp::HttpRequest &req) {
    if (netplus::isIPAddr(h)) return std::string();
    if (h.find('.') == std::string::npos) return std::string();

    // Find parent domain (at least two labels required)
    auto dot = h.find('.');
    if (dot != std::string::npos && dot + 1 < h.size()) {
        std::string parent = h.substr(dot); // e.g. ".tuxist.de"
        // Ensure parent itself has a dot (not just ".de")
        if (parent.find('.', 1) != std::string::npos)
            return parent;
    }
    return h;
    // Use host-only cookies by default. Auto-expanding to a parent domain can be
    // rejected by browsers on public-suffix style deployments (and behind proxies).
    (void)h;
    return std::string();
}

static bool isDeployRequestUrl(const std::string &url) {