GithubHelp home page GithubHelp logo

Comments (13)

undergroundwires avatar undergroundwires commented on May 20, 2024

Hi @AdamJel , glad to hear that you're happy and thanks for the bug report. Would you be able to specify your OS version? Did you run standard/script or something customized? Could you upload the script if it was something customized?

from privacy.sexy.

AdamJel avatar AdamJel commented on May 20, 2024

@undergroundwires luckily, I am able to catch on your message editing going on :)

from privacy.sexy.

undergroundwires avatar undergroundwires commented on May 20, 2024

Hi, sorry for the inconsistent replies, I was testing meanwhile and getting different result 😅 Thanks for the all information.

I tested it on 20H1 but could not reproduce, however I could reproduce it using 20H2 and "Strict" template after rebooting.

Behavior is unintended and I'm not sure what script is causing it. 🤔

from privacy.sexy.

undergroundwires avatar undergroundwires commented on May 20, 2024

I suspect this is caused by disabling a service that interacts with the night light settings in an undocumented way. #55 (comment) by @mikhoul might solve it. Please share if anyone can find out what's the cause here, so we can unrecommend or document the script.

from privacy.sexy.

mikhoul avatar mikhoul commented on May 20, 2024

There are 3 Windows services necessary for night lighting to work properly:

  • Connected Devices Platform User Service (CDPUserSvc)

  • Connected Devices Platform Service (CDPSvc)

  • Network Connection Broker (NcbService)

If the "Connected Devices Platform Service" and "Network Connection Broker" services have the "disabled" start type, the "night lighting" functionality in the "Settings" application does not work, if we click on the button for the activate, nothing happens. For the night lighting setting to work, these services can be configured with the "manual" or "automatic" start type with the service management console (services.msc).

The "Connected Devices Platform User Service" service must be configured with the "automatic" start type for night lighting to work. This service (called "template service") create a secondary service (called "Per-user service") with the same name followed by a random hexadecimal number (ex: Connected Devices Platform User Service_253cb) when a user log in (source: https://docs.microsoft.com/en-us/windows/application-management/per-user-services-in-windows).

This service cannot be configured with services.msc, so you must modify its configuration with the Windows registry by executing these commands in Administrator:

reg add "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\CDPUserSvc" /v Start /t REG_DWORD /d 2 /f

reg add "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\CDPUserSvc" /v UserServiceFlags /t REG_DWORD /d 3 /f

Setting the value "Start" to 2 configures the type of start to "Automatic".

Setting the value "UserServiceFlags" to 3 allows the creation of the service per user.

When a user log in, the created per-user service inherits the configuration parameters from the service template. So, if the value "Start" of the template service is 2, the service per user created will have the same value "Start" to 2.

After applying these settings, restart the computer and test the night lighting again.

Source: https://answers.microsoft.com/en-us/windows/forum/all/cant-use-windows-night-light-feature/a7372273-ef97-490e-a65e-5a73d714348c

from privacy.sexy.

usamac avatar usamac commented on May 20, 2024

Hello @mikhoul

I am having this issue after running Standard with some modifications. I have removed EDGE, MS Edge, OneNote & One Drive. There may be one other thing I allowed it wanted to remove that I cannot recall.

I am on 20H2 with Build 19042.906 and Windows Feature Experience Pack 120.2212.551.0.

After running the script, I restarted my system. Then I happened to notice that Night Light was broken. (I use it famously on all of my systems.)

Via your instructions above, searched the services.msc and found both of the aforementioned "Connected Devices Platform Service (CDPSvc)" which was set to Automatic (Delayed Start) and "Network Connection Broker" was set to Manual (Trigger Start). Both were currently Running.

"Connected Devices Platform User Service" was set to Automatic and it was Running.
So, I opened properties and toggled it to Automatic, applied, closed and restarted my system. Once loaded in I checked and Night Light was still greyed out.

I went back into check what they were showing in service.msc and found that "Connected Devices Platform User Service" was no longer even present in any way.

At this point I opened cmd in admin and ran the two lines one at a time just as you posted above. Both ran successfully.
I then restarted and once loaded in found that Night Light was still greyed out. I then searched for Night Light setting to check if I had any options there.

services.msc still does not show "Connected Devices Platform User Service" at all.

Could you provide any other suggestions? It is strange because I have run a very similar script on work devices and while I left OneNote, Drive and Edge enabled, there are no other differences in these two scripts. Work machines are not losing Night Light.

privacy-script personal.zip

from privacy.sexy.

mikhoul avatar mikhoul commented on May 20, 2024

services.msc still does not show "Connected Devices Platform User Service" at all.

Make sure that the CDPUserSvc.dll file exists in the %WinDir%\System32 folder. If this file is missing you can try to restore it from your Windows 10 installation media.

from privacy.sexy.

usamac avatar usamac commented on May 20, 2024

I believe it is installed, right?

Screenshot 2021-04-02 191234

from privacy.sexy.

mikhoul avatar mikhoul commented on May 20, 2024

Verify that the DDL is registred: https://helpdeskgeek.com/how-to/register-dll-file-in-windows/

Once registered set the service to automatic and reboot so see if the service is started.

from privacy.sexy.

usamac avatar usamac commented on May 20, 2024

Thank you. I did this and then it disappeared again after reboot. I ended up running sfc /scannow and it restored my Night Light. Searching through the logs.. Unsure so far, but I am wondering if this enabled my telemetry back as well though?

@AdamJel you may want to try this if you are still without your Night Light.

from privacy.sexy.

undergroundwires avatar undergroundwires commented on May 20, 2024

I found this out after some extensive testing. It's Microsoft AAD Broker Plugin script. Uninstalling it breaks night light settings after reboot. Reverting the script and rebooting solves the issue.

Also breaks on Windows 10 21H1 and Windows 11 - 21H2.

I don't know why night light setting would require Azure Active Directory connection. High likely that some data collection is involved.

from privacy.sexy.

usamac avatar usamac commented on May 20, 2024

from privacy.sexy.

undergroundwires avatar undergroundwires commented on May 20, 2024

Closing this as the setting is now unrecommended and documented. Feel free to create new issues for further problems/ideas.

from privacy.sexy.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.