Monthly Archives: August 2020

Domino cookies needs to be secure and have samesite

The first thing is that Domino authentication cookies needs to be secured so you can’t hijack the content. This can be performed using the httponly and secure attributes.

Secondly we might need a way to add the samesite attribute to the cookies if we get problems with the new settings in Chrome. The same site settings is to block third party cookies that is used for advertising but in Domino this could give you problems if your applications is bouncing between domains. How to achieve this.

Server setting, no the Domino server doesn’t have this setting.
Vote for the Same site ideas on Domino ideas, UPDATE 2022 your votes made a difference this is now in Domino 12

Javascript, no that isn’t an option because the settings added removes control from javascript.

But using XPages we have no problem reading and set the cookies again with the correct attributes.

I’ve added this to the after page load event, you need to add this code for all Domino Related cookies that your setup use. Like LTPAToken, SessionID or DomAuthSessId

var c:javax.servlet.http.Cookie = cookie.get("DomAuthSessId")
var response=facesContext.getExternalContext().getResponse();

response.addHeader("Set-Cookie","DomAuthSessId="+c.getValue()+"; Path=/; Secure; HttpOnly; SameSite=None");

This changes the cookies after you have done a login but it will not help if the cookies is removed when you do a login.