Skip to content

Cookie not properly set #9

@Polpetta

Description

@Polpetta

Hi 👋
I found a bug when the UI is running on port 80 or 443. In particular, the field cport is not properly set, as window.location.host returns only the address, without the port number.

The fix is to use, in page/login.html, the following code:

var ip = window.location.host.split(':')[0];
var port = location.port || (location.protocol === 'https:' ? '443' : '80');

instead of:

var url = window.location.host.split(':');
var ip = url[0];
var port = url[1];

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions