Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
156 commits
Select commit Hold shift + click to select a range
96496d8
Accessibility: Set-up UIA Tree (#1691)
carlos-zamora Jul 29, 2019
3f62c8b
Add some ETL around profile, control and connection creation (#2125)
DHowett Jul 30, 2019
56589c0
Fixes crash when specifying invalid font (#2153)
miniksa Jul 30, 2019
c6c51fb
Change our manifest from depending on Windows.Universal to Windows.De…
DHowett Jul 30, 2019
7abcc35
Fix a crash on restore down (#2149)
zadjii-msft Jul 30, 2019
2d3e271
Fix the terminal snapping across DPI boundaries strangely
zadjii-msft Jul 30, 2019
63df881
VT sequence support for EraseInLine, EraseInDisplay, DeleteCharacter …
Jul 30, 2019
1afab78
Update the package version to v0.3
DHowett Jul 30, 2019
a08666b
Accessibility: TermControl Automation Peer (#2083)
carlos-zamora Jul 30, 2019
66044ca
Try to turn audit mode back on without building test/utilities (#2179)
miniksa Jul 31, 2019
6749ab0
First draft of a spec for VT52 escape sequences (#2017)
j4james Aug 1, 2019
f8f0798
Added information on WxH character (#2104)
tapaswenipathak Aug 1, 2019
0da13cd
Use ROW.Reset in EraseInDisplay instead of printing millions of space…
Aug 1, 2019
42c1e58
Remove job object and startup suspended behavior because conhosts sho…
miniksa Aug 2, 2019
0d8f299
Azure connector only shows up if available (#2195)
PankajBhojwani Aug 2, 2019
1b33d18
Update bug template with crash instructions (#2257)
miniksa Aug 5, 2019
3086671
Update bot with new rules (#2259)
miniksa Aug 5, 2019
4529e46
Fixed Ctrl+Alt shortcuts conflicting with AltGr (#2235)
lhecker Aug 5, 2019
b495ad2
Create bx.cmd (#2168)
zadjii-msft Aug 6, 2019
aae938f
Attempt to clean up PCHs as we build to leave more Hosted Agent disk …
miniksa Aug 6, 2019
a787755
add exclusion directories to PR builds, not just rolling builds. (#2272)
miniksa Aug 6, 2019
ff7fdbe
Don't log an error message when _DoGetConsoleInput returns CONSOLE_ST…
j4james Aug 6, 2019
dfb8536
use std::move() on a few more strings, other general code tidying (#1…
yves-dolce Aug 6, 2019
94e5d54
skip a few failing tests for x86 (#2262)
carlos-zamora Aug 6, 2019
8fa42e0
Add a note about the build required to the README (#2291)
zadjii-msft Aug 6, 2019
89925eb
inbox: reflect changes from 20h1 branch (#2310)
DHowett Aug 7, 2019
6c747c5
Update a number of our dependencies (#2301)
DHowett Aug 7, 2019
1e4e125
Stop Roaming settings (#2298)
zadjii-msft Aug 8, 2019
eac29d2
Add list of keybindings to SettingsSchema.md (#2335)
wolf99 Aug 9, 2019
646d8f9
Fix the ut_app build for VS 16.2, 16.3 (#2347)
zadjii-msft Aug 9, 2019
0843f3c
doc: fix typo reaons -> reasons (#2383)
Aulos Aug 11, 2019
138d3b8
template: add Powershell command to get OS version (#2403)
Aug 12, 2019
ac97e5d
Add a Local Test binary, to enable local TerminalApp testing (#2294)
zadjii-msft Aug 13, 2019
13d66c9
Add info about adding copy/paste keybindings (#2290)
zadjii-msft Aug 13, 2019
8999c66
Only update the icon of a tab it the icon actually _changed_ (#2376)
zadjii-msft Aug 14, 2019
82de43b
A better fix for #tab-titles-are-too-long (#2373)
zadjii-msft Aug 14, 2019
1f41fd3
Chunk Selection Expansion for Double/Triple Click Selection (#2184)
carlos-zamora Aug 14, 2019
becdd16
Add Dustin's comment from #632 to Niksa's Doc (#2346)
zadjii-msft Aug 15, 2019
16e1e29
Replace CodepointWidthDetector's runtime table with a static one (#2368)
DHowett Aug 16, 2019
fca0cd9
Reduce scope of audit mode build to just the projects that are curren…
miniksa Aug 16, 2019
24ea086
When the titlebar is clicked, dismiss the new tab flyout (#2438)
zadjii-msft Aug 16, 2019
d7d96f7
Add Warnings during settings load (#2422)
zadjii-msft Aug 16, 2019
d55ecae
Add default keybinding for opening dropdown (#2365)
cinnamon-msft Aug 16, 2019
c70fb49
Add a spec draft for Keybindings Arguments (#1349)
zadjii-msft Aug 16, 2019
734fc1d
Don't copy text if there's no selection (#2446)
zadjii-msft Aug 16, 2019
bd47dcc
Accessibility: Refactor IRenderData with IUiaData (#2296)
carlos-zamora Aug 19, 2019
3815631
sample: Fix static "cmd.exe" in miniterm (#2461)
inventivejon Aug 19, 2019
71eaf62
Add support for HTML copy (#1224)
carlos-zamora Aug 19, 2019
98f7781
Draft Spec for Cascading Default + User Settings (#1258)
zadjii-msft Aug 20, 2019
ff87190
Added CopyOnSelect as a Global Setting (#2152)
carlos-zamora Aug 20, 2019
0c454f5
TURNS OUT CASE SENSITIVITY IS IMPORTANT (#2481)
zadjii-msft Aug 20, 2019
09d79cb
Prevent splitting panes into 0 width/height #2401 (#2450)
richardszalay Aug 20, 2019
f975214
Bugfix: Copy data should persist after Windows Terminal Closes (#2486)
carlos-zamora Aug 20, 2019
8096d7c
Don't overwrite the settings file (#2475)
zadjii-msft Aug 20, 2019
28b767d
dx: Render all gridlines (and, bonus: the box cursor) properly (#2491)
DHowett Aug 20, 2019
667c028
Accessibility: Refactor Providers (#2414)
carlos-zamora Aug 20, 2019
e92efa5
doc: svg currently doesn't work; using .jpg instead (#2443)
MikeTheGreat Aug 20, 2019
be52880
Accessibility: Add BoundingRects to UiaTextRanges (#2423)
carlos-zamora Aug 21, 2019
d1a3e6d
doc: startingDirectory formatting note (#2415)
alphapuggle Aug 21, 2019
6d50fb4
doc: More clear path instructions (#2497)
P1100 Aug 21, 2019
84d19f5
doc: Update bot.md (#2500)
brightbluejay Aug 21, 2019
5694606
doc: Update submitting_code.md (#2499)
brightbluejay Aug 21, 2019
9ff90ba
az: Introduce a "credential version" to force old credentials to be d…
DHowett Aug 21, 2019
1006e98
az: Don't fail when a tenant doesn't have a knowable name (#2508)
DHowett Aug 22, 2019
e7c78c8
Update package version to 0.4
DHowett Aug 22, 2019
949839f
doc: Update Keybindings-Arguments.md (#2498)
brightbluejay Aug 23, 2019
02d8df8
Don't treat the Windows keys as input (#2514)
marcelfreiberg Aug 23, 2019
ebcf812
connection: start up the output thread _only after_ all the pipes are…
DHowett Aug 26, 2019
cffa033
When we reload a profile, always use the same GUID for it (#2542)
zadjii-msft Aug 26, 2019
974e95e
Make the RIS command clear the display and scrollback correctly (#2367)
j4james Aug 28, 2019
f4294b1
Clean up Pane (#2494)
richardszalay Aug 28, 2019
5e38bcd
Fixed typo in user-docs (#2592)
martin389 Aug 29, 2019
0d12a25
Fix typo (#2538)
drebelsky Aug 29, 2019
f93adb9
Added more bot rules (#2502)
miniksa Aug 29, 2019
5de6309
Update building.md (#2501)
brightbluejay Aug 29, 2019
cb02ca7
Changed default padding to 8,8,8,8 and default font size to 11 (#2378)
cinnamon-msft Aug 29, 2019
1989eb9
Make warnings errors for static analysis.
miniksa Aug 29, 2019
65dec36
C26446, Use .at instead of array indices
miniksa Aug 29, 2019
23897b1
[Complex] C26446, Use .at instead of array indices - Reword UTF8OutPi…
miniksa Aug 29, 2019
bd2d5dd
C26477, don't use 0 or NULL, use nullptr.
miniksa Aug 29, 2019
b33a598
C26496, mark const if it's never written after creation
miniksa Aug 29, 2019
c63289b
C26493, no C-style casts.
miniksa Aug 29, 2019
a381f6a
C26435, choose one of `virtual`, `override`, or `final`
miniksa Aug 29, 2019
8ea7401
C26472, no static_cast for arithmetic conversions. narrow or narrow_cast
miniksa Aug 29, 2019
50e2d0c
C26433, overrides should be explicit.
miniksa Aug 29, 2019
8579d89
C26451, promote before arithmetic if storing in larger result size (o…
miniksa Aug 29, 2019
8c3a629
C26481, don't use pointer arithemetic. use span.
miniksa Aug 29, 2019
4f1157c
C26447,C26440 - is noexcept but can throw or doesn't throw but not no…
miniksa Aug 29, 2019
7ec6bfc
catch failure to open clipboard (#2590)
carlos-zamora Aug 30, 2019
feb5b18
doc: move cascadia specs and rename them to spec format (#2593)
DHowett Aug 30, 2019
30e8e7f
C26429, symbols not tested for nullness.
miniksa Sep 3, 2019
cdfbf8f
C26474, don't use static_cast when an implicit cast is acceptable.
miniksa Sep 3, 2019
230e7f4
C26466, disable dynamic_cast rule because we're not RTTI due to OS po…
miniksa Sep 3, 2019
7d4096b
C26485, refactor to avoid array-to-pointer decay.
miniksa Sep 3, 2019
81ab580
C26473, do not cast pointer back to the same type.
miniksa Sep 3, 2019
d5d7cf4
C26494, uninitalized local variables
miniksa Sep 3, 2019
bbdfdf9
C26462, const local variables that are unchanged.
miniksa Sep 3, 2019
b180406
C26445, wstring_view byref may indicate a lifetime issue
miniksa Sep 3, 2019
c956913
C26497, use constexpr for functions that could be evaluated at compil…
miniksa Sep 3, 2019
594dca9
C26429, mark gsl::not_null on places where we don't test for null (sh…
miniksa Sep 3, 2019
45e5993
C26430, not tested for nullness on all paths. I will just always chec…
miniksa Sep 3, 2019
9678dd8
C26414, don't use smart pointers for locals
miniksa Sep 3, 2019
dd49c3e
C26460, use const on params that are unchanged (and remove some unnec…
miniksa Sep 3, 2019
d8bc94f
forgot all return paths to _FillRectangle.
miniksa Sep 3, 2019
49ff36b
Reflect inbox changes in 8c63dff
miniksa Aug 28, 2019
2d3f285
C26432, rule-of-five (if you define one of destruct/copy/move, then d…
miniksa Sep 3, 2019
3bbd8f4
C26443, overriding destructors shouldn't declare virtual nor override.
miniksa Sep 3, 2019
b78d917
C26434, do not hide base class methods. Overriding this one because i…
miniksa Sep 3, 2019
b87f8f9
C26426, global initializers calling non-constexpr. Suppress for defau…
miniksa Sep 3, 2019
072bbfd
C26426, global initializer calls non-constexpr. This needs further co…
miniksa Sep 3, 2019
5d60d69
C26426, global initializer calls non-constexpr. This is an easy move …
miniksa Sep 3, 2019
c7f0a34
C26490, don't reinterpret_cast. It looks like the buffer can easily b…
miniksa Sep 3, 2019
cd144e9
C26436, destructor definition required for class with virtual methods.
miniksa Sep 3, 2019
e14a59a
C26455, default constructor may not throw. Mark `noexcept`. (Trivial …
miniksa Sep 3, 2019
87f5852
Define actual constructor for CodepointWidthDetector as default isn't…
miniksa Sep 3, 2019
b2c093f
C26455, default constructor may not throw, mark as nothrow (another t…
miniksa Sep 3, 2019
3a0da64
C26490, no reinterpret_cast. Suppress on OutputCellIterator because f…
miniksa Sep 3, 2019
244fb72
C26490, no reinterpret_cast. Just use the actual struct and copy inst…
miniksa Sep 3, 2019
41f209f
C26440, default constructors should be noexcept.
miniksa Sep 3, 2019
93aa945
C26429, test for nullness or mark as not_null (and a few cascading wa…
miniksa Sep 3, 2019
ae25a32
C26497, you can mark this thing as constexpr.
miniksa Sep 3, 2019
01bd770
C26429, mark as not_null if not testing for nullness.
miniksa Sep 3, 2019
23b4a46
C26429, C26481, don't use pointer arithmetic, test for nullness. Also…
miniksa Sep 3, 2019
4204733
C26481, don't use pointer arithmetic. Convert to measuring string wit…
miniksa Sep 3, 2019
6735311
Suppress last two errors (C26455 default constructor throw in DxEngin…
miniksa Sep 3, 2019
7d9534b
constexprs have to go into the headers or other usages can't find the…
miniksa Sep 4, 2019
21067a7
Fixes #1918 - Added docs for image/icon settings & paths (#2545)
Sep 4, 2019
51f5353
Add support for short hex color codes like #CCC (#2658)
kojoru Sep 4, 2019
e0762f6
Open-source the PseudoConsole family of functions in a new DLL (#2611)
DHowett Sep 4, 2019
7c66e66
Fix redefinition of class name for constexpr method I moved from CPP …
miniksa Sep 4, 2019
3bff2a3
fix merge conflict with master
miniksa Sep 4, 2019
b7c1e05
code formatter, you're killing me.
miniksa Sep 4, 2019
ce3028e
Clean up boundary between terminal app and terminal page (#2208)
KaiyuWang16 Sep 4, 2019
d0c207b
fix remaining issues that appeared on merge.
miniksa Sep 4, 2019
886d018
warnings as errors for cppwinrt projects, then fix the warnings (#2660)
miniksa Sep 4, 2019
96cc772
Add GH issue IDs to all the suppress/disables that I left behind as t…
miniksa Sep 5, 2019
689c21e
PR feedback.
miniksa Sep 5, 2019
fc81adf
use the array size for the read bounds. using extent on the newly-con…
miniksa Sep 5, 2019
c58033c
Don't crash when restore-down'ing the alt buffer (#2666)
zadjii-msft Sep 5, 2019
125e177
Add some logging around startup, connection start timing (#2544)
zadjii-msft Sep 5, 2019
d8ff47a
Some of the PR feedback.
miniksa Sep 6, 2019
fecddaf
Changed feedback hub request rule (#2680)
miniksa Sep 6, 2019
badbbc4
doc: amend docs procedure for `Running a Different Shell` (#2605)
martin389 Sep 9, 2019
ce34c73
Prevent "Options" propsheet from reverting cursor shape settings (#2663)
zadjii-msft Sep 9, 2019
bac69f7
When inserting/deleting lines, preserve RGB/256 attributes (#2668)
zadjii-msft Sep 9, 2019
18bacfe
A few PR comments. A constexpr here, a misleading comment there, and …
miniksa Sep 9, 2019
429af0e
Merge pull request #2607 from microsoft/dev/miniksa/audit-a
miniksa Sep 10, 2019
2ac2497
Stylus Selection Support (#2586)
carlos-zamora Sep 10, 2019
2063197
Add SECURITY.md to repo (#2720)
miniksa Sep 10, 2019
2da3b49
Fix json settings documentation (#2699)
fredimachado Sep 10, 2019
12d2e17
Correct the boundaries of the scrolling commands (#2505)
j4james Sep 11, 2019
b5fe4ff
Update link to Background Images and Icons section (#2725)
kynapse Sep 11, 2019
537258a
Edits doc section `Configuring Windows Terminal` (#2719)
martin389 Sep 11, 2019
1fccbc5
Move cursor to left margin for IL and DL controls (#2731)
j4james Sep 12, 2019
b693fd4
wap: add some workaround to ensure that our package builds on 16.3 (#…
DHowett Sep 13, 2019
3d35e39
Bugfix: CLS should clear current active buffer (#2729)
carlos-zamora Sep 13, 2019
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion .github/ISSUE_TEMPLATE/Bug_Report.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,14 +26,16 @@ This bug tracker is monitored by Windows Terminal development team and other tec
**Important: When reporting BSODs or security issues, DO NOT attach memory dumps, logs, or traces to Github issues**.
Instead, send dumps/traces to secure@microsoft.com, referencing this GitHub issue.

If this is an application crash, please also provide a Feedback Hub submission link so we can find your diagnostic data on the backend. Use the category "Apps > Windows Terminal (Preview)" and choose "Share My Feedback" after submission to get the link.

Please use this form and describe your issue, concisely but precisely, with as much detail as possible.

-->

# Environment

```none
Windows build number: [run "ver" at a command prompt]
Windows build number: [run `[Environment]::OSVersion` for powershell, or `ver` for cmd]
Windows Terminal version (if applicable):

Any other software?
Expand Down
180 changes: 39 additions & 141 deletions OpenConsole.sln

Large diffs are not rendered by default.

2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@

## Installation

_(Note: in order to run the Windows Terminal, you'll need to be running at least Windows build 18362 or higher.)_

### Microsoft Store

Download the Microsoft Terminal free from the Microsoft Store and it'll be continuously updated. Or, feel free to side-load [releases](https://github.com/microsoft/terminal/releases) from GitHub, but note they won't auto-update.
Expand Down
41 changes: 41 additions & 0 deletions SECURITY.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
<!-- BEGIN MICROSOFT SECURITY.MD V0.0.2 BLOCK -->

## Security

Microsoft takes the security of our software products and services seriously, which includes all source code repositories managed through our GitHub organizations, which include [Microsoft](https://github.com/Microsoft), [Azure](https://github.com/Azure), [DotNet](https://github.com/dotnet), [AspNet](https://github.com/aspnet), [Xamarin](https://github.com/xamarin), and [many more](https://opensource.microsoft.com/).

If you believe you have found a security vulnerability in any Microsoft-owned repository that meets Microsoft's [definition](https://docs.microsoft.com/en-us/previous-versions/tn-archive/cc751383(v=technet.10)) of a security vulnerability, please report it to us as described below.

## Reporting Security Issues

**Please do not report security vulnerabilities through public GitHub issues.**

Instead, please report them to the Microsoft Security Response Center (MSRC) at [https://msrc.microsoft.com/create-report](https://msrc.microsoft.com/create-report).

If you prefer to submit without logging in, send email to [secure@microsoft.com](mailto:secure@microsoft.com). If possible, encrypt your message with our PGP key; please download it from the the [Microsoft Security Response Center PGP Key page](https://www.microsoft.com/en-us/msrc/pgp-key-msrc).

You should receive a response within 24 hours. If for some reason you do not, please follow up via email to ensure we received your original message. Additional information can be found at [microsoft.com/msrc](https://www.microsoft.com/msrc).

Please include the requested information listed below (as much as you can provide) to help us better understand the nature and scope of the possible issue:

* Type of issue (e.g. buffer overflow, SQL injection, cross-site scripting, etc.)
* Full paths of source file(s) related to the manifestation of the issue
* The location of the affected source code (tag/branch/commit or direct URL)
* Any special configuration required to reproduce the issue
* Step-by-step instructions to reproduce the issue
* Proof-of-concept or exploit code (if possible)
* Impact of the issue, including how an attacker might exploit the issue

This information will help us triage your report more quickly.

If you are reporting for a bug bounty, more complete reports can contribute to a higher bounty award. Please visit our [Microsoft Bug Bounty Program](https://microsoft.com/msrc/bounty) page for more details about our active programs.

## Preferred Languages

We prefer all communications to be in English.

## Policy

Microsoft follows the principle of [Coordinated Vulnerability Disclosure](https://www.microsoft.com/en-us/msrc/cvd).

<!-- END MICROSOFT SECURITY.MD BLOCK -->
13 changes: 8 additions & 5 deletions build/pipelines/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,17 +13,20 @@ pr:
branches:
include:
- master
paths:
exclude:
- doc/*
- samples/*
- tools/*

# 0.0.yyMM.dd##
# 0.0.1904.0900
name: 0.0.$(Date:yyMM).$(Date:dd)$(Rev:rr)

jobs:
# This is disabled because the build agents were running out of disk space.
# We're pursuing that in the background, but the spice must flow in the meantime.
# - template: ./templates/build-console-audit-job.yml
# parameters:
# platform: x64
- template: ./templates/build-console-audit-job.yml
parameters:
platform: x64

- template: ./templates/build-console-ci.yml
parameters:
Expand Down
8 changes: 8 additions & 0 deletions build/scripts/Test-WindowsTerminalPackage.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,14 @@ Try {
If ($null -eq $AppXbf) {
Throw "Failed to find App.xbf (TerminalApp project) in resources.pri"
}

If ($Manifest.Package.Identity.ProcessorArchitecture -Ne "arm64") {
### ARM64 doesn't package cpprest_2_10.
If (($null -eq (Get-Item "$AppxPackageRootPath\cpprest_2_10.dll" -EA:Ignore)) -And
($null -eq (Get-Item "$AppxPackageRootPath\cpprest_2_10d.dll" -EA:Ignore))) {
Throw "Failed to find cpprest_2_10.dll -- check the WAP packaging project"
}
}
} Finally {
Remove-Item -Recurse -Force $AppxPackageRootPath
}
1 change: 1 addition & 0 deletions consolegit2gitfilters.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
"/.vs/",
"/build/",
"/src/cascadia/",
"/src/winconpty/",
"/.nuget/",
"/.github/",
"/samples/"
Expand Down
2 changes: 1 addition & 1 deletion dep/gsl
Submodule gsl updated 2 files
+13 −7 appveyor.yml
+5 −5 include/gsl/multi_span
8 changes: 6 additions & 2 deletions doc/ConsoleHostSettings.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@ Settings in the Windows Console Host can be a bit tricky to understand. This is
|---------------------------|-----------------------|--------------------------------------|
|`FontSize` |Coordinate (REG_DWORD) |Size of font in pixels |
|`FontFamily` |REG_DWORD |GDI Font family |
|`ScreenBufferSize` |Coordinate (REG_DWORD) |Size of the screen buffer in WxH characters |
|`ScreenBufferSize` |Coordinate (REG_DWORD) |Size of the screen buffer in WxH characters\*\* |
|`CursorSize` |REG_DWORD |Cursor height as percentage of a single character |
|`WindowSize` |Coordinate (REG_DWORD) |Initial size of the window in WxH characters |
|`WindowSize` |Coordinate (REG_DWORD) |Initial size of the window in WxH characters\*\* |
|`WindowPosition` |Coordinate (REG_DWORD) |Initial position of the window in WxH pixels (if not set, use auto-positioning) |
|`WindowAlpha` |REG_DWORD |Opacity of the window (valid range: 0x4D-0xFF) |
|`ScreenColors` |REG_DWORD |Default foreground and background colors |
Expand Down Expand Up @@ -39,6 +39,10 @@ Settings in the Windows Console Host can be a bit tricky to understand. This is

*: Only applies to the improved version of the Windows Console Host

**: WxH stands for Width by Height, it's the fact that things like a Window size
store the Width and Height values in the high and low word in the registry's
double word values.

## The Settings Hierarchy

Settings are persisted to a variety of locations depending on how they are modified and how the Windows Console Host was invoked:
Expand Down
34 changes: 34 additions & 0 deletions doc/Niksa.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ This document serves as a storage point for those posts.
- [How are the Windows graphics/messaging stack assembled?](#gfxMsgStack)
- [Output Processing between "Far East" and "Western"](#fesb)
- [Why do we not backport things?](#backport)
- [Why can't we have mixed elevated and non-elevated tabs in the Terminal?](#elevation)

## <a name="cmd"></a>Why do we avoid changing CMD.exe?
`setlocal` doesn't behave the same way as an environment variable. It's a thing that would have to be put in at the top of the batch script that is `somefile.cmd` as one of its first commands to adjust the way that one specific batch file is processed by the `cmd.exe` engine. That's probably not suitable for your needs, but that's the way we have to go.
Expand Down Expand Up @@ -145,3 +146,36 @@ It's also costly in terms of time, effort, and testing for us to validate a modi
So from our little team working hard to make developers happy, we virtually never make the cut for servicing. We're sorry, but we hope you can understand. It's just the reality of the situation to say "nope" when people ask for a backport. In our team's ideal world, you would all be running the latest console bits everywhere everytime we make a change. But that's just not how it is today.

Original Source: https://github.com/microsoft/terminal/issues/279#issuecomment-439179675

## <a name="elevation"></a>Why can't we have mixed elevated and non-elevated tabs in the Terminal?

_guest speaker @DHowett-MSFT_

[1] It is trivial when you are _hosting traditional windows_ with traditional window handles. That works very well in the conemu case, or in the tabbed shell case, where you can take over a window in an elevated session and re-parent it under a window in a non-elevated session.

When you do that, there's a few security features that I'll touch on in [2]. Because of those, you can parent it but you can't really force it to do anything.

There's a problem, though. The Terminal isn't architected as a collection of re-parentable windows. For example, it's not running a console host and moving its window into a tab. It was designed to support a "connection" -- something that can read and write text. It's a lower-level primitive than a window. We realized the error of our ways and decided that the UNIX model was right the entire time, and pipes and text and streams are _where it's at._

Given that we're using Xaml islands to host a modern UI and stitching a DirectX surface into it, we're far beyond the world of standard window handles anyway. Xaml islands are fully composed into a single HWND, much like Chrome and Firefox and the gamut of DirectX/OpenGL/SDL games. We don't **have** components that can be run in one process (elevated) and hosted in another (non-elevated) that aren't the aforementioned "connections".

Now, the obvious followup question is _"why can't you have one elevated connection in a tab next to a non-elevated connection?"_ This is where @sba923 should pick up reading (:smile:). I'm probably going to cover some things that you (@robomac) know already.

[2] When you have two windows on the same desktop in the same window station, they can communicate with eachother. I can use `SendKeys` easily through `WScript.Shell` to send keyboard input to any window that the shell can see.

Running a process elevated _severs_ that connection. The shell can't see the elevated window. No other program at the same integrity level as the shell can see the elevated window. Even if it has its window handle, it can't really interact with it. This is also why you can't drag/drop from explorer into notepad if notepad is running elevated. Only another elevated process can interact with another elevated window.

That "security" feature (call it what you like, it was probably intended to be a security feature at one point) only exists for a few session-global object types. Windows are one of them. Pipes aren't really one of them.

Because of that, it's trivial to break that security. Take the terminal as an example of that. If we start an elevated connection and host it in a _non-elevated_ window, we've suddenly created a conduit through that security boundary. The elevated thing on the other end isn't a window, it's just a text-mode application. It immediately does the bidding of the non-elevated host.

Anybody that can _control_ the non-elevated host (like `WScript.Shell::SendKeys`) _also_ gets an instant conduit through the elevation boundary. Suddenly, any medium integrity application on your system can control a high-integrity process. This could be your browser, or the bitcoin miner that got installed with the `left-pad` package from NPM, or really any number of things.

It's a small risk, but it _is_ a risk.

---

Other platforms have accepted that risk in preference for user convenience. They aren't wrong to do so, but I think Microsoft gets less of a "pass" on things like "accepting risk for user convenience". Windows 9x was an unmitigated security disaster, and limited user accounts and elevation prompts and kernel-level security for window management were the answer to those things. They're not locks to be loosened lightly.

Original Source: https://github.com/microsoft/terminal/issues/632#issuecomment-519375707

30 changes: 29 additions & 1 deletion doc/bot.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ We'll be using tags, primarily, to help us understand what needs attention, what
### Quick-Guidance to Core Contributors
1. Look at `Needs-Attention` as top priority
1. Look at `Needs-Triage` during triage meetings to get a handle on what's new and sort it out
1. Look at `Needs-Tag-Fix` when you have a few minutes to fix up things tagged impoperly
1. Look at `Needs-Tag-Fix` when you have a few minutes to fix up things tagged improperly
1. Manually add `Needs-Author-Feedback` when there's something we need the author to follow up on and want attention if they return it or an auto-close for inactivity if it goes stale.

### Tagging/Process Details
Expand All @@ -33,6 +33,17 @@ We'll be using tags, primarily, to help us understand what needs attention, what

## Rules

### Triage Shorthand
- All rules in this category apply to triaging issues. They're shorthand comments that the triage team can use in order to complete the triage process faster.
- Only individuals with `Write` or `Admin` privileges on the repository can use these responses.

#### Duplicate Issues
- When a comment on the thread says `/dup #<issue ID>`...
1. Reply with a comment explaining that the issue is a duplicate and recommend that the opener and interested parties follow the issue on the listed ID number.
1. Close the issue
1. Remove all `Needs-*` tags
1. Add `Resolution-Duplicate`

### Issue Management

#### Mark as Triage Needed
Expand Down Expand Up @@ -64,6 +75,14 @@ We'll be using tags, primarily, to help us understand what needs attention, what
- If an issue is filed matching a pattern that happens all the time (common duplicate phrase, obvious multiple-issues-in-one pattern)...
- Then close the issue automatically informing the opener that they can resolve the problem and reopen the issue. (See Bug/Feature templates for example situations.)

#### Help ask for Feedback Hub
- When a comment on the thread says `/feedback`...
1. Then reply to the issue with a bit of text on asking the author to send us data with Feedback Hub and give us the link.
1. And add the `Needs-Author-Feedback` tag

#### Remove Help Wanted from In PR issues
- If an issue gets the `In-PR` tag when a new PR is created, we will remove the `Help-Wanted` tag to avoid someone trying to work on an issue where another person has already submitted a proposed fix.

### PR Management

#### Codeflow Link *(Disabled)*
Expand Down Expand Up @@ -98,5 +117,14 @@ We'll be using tags, primarily, to help us understand what needs attention, what
#### Add committed fix tag for completed PRs
- When a PR is finished and there's no outstanding work left on a linked issue, add the `Resolution-Fix-Committed` label

#### Remove Needs-Second from completed PRs
- If a PR is closed and it has the `Needs-Second` tag, the bot will remove the tag.

### Release Management

When a release is created, if the PR ID number is linked inside the release description, the bot will walk through the related PR and all of its related issues and leave a message.
- PR message: "🎉{release name} {release version} has been released which incorporates this pull request.🎉
- Issue message: 🎉This issue was addressed in #{pull request ID}, which has now been successfully released as {release name} {release version}.🎉"

## Admin Panel
[Here](https://fabric-cp.azurewebsites.net/bot/)
4 changes: 2 additions & 2 deletions doc/building.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@

# How to build Openconsole

Openconsole can be built with Visual Studio or from the command line. There are build scripts for both cmd and powershell in /tools.
Openconsole can be built with Visual Studio or from the command line. There are build scripts for both cmd and PowerShell in /tools.

When using Visual Studio, be sure to set up the path for code formatting. This can be done in Visual Studio by going to Tools > Options > Text Editor > C++ > Formatting and checking "Use custom clang-format.exe file" and choosing the clang-format.exe in the repository at /dep/llvm/clang-format.exe by clicking "browse" right under the check box.

Expand Down Expand Up @@ -33,4 +33,4 @@ Openconsole has three configuration types:
- Release
- AuditMode

AuditMode is an experimental mode that enables some additional static analyis from CppCoreCheck.
AuditMode is an experimental mode that enables some additional static analysis from CppCoreCheck.
Loading