Cari Bantuan

Avoid support scams. We will never ask you to call or text a phone number or share personal information. Please report suspicious activity using the “Report Abuse” option.

Learn More

Suppress console message when attempting to set cookie for an invalid domain

  • Tidak ada balasan
  • 0 memiliki masalah ini
  • 8 kunjungan
more options

We write an SDK that needs to detect what subdomain a site is running on. For example to detect that app.foo.example.com.au and web.foo.example.com.au share example.com.au

In order to do that we check if we can set a cookie on `.au` that fails. Then `.com.au` also fails, then `example.com.au` and that succeeds

This is safe and fast and leaks no information not already available to any JS running in the page.

In most browsers this is fine. In Firefox it is also fine _except_ it logs a warning to the console that a cookie was rejected. This then causes users to open a support ticket with us in order to find out about "the error"

Is it possible for us to suppress this log?

We write an SDK that needs to detect what subdomain a site is running on. For example to detect that app.foo.example.com.au and web.foo.example.com.au share example.com.au In order to do that we check if we can set a cookie on `.au` that fails. Then `.com.au` also fails, then `example.com.au` and that succeeds This is safe and fast and leaks no information not already available to any JS running in the page. In most browsers this is fine. In Firefox it is also fine _except_ it logs a warning to the console that a cookie was rejected. This then causes users to open a support ticket with us in order to find out about "the error" Is it possible for us to suppress this log?
Lampiran tangkapan layar

Anda harus masuk ke akun Anda untuk membalas kiriman ini. Sila mulai pertanyaan baru, jika Anda belum memiliki akun.