terminal/src/cascadia
Mike Griese c79334ffbb
Add a file for storing elevated-only state (#11222)
## Summary of the Pull Request

This creates an `elevated-state.json` that lives in `%LOCALAPPDATA%` next to `state.json`, that's only writable when elevated. It doesn't _use_ this file for anything, it just puts the framework down for use later.

It's _just like `ApplicationState`_. We'll use it the same way. 

It's readable when unelevated, which is nice, but not writable. If you're dumb and try to write to the file when unelevated, it'll just silently do nothing.

If we try opening the file and find out the permissions are different, we'll _blow the file away entirely_. This is to prevent someone from renaming the original file (which they can do unelevated), then slapping a new file that's writable by them down in it's place. 

## References
* We're going to use this in #11096, but these PRs need to be broken up.

## PR Checklist
* [x] Closes nothing
* [x] I work here
* [x] Tests added/passed
* [ ] Requires documentation to be updated - maybe? not sure we have docs on `state.json` at all yet

## Validation Steps Performed
I've played with this much more in `dev/migrie/f/non-terminal-content-elevation-warning`

###### followed by #11308, #11310
2021-11-13 01:58:43 +01:00
..
CascadiaPackage Enable DefApp hooks for stable (#11423) 2021-10-06 11:32:14 +00:00
inc Only access ControlInteractivity through the projection (#10051) 2021-07-19 11:59:30 -05:00
LocalTests_SettingsModel Standardize the color table order (#11602) 2021-11-04 22:13:22 +00:00
LocalTests_TerminalApp Unify splitting panes and creating new tabs (#11305) 2021-11-04 22:29:58 +00:00
PublicTerminalCore Introduce AtlasEngine - A new text rendering prototype (#11623) 2021-11-13 00:10:06 +00:00
Remoting Persist window layout cont. save multiple windows (#11083) 2021-09-27 21:18:39 +00:00
ShellExtension Properly escape constructed wt command-lines (#11314) 2021-09-24 16:17:16 +00:00
TerminalApp Add a file for storing elevated-only state (#11222) 2021-11-13 01:58:43 +01:00
TerminalAzBridge Upgrade to C++/WinRT 2.0.210825.3 (#11188) 2021-09-10 21:33:13 +00:00
TerminalConnection Make sure to format the error message with an UNSIGNED int (#11667) 2021-11-03 22:27:41 +00:00
TerminalControl Introduce AtlasEngine - A new text rendering prototype (#11623) 2021-11-13 00:10:06 +00:00
TerminalCore Introduce AtlasEngine - A new text rendering prototype (#11623) 2021-11-13 00:10:06 +00:00
TerminalSettingsEditor Introduce AtlasEngine - A new text rendering prototype (#11623) 2021-11-13 00:10:06 +00:00
TerminalSettingsModel Add a file for storing elevated-only state (#11222) 2021-11-13 01:58:43 +01:00
UnitTests_Control Introduce AtlasEngine - A new text rendering prototype (#11623) 2021-11-13 00:10:06 +00:00
UnitTests_Remoting Persist window layout cont. save multiple windows (#11083) 2021-09-27 21:18:39 +00:00
UnitTests_TerminalCore Standardize the color table order (#11602) 2021-11-04 22:13:22 +00:00
ut_app Enable fast floating point model and fast debug linking (#11466) 2021-10-11 21:02:15 +00:00
WindowsTerminal Add a file for storing elevated-only state (#11222) 2021-11-13 01:58:43 +01:00
WindowsTerminal_UIATests Enable /Zc:preprocessor (#10593) 2021-07-13 23:00:11 +00:00
WindowsTerminalUniversal Update to MUX 2.7 (#11240) 2021-09-20 22:08:55 +00:00
WinRTUtils Replace the UWP file export with the shell32 one (#11365) 2021-10-01 18:33:22 +00:00
WpfTerminalControl wpf: make sure to pack api-ms-win-core-synch-l1-2-0 (#10587) 2021-07-08 10:31:59 -05:00
WpfTerminalTestNetCore wpf: make sure to pack api-ms-win-core-synch-l1-2-0 (#10587) 2021-07-08 10:31:59 -05:00
wt Upgrade Windows SDK to 19041 (#10118) 2021-05-20 16:04:25 +00:00
CascadiaResources.build.items Update Cascadia Code to 2106.17 (#10455) 2021-06-18 20:47:19 +00:00