Login Dashticz (background)

Dashticz, alternative dashboard based on HTML, CSS, jQuery

Moderators: leecollings, htilburgs, robgeerts

Post Reply
Dave47
Posts: 136
Joined: Thursday 19 July 2018 14:36
Target OS: -
Domoticz version: 2023.1
Contact:

Login Dashticz (background)

Post by Dave47 »

Hallo after update dashticz v3.2.0 to v3.3.1 the Login screen from dashticz shows another background.
The background i see is the startpage from dashticz en pop-up Login screen.

In Dashticz v3.2.0 there was another background. Not 1 of the screens.

The problem is that we use Domoticz outside en you can see the screen if jou follow these link: http://ipextern:8080/dashticz_v3/

On the screen we have the camera's.

Can somebody help us?

One question more.
If we follow the externen link to dashticz must we use
Http://ipextern:8080/dashticz_v3/
Or
Http://ipextern:80/dashticz_v3/

We cant see the switches outside the house. Only other settings like weather.
Lokonli
Posts: 2291
Joined: Monday 29 August 2016 22:40
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: Login Dashticz (background)

Post by Lokonli »

Dave47 wrote: Friday 13 December 2019 9:57 Hallo after update dashticz v3.2.0 to v3.3.1 the Login screen from dashticz shows another background.
The background i see is the startpage from dashticz en pop-up Login screen.

In Dashticz v3.2.0 there was another background. Not 1 of the screens.

The problem is that we use Domoticz outside en you can see the screen if jou follow these link: http://ipextern:8080/dashticz_v3/

On the screen we have the camera's.

Can somebody help us?

One question more.
If we follow the externen link to dashticz must we use
Http://ipextern:8080/dashticz_v3/
Or
Http://ipextern:80/dashticz_v3/

We cant see the switches outside the house. Only other settings like weather.
I'll check the background of the login screen.

For the http address:

The http address you have to use depends on your system setup. Your router uses port forwarding rules, that can be from ipextern:8080 to ipintern:8080, or ipextern:80 to ipintern:8080.

If you make Dashticz accessible from an external IP address, I strongly recommend to read the authorization/authentication info:
https://dashticz.readthedocs.io/en/mast ... z-security

Further,
Dashticz runs in your browser. If you open Dashticz from an external IP address, then the ip-address for Domoticz in your CONFIG.js must also be accessible externally.
Dave47
Posts: 136
Joined: Thursday 19 July 2018 14:36
Target OS: -
Domoticz version: 2023.1
Contact:

Re: Login Dashticz (background)

Post by Dave47 »

If you make Dashticz accessible from an external IP address, I strongly recommend to read the authorization/authentication info:
https://dashticz.readthedocs.io/en/mast ... z-security
i have read this. At the moment i only use the default security settings in dashticz.

I have forward the port 8080 from domoticz for using outside. So i can open dashticz with the link http://ipextern:8080/dashticz_v3/

i read that this is not save enough.

But when i do like https://dashticz.readthedocs.io/en/mas ... -security i can only set a password i understand not a user and password?


But it is not really necessary for me to reach dashticz externally.

But how can i protect domoticz outside??
I have forward port 8080 for using with geofence and then you can also run in dashticz on the same port which is only protected by default.

I have not forward port 80.
tarmacalastair
Posts: 95
Joined: Wednesday 30 October 2019 14:11
Target OS: Raspberry Pi / ODroid
Domoticz version: beta
Location: Great Britain
Contact:

Re: Login Dashticz (background)

Post by tarmacalastair »

I asked similar questions about external access at https://www.domoticz.com/forum/viewtopi ... 67&t=30329

I have config['loginEnabled'] = 0; so I do not see a login screen. I get a pop up box to log in instead - this is what you get when you follow the instructions at https://dashticz.readthedocs.io/en/mast ... z-security and yes it does ask for both username and password.
For troubleshooting purposes from outside, I would suggest the above loginEnabled setting initially until you get it working.

