Commit Graph

705 Commits

Author SHA1 Message Date
bingbing8 38fc68a21b Grant built-in-user TRACE_LOG_EVENT permission
change the file to text type to show the diff
2018-08-11 00:12:50 -07:00
Yanbing 4ac87b4991
Upload unit test as artifacts (#337)
Update vsts scripts to upload unit tests as artifacts
2018-08-06 12:57:47 -07:00
bagajjal 92f363bef1 Remove console resize (#336)
remove the window resize logic in ssh-shellhost.exe
2018-08-03 13:29:43 -07:00
Yanbing 0f9808f190
Cranked version 7.7.2.0 (#334)
Cranked version 7.7.2.0
2018-07-26 11:03:08 -07:00
Manoj Ampalam 84e87be8ae
ConPTY changes and support for auto-updating known_hosts;
- Logic to support conpty (currently disabled until validation is complete)
- fdopen() and fchmod() support for file handles
- support for auto updating known_hosts via ssh and ssh-keygen
- Support for dynamic Windows-size changes with PTY
- Changes to support OneCore SDK
- Test cases
2018-07-25 15:15:05 -07:00
Bryan Berns 366964344f Use Implicit User Principal Name If Explicit Does Not Exist (#332)
Modified user principal name lookup to default to the implicit form (SamAccountName@DnsDomainName) if no explicit user principal name attribute is found on the account.

https://github.com/PowerShell/Win32-OpenSSH/issues/1213
2018-07-20 10:29:49 -07:00
cbookg ce3db0ee61 Fix descriptor leaks in win32 fstat implementation (#329)
Fix descriptor leaks in win32 fstat implementation
PowerShell/Win32-OpenSSH#1209

According to the docs for _open_osfhandle, _close will close the underlying handle:
"To close a file opened with , call _close. The underlying handle is also closed by a call to _close, so it is not necessary to call the Win32 function CloseHandle on the original handle"
2018-07-13 10:43:36 -07:00
Manoj Ampalam 8bb672aa4d
Optimized group membership resolution (#327)
Current group membership resolution though very effective, is very slow. In a typical domain joined enterprise machine, adding a simple entry like the following in sshd_config
AllowGroups administrators
will incur a long delay in remote session establishment as sshd tried to pull all groups associated with the domain user.

Changes in this PR optimize the general case scenarios where no wild cards are in use. Specifically rules like this are processed promptly:

AllowGroups group1, group2, group3 //with no wild cards
Match Group group1 //single group with no negation and wild cards

Optimization is done by resolve the groupname in rule immediately to SID and checking its membership against user token. Enumerating the entire group membership is done on a lazy on-demand basis.

Beyond the optimization, there are 2 functional changes

- removed domain prefix for builtin groups
- removed domain prefix'ed versions of local groups since we are strictly following the convention that local principals shouldn't have any domain qualification.
2018-07-03 10:15:07 -07:00
Bryan Berns 856078b7fd Cleanup SeServiceLogonRight For Restricted User Account (#328)
After creating a user token, the SeServiceLogonRight is now removed from the account so it does not create an orphaned reference in the local security policy.
Other small code changes for code style consistency within the file.

PowerShell/Win32-OpenSSH#1202
2018-07-03 09:43:32 -07:00
Yanbing ed70a1a7f8
Add debug msg, replace API call incompatible with onecore , add build script (#324)
Add debug msg, replace API call incompatible with onecore , add build script
2018-06-18 22:39:31 -07:00
Bryan Berns 4be3dd9647 Added / Fixed Debug Messages (#323)
Fixed debug messages in user token utilities.
2018-06-12 10:18:41 -07:00
Darren Tucker 7703ae5f5d Use ssh-keygen -A to generate missing host keys.
Instead of testing for each specific key type, use ssh-keygen -A to
generate any missing host key types.
2018-06-06 16:05:44 +10:00
Manoj Ampalam 9369d870ad
upped version to 7.7.1.0 and fixed some issues with session path resolution (#320)
upped version to 7.7.1.0 and fixed some issues with session path resolution
2018-06-04 21:15:18 -07:00
Bryan Berns 3b450d5072 Updated SSHD Password Generation (#317)
Updated SSHD user password generation routine to be longer and more complex. This should satisfy systems with password filters that require more character types or very long passwords.
Updated routine to now securely zero memory for the SSHD account password.
Corrected attempt to write to NULL pointer by localtime_s() in localtime_r() and made function return NULL on error per specification.
Addressed various compiler / code analysis warnings.
2018-06-04 21:10:46 -07:00
Manoj Ampalam 1e0c864707
session process path changes (#319)
Added utility to build session process command line - this accounts for restrictions from various shells. With these changes, scp and sftp-server are expected to be machine wide PATH if a custom shell (other than cmd.exe) is defined. Added comprehensive test cases.
Fixed issue with USERNAME env variable containing domain prefix too.

PowerShell/Win32-OpenSSH#1165
PowerShell/Win32-OpenSSH#1165
PowerShell/Win32-OpenSSH#1171
2018-06-04 12:16:13 -07:00
Bryan Berns 710050b186 Remove None/Domain Users Group Filter (#316)
- Removed logic that was excluding the group membership SID that matched 'None' on workgroup computers or 'Domain Users' on domain systems.
- Removed test that was checking that AllowGroups failure if user was not in any group at all.  This is no longer testable since user will always be a member of at least one group.

https://github.com/PowerShell/Win32-OpenSSH/issues/1167
2018-06-03 08:23:30 -07:00
bagajjal 8013f1377b implement freezero(), use localtime_s() instead of localtime() (#300)
PowerShell/Win32-OpenSSH#1121
2018-05-29 19:00:56 -07:00
Manoj Ampalam 8c9c6a0e17
fixed product version (#315) 2018-05-29 10:55:32 -07:00
Manoj Ampalam 9ff97f6106
Fixed issue with virtual token generation (#314)
On certain machines, virtual tokens were not getting generated due to lack of required privileges. Fixed it by assigning them before doing LogonUserExExW. Consolidated runtime dll loading logic. 

PowerShell/Win32-OpenSSH#1162
2018-05-28 22:03:33 -07:00
Bryan Berns 471b76dbd5 Updates To Address OneCore Linking (#311)
* Updates To Address OneCore Linking

- Modified generate_s4u_user_token() and sys_auth_passwd() to dynamically load TranslateNameW() to avoid OneCore static library linking.
- Modified getusergroups() to avoid Lsa* calls that are not present in OneCore libraries.

* Updates To Address OneCore Linking - Revisions

- Corrected failure detection logic when TranslateNameW() cannot be located.
2018-05-23 16:55:55 -07:00
Bryan Berns ec102dce28 Alternate Thread Creation API To Avoid Memory Leaks (#306)
* Alternate Thread Creation API To Avoid Memory Leaks

- Switched from CreateThread() to _beginthreadex() and ExitThread() to _endthreadex() in order to avoid potential leaks when linking with static CRT library.
- Addressed a variety of warnings that were being detected with static code analysis.

* Addressed Type Cast Warning

- Added explicit cast to the output of _beginthreadex() to avoid a compiler warning.

* Indentation Fix
2018-05-23 16:53:36 -07:00
Manoj Ampalam 236b04b335
Tentative changes to support sshd in interactive mode (#313)
Added support to run sshd as non-system. In this mode, sshd can authenticate only the user that sshd is running as, and only via public key authentication.

PowerShell/Win32-OpenSSH#1153
2018-05-22 22:24:23 -07:00
Manoj Ampalam 3fb0c252c3
Refactor session logic (default shell, non PTY, child spawning) (#312)
Changes include:
- Removing sid from pwd structure to comply with Unix structure
- Integrating default shell logic within pwd
- pwd placeholder to allow logins using usernames not associated with Windows account (possible via custom LSA authentication)
- Moving all nonPTY logic from shellhost to session.c. 
- ssh-shellhost is now exclusively for implementing PTY
- Spawning all session processes from within a shell
- Validation checks in safely_chroot
2018-05-22 21:49:58 -07:00
Yanbing a479737cd5
Buffer overflow in Scp (#310)
1. Fix buffer overflow in scp
2. Update setup tests to take into account the windows inbox service startup type
2018-05-20 19:06:36 -07:00
Manoj Ampalam 7b28a316eb
Enable SFTP chroot support (#308)
- Added chroot implementation that simply stores the path in internal state and sets an environment variable
- Spawned processes pickup chroot from environment variable
- Core change in realpath and resolved_path_utf16 now take into account chroot path.
- Unit tests
- Other miscellaneous changes to account for chroot enabled logic in core code

PowerShell/Win32-OpenSSH#190
PowerShell/Win32-OpenSSH#292
2018-05-11 14:45:20 -07:00
Dominic Watley 936b89ac0d Add GCM Cipher Support (#309)
Enabled GCM Cipher related macros in config header for Windows
PowerShell/Win32-OpenSSH#1075
2018-05-10 21:20:55 -07:00
Bryan Berns fe422e5c15 Enhanced Group Discovery / Normalized Names (#286)
Modified getusergroups() to use s4u tokens to discover nested groups and return them in NetBiosName\GroupName format.
Modified get_passwd() to internally normalize names to NetBiosName\SamAccountName format and changed functions that use it to translate to UPN where necessary.
Removed unnecessary support functions used by previous version of getusergroups().
Various refactoring and function consolidation / simplification.
Addressed several buffer over-read issues.

PowerShell/Win32-OpenSSH#553
2018-05-01 23:20:42 -07:00
Manoj Ampalam 77999d2f4d
Merge pull request #303 from NoMoreFood/path_fixes
Reworked resolved_path() into resolved_path_utf16() that combined utf16 conversion and path conditioning into a single function. This eliminated the previously non-threadsafe resolved_path() function that used a static buffer. Changed some functions to use unicode to eliminate use of previous resolve_path function.
Adjusted functions to use resolved_path_utf16().
Collapsed copy_file() function that was only used once.
Corrected compilation errors when debug4() and debug5() are enabled.
Removed debug statements that were interfering with APC wakeup due to the way that logging works in atomicio6().
Filled in a missing parameter in a debug statement.
Changed test helper so test name is displayed when running release build.
Corrected permissions check for whether to run symbolic links in test cases.
Removed TEST_RESOURCES() in unit tests calls due to inconsistent ability to sample handles in Windows 8.1 / Server 2012 R2.
2018-04-25 22:03:52 -07:00
Yanbing ec3eb7a088
Fix issue install-sshd.ps1 failed on Nano, update it to match inbox manifest, and add setup and uninstall tests (#305)
1. Fix issue install-sshd.ps1 failed on Nano
2. Update settings of services in install-sshd.ps1 to match windows inbox
3. added setup tests and update the test helper scripts to run setup tests before changing configurations on the machine
4. added uninstallation tests
2018-04-24 11:50:44 -07:00
Bryan Berns 808a4ac5ce
Merge branch 'latestw_all' into path_fixes 2018-04-24 05:11:43 -04:00
Bryan Berns 3cb15761a9 Use Path Resolution Function For Hard Links
- Changed link() to use resolved_path_utf16().
2018-04-24 05:04:56 -04:00
Manoj Ampalam c24cf7945e Added support for hard links over sftp
https://github.com/PowerShell/Win32-OpenSSH/issues/1119
Added link() support using the CreateHardLink() function.
Made readlink() and link() declarations consistent with other functions.
2018-04-24 05:00:23 -04:00
Bryan Berns 8c86f30a0f Reworked Path Resolution Function - Review Changes
- Changes based on review comments.
2018-04-24 04:47:09 -04:00
Yanbing 41e4e89376
Add support to take key files with CRLF new line ending on windows (#301)
1. Add support to take key files with windows new line ending (PowerShell/Win32-OpenSSH#1130)
2. add test cases for CRLF
3. Update test helper script to catch the exitcode of unittest and report the failure
4. Enable uni test unittest-sshkey and unittest-sshkey
5. Disable resource check for signal tests due to some API issue to follow.
6. Remove workaround for windows new line ending in test scripts
7. Add test validation for ACL of registry entries when perform ssh-add
2018-04-12 14:24:38 -07:00
Damien Miller 10479cc2a4 Many typo fixes from Karsten Weiss
Spotted using https://github.com/lucasdemarchi/codespell
2018-04-10 10:19:02 +10:00
Manoj Ampalam 1616b21ecb
Added support for hard links over sftp
https://github.com/PowerShell/Win32-OpenSSH/issues/1119
Added link() support using the CreateHardLink() function.
Made readlink() and link() declarations consistent with other functions.
2018-04-05 09:57:41 -07:00
Bryan Berns 14ba410250 Removed Problematic Debug Statements
- Removed debug statements that were interfering with APC wakeup due to the way that logging works in atomicio6().
- Filled in a missing parameter in a debug statement.
2018-04-03 23:17:44 -04:00
Manoj Ampalam 32a7aec453 Ported upstream changes (7.7) 2018-04-02 22:30:15 -07:00
Manoj Ampalam 2474b9130b Merge branch 'master' of https://github.com/openssh/openssh-portable into up_merge 2018-04-02 13:13:47 -07:00
Damien Miller a0349a1cc4 update versions in .spec files 2018-04-02 15:38:28 +10:00
Bryan Berns bd6408058a Reworked Path Resolution Function
- Reworked resolved_path() into resolved_path_utf16() that combined utf16 conversion and path conditioning into a single function.  This eliminated the previously non-threadsafe resolved_path() function.
- Adjusted functions to use resolved_path_utf16().
- Collapsed copy_file() function that was only used once.
- Corrected compilation errors when debug4() and debug5() are enabled.
2018-04-01 23:41:09 -04:00
Bryan Berns 296c6934bc Added link() Support
- Added link() support using the CreateHardLink() function.
- Made readlink() and link() declarations consistent with other functions.
2018-03-31 07:52:58 -04:00
Manoj Ampalam c1aaa5d5a3 updates to uninstall-sshd.ps1, cranked version to 7.6.1.0 (#295) 2018-03-30 19:45:11 -07:00
Yanbing f291d2438f
Added config files to enabled VSTS build, compliance tests, Code signing. (#296)
Added config files to enabled VSTS build, compliance tests, Code signing.
2018-03-30 19:44:07 -07:00
Daniel Sweet 11726e3c8e Follow POSIX write/append semantics in fileio_open (#276)
fileio_open previously treated all O_CREAT flags as CREATE_* flags in
CreateFile; CREATE_* always truncates files but O_CREAT only truncates
files when O_TRUNC is also set on POSIX platforms. This becomes
noticeable under SFTP sessions where remote files are opened with
O_APPEND: the file is instead truncated as in O_CREAT | O_TRUNC.

https://github.com/PowerShell/Win32-OpenSSH/issues/1078
2018-03-30 12:37:07 -07:00
revngnr f607a0be96 Bandwidth limits don't work correctly for sftp client (#278)
Fixes following issues:
- gettimeofday : Incorrect converting 100ns intervals (from GetSystemTimeAsFileTime) to timeval.
(us % RATE_DIFF) means number of microseconds but it may be great than 10**6
- nanosleep : SetWaitableTimer works with 100ns intervals but get nanoseconnds (only part of timespec) Missed CloseHandle call in WaitForSingleObject error case.


https://github.com/PowerShell/Win32-OpenSSH/issues/1094
2018-03-30 09:45:44 -07:00
Bryan Berns 993cce0798 Added symlink() Implementation; Revised readlink() (#289)
- Added implementation of symlink() using native CreateSymbolicLink() function.
- Added unit tests for symlink behavior in readlink(), lstat, stat(), and symlink().
- Reworked readlink() to be more inline with POSIX readlink() behavior.
- Reworked symlink handling in stat/lstat due to revised readlink().
- Added additional error handling to readlink().
- Added symlink() Implementation - Memory Leak Fix
- Modified fileio_readlink() to properly free a temporary buffer it creates.
2018-03-29 10:54:38 -07:00
bagajjal 00b869dbd8 Use libre ssl official release binaries (#294)
- Use LibreSSL release binaries. Update paths.target
- Update paths.targets to remove onecore specific changes
- Minor changes
2018-03-29 10:23:05 -07:00
bagajjal be0a2ff29d Fix shellhost infiniteloop issue (ssh.exe -t user@ip dir) (#292)
Fix for PowerShell/Win32-OpenSSH#892
Fixed warning messages in latest code.
2018-03-26 21:32:30 -07:00
Yanbing 952650633d
Update compiler and link options (#293)
* add additionaloptions for ClCompiler and linker for APIscan compliance test
2018-03-26 16:21:56 -07:00
Bryan Berns 59971b42ee Updated Signal Handler (#287)
https://github.com/PowerShell/Win32-OpenSSH/issues/1096
https://github.com/PowerShell/Win32-OpenSSH/issues/191

- Updated wait_for_multiple_objects_enhanced() to handle a no-event request while alterable.
- Simplified wait_for_any_event() to by taking advantage of no-event alterable request in wait_for_multiple_objects_enhanced().
- Updated wait_for_any_event() to use MAX_CHILDREN limit instead of MAXIMUM_WAIT_OBJECTS limit.
- Removed unnecessary ZeroMemory() call.
- Created distinct definition MAXIMUM_WAIT_OBJECTS_ENHANCED
 and modified functions to use it.
- Upped w32_select() event limit.
- Modified wait_for_multiple_objects_enhanced() to allow for 0 millisecond wait.
2018-03-20 09:49:09 -07:00
Bryan Berns 966d8c4129 Unit Test Updates / Small Bug Fixes (#288)
- Updated socketio_WSARecv() to prevent attempted buffer overrun.
- Updated w32_rename() to handle error when input parameters are null.
- Updated file verify success on dup() test.
2018-03-16 09:32:26 -07:00
Bryan Berns d43856a300 Added Symbolic Link Support (#285)
Created readlink() implementation.
Separated, corrected lstat() implementation.
Added symlink file type indicator to returned request data.
2018-03-15 17:13:13 -07:00
Bryan Berns 0dc5a971bd Allow More Child Processes (#284)
- Added wait_for_multiple_objects_enhanced() function that can logically handle wait-any on many children (system resources permitting).
- Added unit tests for wait_for_multiple_objects_enhanced().
- Incorporated use of wait_for_multiple_objects_enhanced() into main signal handler.
- Upped max child processes to 500.
2018-03-14 11:10:27 -07:00
Yanbing fb1342f7e0
Add wildcard support for scp (#283)
1. Expand wildcard for input parameters
2.  add scp tests with wildcard
3. for debug mode, need to enable the log to local log file.
4. update the path to log file
2018-03-11 23:28:52 -07:00
Manoj Ampalam 9fe39c0c73
Fixed regression caused due to ETW support changes (#282)
Regression: Service is unable to start if "ssh" programdata directory is missing.
Reason: This is due to refactored changes around w32_programdir() that moved its initialization to within win32_posix_initialize. sshd_main() is relying on this call even before the POSIX layer gets initialized.
Fix: Reverted the refactoring changes and added comments to consolidate these changes later. Also removed directory creation logic in install-sshd.ps1 that masked this issue before.
2018-03-09 14:56:47 -08:00
Manoj Ampalam 2c559a2b6c
Added support for ETW based logging (#280)
https://github.com/PowerShell/Win32-OpenSSH/issues/95
2018-03-06 15:33:19 -08:00
Yanbing 50a4badb79
Test Fixes on down level OS (#279)
* Test Fixes on downlevel machines
1. Test fix to run on win7 and win8
2. Add -onecore parameter to start-opensshpackage in build helper script
3. Add copying of libcrypto.dll and libcrypto.pdb
4. Update the build number on appveyor.yml
2018-03-01 15:11:55 -08:00
Yanbing f46d8d1b30
build script update: use vs2017 if it exists; fall back to vs2015 if 2017 does not presents (#277)
* add NoOpenSSL and OneCore parameter for packaging

* update the log option so it can print out the build console log

* update script to use vs2017 if it exists

* update path to copy libcrypto.dll
2018-02-27 14:01:45 -08:00
Manoj Ampalam b3a3a5cc66
Multiple Fixes (#273)
PowerShell/Win32-OpenSSH#1065
Fix: In recent sshd architectural changes, post authentication changes that process user specific changes were missing in authenticated sshd worker. Added missing call.
PowerShell/Win32-OpenSSH#1052
Fix: getpwd* functions will now strip off domain of any local user account.
2018-02-21 10:09:18 -08:00
Manoj Ampalam e610a3d6d1 added work arounds for missing APIs 2018-02-21 07:18:42 -08:00
Manoj Ampalam 89cac52637
onboarding fileversion, productversion and softwareversion changes (#274)
Updated file version info:
FileVersionRaw : 7.6.0.0
ProductVersionRaw : 7.6.0.0
ProductName : OpenSSH for Windows
ProductVersion : OpenSSH_7.6p1 for Windows

Updated softwareversion - this would show up in protocol identification string and when doing ssh -V
OpenSSH_for_Windows_7.6
2018-02-20 23:02:04 -08:00
Manoj Ampalam 05d1975743
Added logic to spawn unauthenticated sshd workers to run in isolated … (#275)
Issue: All SSHD unauthenticated workers are currently running as "sshd". Any compromised worker can snoop into the process space of one other worker, steal authentication payload and elevate itself.
Fix: Added logic to spawn the unauthenticated workers under the context of run time unique security identities that will provide complete isolation between these worker processes.
2018-02-20 23:00:14 -08:00
Darren Tucker 265d88d4e6 Remove remaining now-obsolete cvs $Ids. 2018-02-15 20:06:19 +11:00
bagajjal fcead5ed76 Fixed issue with starting sshd in debug mode with a "./" (./sshd.exe -d)
PowerShell/Win32-OpenSSH#1045
2018-02-12 11:49:33 -08:00
Darren Tucker cdb10bd431 Add changelog entry for binary strip change. 2018-02-10 11:18:38 +11:00
Darren Tucker 937d96587d Don't strip binaries so debuginfo gets built.
Tell install not to strip binaries during package creation so that the
debuginfo package can be built.
2018-02-10 11:12:45 +11:00
Darren Tucker eb0865f330 Fix bogus dates in changelog. 2018-02-10 10:33:11 +11:00
Darren Tucker 7fbde1b34c Remove SSH1 from description. 2018-02-10 10:25:15 +11:00
Darren Tucker 9c34a76f09 Add support for compat-openssl10 build dep. 2018-02-10 10:23:00 +11:00
Darren Tucker 04f4e8193c Add leading zero so it'll work when rhel not set.
When rhel is not set it will error out with "bad if". Add leading zero
as per https://fedoraproject.org/wiki/Packaging:DistTag so it'll work
on non-RHEL.
2018-02-10 09:58:32 +11:00
Darren Tucker 12abd67a6a Update openssl-devel dependency. 2018-02-10 09:58:32 +11:00
nkadel b33e7645f8 Add mandir with-mandir' for RHEL 5 compatibility.
Activate '--mandir' and '--with-mandir' settings in setup for RHEL
5 compatibility.
2018-02-10 09:58:32 +11:00
nkadel 94f8bf360e Discard 'K5DIR' reporting.
It does not work inside 'mock' build environment.
2018-02-10 09:58:32 +11:00
nkadel bb7e54dbaf Add 'dist' to 'rel' for OS specific RPM names. 2018-02-10 09:58:32 +11:00
nkadel 87346f1f57 Add openssh-devel >= 0.9.8f for redhat spec file. 2018-02-10 09:58:32 +11:00
nkadel bec1478d71 Enhance BuildRequires for openssh-x11-askpass. 2018-02-10 09:58:32 +11:00
nkadel 3104fcbdd3 Always include x11-ssh-askpass SRPM.
Always include x11-ssh-askpass tarball in redhat SRPM, even if unused.
2018-02-10 09:58:32 +11:00
bagajjal b10f2232e5 fix lsa auth provider and minor bug fixes (#270)
https://github.com/PowerShell/Win32-OpenSSH/issues/1046
2018-02-02 15:45:32 -08:00
Manoj Ampalam 02d07309e2
Now logging sshd.pid at %programdata%\ssh (#269)
PowerShell/Win32-OpenSSH#982
2018-01-29 21:59:48 -08:00
Yanbing bad5548188
Test update
1. Move Start-SSHD-TestDaemon and Stop-SSHD-TestDaemon to commonUtils.psm1
2. Fix the timing issue when trying to read the log while it is still locked by the process.
3, Start the service to create the config fold if it is not there.
4. Skip authorizedkey and sshdconfig tests on win7 since the task scheduler cmdlets are not available on win7.
5. rename variables
2018-01-29 13:49:01 -08:00
Manoj Ampalam fd580e9d96
Allow remote session processes to break away from session job object
PowerShell/Win32-OpenSSH#1032
Issue: Ssh-shellhost.exe creates a job object and ties all its child processes to its lifetime. It does not allow the child processes to break away from this job. This restriction is unnecessary.
Fix: Modified job object to allow child processes to break away if they need to.
2018-01-26 15:22:23 -08:00
bagajjal b92b7c9480 fix the sshd_config and test related changes (#265)
fix the sshd_config and test related changes
2018-01-22 18:53:17 -08:00
bagajjal 973a7afc62
automated generation of cfg, logs folder and copy sshd_config (#264) 2018-01-22 16:55:42 -08:00
Yanbing 8f212f6b05
Cranked version 1.0.0.0 (#262)
Cranked version 1.0.0.0
2018-01-19 15:13:09 -08:00
bagajjal c85ba2b8c3 Separate binary path from cfg path and log path (#263)
Separate binary path from cfg path and log path, test update
2018-01-19 15:12:43 -08:00
Manoj Ampalam 88defae8c1
removed logic arround NTService\SSHD related checks (#261) 2018-01-18 10:46:52 -08:00
Manoj Ampalam 32ff0c2aed
Added support to autogen hostkeys at sshd service startup (#259)
* Added support to autogen hostkeys at sshd service startup
* Integrated latest changes to sshd_config
2018-01-17 08:52:10 -08:00
bagajjal 04c012c032 fix backspace (Control+?) in no-pty session (#257)
https://github.com/PowerShell/Win32-OpenSSH/issues/1011
2018-01-16 21:59:27 -08:00
bagajjal 1f636bd8dd removed extra ; remove m while sending color code (#255)
https://github.com/PowerShell/Win32-OpenSSH/issues/1005
2018-01-16 21:58:44 -08:00
Karl Itnic 97b74e8a10 Update socketio.c (#252)
Merged fix from https://github.com/PowerShell/openssh-portable/pull/252
2018-01-16 21:37:21 -08:00
Manoj Ampalam 5e0833f69d
Logfile add date (#260)
* add date in the log file in MM/DD/YYYY format

* changed date format in log file to bigendian ISO 8601 (YYYY-MM-DD) (#256)

The "madendian" MM/DD/YYYY format is not used outside the United States
(and rather irritating elsewhere)
2018-01-16 19:56:06 -08:00
bagajjal b62ae95cd2 add date in the log file in MM/DD/YYYY format (#253) 2018-01-16 19:48:06 -08:00
Manoj Ampalam fdd54b6334
Implement Unix styled privilege separation in Windows (#258)
OpenSSh privilege separation model - http://www.citi.umich.edu/u/provos/ssh/privsep.html 
Posix_spawn is implemented in POSIX adapter as an alternative to fork() that is heavily used in Privilege separation. 
Additional state info is added to sshd to accommodate distinguishing the various modes (privileged monitor, unprivileged child, authenticated child).
Required service state (like config and host keys) is transmitted over pipes from monitor to child processes.
Changes to installation scripts and tests to accomodate new architectural changes
2018-01-15 13:57:31 -08:00
bagajjal 8906783fa4
remove LsaNtStatusToWinError as onecore doesn't support this API (#249) 2017-12-07 12:50:16 -08:00
bagajjal 507fe3283a Support custom LSA auth provider (#246)
Support custom LSA auth provider
2017-12-07 11:12:29 -08:00
bagajjal ef55537c8b
Merge pull request #226 from PowerShell/mitigate_AltGR_#902
Fix non-US keyboard related issue and scp x86 debug build error
2017-12-05 12:58:47 -08:00
Yanbing 04a3e5ee68
Cranked version 0.0.24.0 (#248)
Cranked version 0.0.24.0
2017-12-04 13:03:54 -08:00
bagajjal 5e86ef04c8 sshd service shouldn't call sshd_main() while exiting (#247)
PowerShell/Win32-OpenSSH#957
2017-12-04 10:45:20 -08:00
Darren Tucker 6c8a246437 Replace mkinstalldirs with mkdir -p.
Check for MIKDIR_P and use it instead of mkinstalldirs.  Should fix "mkdir:
cannot create directory:... File exists" during "make install".
Patch from eb at emlix.com.
2017-12-01 17:13:34 +11:00