src/Viserio/Component/Cookie/AbstractCookie.php
protected function normalizeDomain(string $domain = null): ?string
    {
        if ($domain !== null) {
            $domain = \mb_strtolower(\ltrim($domain, '.'));
        }

        return $domain;
    }
protected function normalizeDomain(string $domain = null): ?string
    {
        if ($domain !== null) {
            $domain = \mb_strtolower(\ltrim($domain, '.'));
        }

        return $domain;
    }
Remove the leading '.' and lowercase the domain as per spec in RFC 6265.

@param null|string $domain

@return null|string

@see http://tools.ietf.org/html/rfc6265#section-4.1.2.3
@see http://tools.ietf.org/html/rfc6265#section-5.1.3
@see http://tools.ietf.org/html/rfc6265#section-5.2.3