Some notes that might be useful:
  • I presume you have forwarded ports for both Domoticz and Dashticz (different ports if both are on the same machine) on your router for external access? Otherwise, it will not work. As I learned from Lokonli, Dashticz runs in the browser so if you are accessing from outside your network then the browser needs external access to both.

    In order to protect Domoticz from outside you need to go to Settings/Setup and then fill in a username and password and set Authentication to Basic-Auth (Login Page seems to work for me but it's not recommended). Then add these details in your Dashticz config (config['user_name'] = 'myusername' and config['pass_word'] = 'mypassword' )

    Note, that links to web content inside your network, eg a frame to view a web page, will not work from outside if the internal address is used in Dashticz.

    I didn't want to be prompted for a username and password when inside my network so I followed the instructions at https://dashticz.readthedocs.io/en/mast ... z-security .
    But instead of putting this in my .htaccess file:

    Code: Select all

    AuthUserFile /home/pi/dashticzpasswd
    AuthName "Please Enter Password"
    AuthType Basic
    Require valid-user
    I used:

    Code: Select all

    AuthUserFile /home/pi/dashticzpasswd
    AuthName "Please Enter Password"
    AuthType Basic
    <RequireAny>
       Require valid-user
       Require ip 192.168.1
    </RequireAny>
    
    This then only prompts for login if you are accessing from an IP address outside the 192.168.1.* range (change to suit your internal network). You can test this by toggling the wifi on a mobile phone on and off to test from internal and external.
    Lokonli, could this alternative .htaccess be added to the documentation?
Hope this is helpful.
Running Domoticz and Dashticz beta on Raspberry Pi OS 32 bit - has anyone had success with 64 bit?

Desktop access from Ubuntu Linux
Dave47
Posts: 136
Joined: Thursday 19 July 2018 14:36
Target OS: -
Domoticz version: 2023.1
Contact:

Re: Login Dashticz (background)

Post by Dave47 »

@ tarmacalastair

Thank you. I will try this. Is it more save with .htaccess then default security from dashticz?

Is the basic-auth from Domotiz safe?



At the moment i have default security from Dashticz and i have set a time for stay logged in.
So is it possible to stay logged in for a time in lokal network.
I prefer that to the lokal ip address if possible.
Last edited by Dave47 on Friday 13 December 2019 14:30, edited 1 time in total.
tarmacalastair
Posts: 95
Joined: Wednesday 30 October 2019 14:11
Target OS: Raspberry Pi / ODroid
Domoticz version: beta
Location: Great Britain
Contact:

Re: Login Dashticz (background)

Post by tarmacalastair »

Do you mean "safe"? Afraid I don't know enough about web security to answer that but definitely better than no security at all.

Login_timeout - haven't used it but best way to find out is to try it! Just tried it and it doesn't seem to kick you out. But I would try getting all the other bits working first and then re-enable the login screen at the end.
Running Domoticz and Dashticz beta on Raspberry Pi OS 32 bit - has anyone had success with 64 bit?

Desktop access from Ubuntu Linux
Dave47
Posts: 136
Joined: Thursday 19 July 2018 14:36
Target OS: -
Domoticz version: 2023.1
Contact:

Re: Login Dashticz (background)

Post by Dave47 »

Ok where you have set these login_timeout?
or do you mean in Dashticz settings?

Other things working and i become a pop up box to. That is ok so far.
tarmacalastair
Posts: 95
Joined: Wednesday 30 October 2019 14:11
Target OS: Raspberry Pi / ODroid
Domoticz version: beta
Location: Great Britain
Contact:

Re: Login Dashticz (background)

Post by tarmacalastair »

Dave47 wrote: Friday 13 December 2019 13:55
At the moment i have default security from Dashticz and i have set a time for stay logged in.
So is it possible to stay logged in for a time in lokal network.
I thought you meant config['login_timeout'] = 10; (for 10 minutes) in the Dashticz CONFIG.js ?
Running Domoticz and Dashticz beta on Raspberry Pi OS 32 bit - has anyone had success with 64 bit?

Desktop access from Ubuntu Linux
Dave47
Posts: 136
Joined: Thursday 19 July 2018 14:36
Target OS: -
Domoticz version: 2023.1
Contact:

Re: Login Dashticz (background)

Post by Dave47 »

I thought you meant config['login_timeout'] = 10; (for 10 minutes) in the Dashticz CONFIG.js ?
Yes ok that is the same.

but wen i follow these link: http://ipextern:8080/dashticz_v3/ i become a black screen.
Dashticz is loading but no pop up box.
I have tried it also with te default security, also a black screen for dashticz beta v3.2.1
tarmacalastair
Posts: 95
Joined: Wednesday 30 October 2019 14:11
Target OS: Raspberry Pi / ODroid
Domoticz version: beta
Location: Great Britain
Contact:

Re: Login Dashticz (background)

Post by tarmacalastair »

Not sure what you mean.
You get the login screen for Dashticz if you have config['loginEnabled'] = 1 set. Otherwise you get nothing until you set up the security by following https://dashticz.readthedocs.io/en/mast ... z-security.
After this you will get a browser pop up asking for username and password. Try and get that all working first internally. Once you've done that you can enable port forwarding.
Don't forget to restart Apache after making the security changes.
but wen i follow these link: http://ipextern:8080/dashticz_v3/ i become a black screen.
Dashticz is loading but no pop up box.
I have tried it also with te default security, also a black screen for dashticz beta v3.2.1
Make sure you can access Domoticz (without Dashticz) using the address that you are using in Dashticz's CONFIG.js from wherever you are - internal or external because that is the address that Dashticz tries to use. I had the same problem of a black screen because I was using the internal IP for Domoticz in my Dashticz CONFIG,js but trying to access it from outside. You need to use the external address for Domoticz in CONFIG.js - see https://www.domoticz.com/forum/viewtopi ... 29#p229669
Running Domoticz and Dashticz beta on Raspberry Pi OS 32 bit - has anyone had success with 64 bit?

Desktop access from Ubuntu Linux
Dave47
Posts: 136
Joined: Thursday 19 July 2018 14:36
Target OS: -
Domoticz version: 2023.1
Contact:

Re: Login Dashticz (background)

Post by Dave47 »

Everything is done. Internal it works but external there is a black screen.
I have change the internal ip to external in CONFIG.js
No pop up or login screen.

I use also a dashticz v2 with default security settings next to v3.
That works externally to. I can see the switches in v2 but not in v3


I dont know what is wrong.
Lokonli
Posts: 2291
Joined: Monday 29 August 2016 22:40
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: Login Dashticz (background)

Post by Lokonli »

tarmacalastair wrote: Friday 13 December 2019 13:35 I asked similar questions about external access at https://www.domoticz.com/forum/viewtopi ... 67&t=30329

I have config['loginEnabled'] = 0; so I do not see a login screen. I get a pop up box to log in instead - this is what you get when you follow the instructions at https://dashticz.readthedocs.io/en/mast ... z-security and yes it does ask for both username and password.
For troubleshooting purposes from outside, I would suggest the above loginEnabled setting initially until you get it working.

Some notes that might be useful:
  • I presume you have forwarded ports for both Domoticz and Dashticz (different ports if both are on the same machine) on your router for external access? Otherwise, it will not work. As I learned from Lokonli, Dashticz runs in the browser so if you are accessing from outside your network then the browser needs external access to both.

    In order to protect Domoticz from outside you need to go to Settings/Setup and then fill in a username and password and set Authentication to Basic-Auth (Login Page seems to work for me but it's not recommended). Then add these details in your Dashticz config (config['user_name'] = 'myusername' and config['pass_word'] = 'mypassword' )

    Note, that links to web content inside your network, eg a frame to view a web page, will not work from outside if the internal address is used in Dashticz.

    I didn't want to be prompted for a username and password when inside my network so I followed the instructions at https://dashticz.readthedocs.io/en/mast ... z-security .
    But instead of putting this in my .htaccess file:

    Code: Select all

    AuthUserFile /home/pi/dashticzpasswd
    AuthName "Please Enter Password"
    AuthType Basic
    Require valid-user
    I used:

    Code: Select all

    AuthUserFile /home/pi/dashticzpasswd
    AuthName "Please Enter Password"
    AuthType Basic
    <RequireAny>
       Require valid-user
       Require ip 192.168.1
    </RequireAny>
    
    This then only prompts for login if you are accessing from an IP address outside the 192.168.1.* range (change to suit your internal network). You can test this by toggling the wifi on a mobile phone on and off to test from internal and external.
    Lokonli, could this alternative .htaccess be added to the documentation?
Hope this is helpful.
Thanks, I'll add this to the documentation.
Dave47
Posts: 136
Joined: Thursday 19 July 2018 14:36
Target OS: -
Domoticz version: 2023.1
Contact:

Re: Login Dashticz (background)

Post by Dave47 »

@lokonli

Is it possible to change the background on the Login page.
I have the startscreen as background.

Seconde question. I become a black screen. I change the intern ip to extern ip in CONFIG.js.
From outside i become a black screen.
From my home computer, internal it is ok.
Lokonli
Posts: 2291
Joined: Monday 29 August 2016 22:40
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: Login Dashticz (background)

Post by Lokonli »

Dave47 wrote: Sunday 15 December 2019 15:05 @lokonli

Is it possible to change the background on the Login page.
I have the startscreen as background.

Seconde question. I become a black screen. I change the intern ip to extern ip in CONFIG.js.
From outside i become a black screen.
From my home computer, internal it is ok.
Login background is fixed in latest beta. Do a git pull, and refresh the cache.

For the IP address:
Check for error messages in the console tab of the developer window (Press F12 in Chrome)

If you don't see an error, please send me a PM with your external IP address for Dashticz and Domoticz, and I'll have a look. Can you send me your CONFIG.js as well?
tarmacalastair
Posts: 95
Joined: Wednesday 30 October 2019 14:11
Target OS: Raspberry Pi / ODroid
Domoticz version: beta
Location: Great Britain
Contact:

Re: Login Dashticz (background)

Post by tarmacalastair »

I'd be interested to hear what the solution is when you get this solved....
Running Domoticz and Dashticz beta on Raspberry Pi OS 32 bit - has anyone had success with 64 bit?

Desktop access from Ubuntu Linux
Lokonli
Posts: 2291
Joined: Monday 29 August 2016 22:40
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: Login Dashticz (background)

Post by Lokonli »

tarmacalastair wrote: Tuesday 17 December 2019 17:50 I'd be interested to hear what the solution is when you get this solved....
It's solved.

Can you describe your system setup, and the issues you have?
tarmacalastair
Posts: 95
Joined: Wednesday 30 October 2019 14:11
Target OS: Raspberry Pi / ODroid
Domoticz version: beta
Location: Great Britain
Contact:

Re: Login Dashticz (background)

Post by tarmacalastair »

I don't have any problem myself. Like you, I'd been trying to help Dave47 and was just interested to know where his problem was.
Running Domoticz and Dashticz beta on Raspberry Pi OS 32 bit - has anyone had success with 64 bit?

Desktop access from Ubuntu Linux
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest