Downloads:

4,632

Downloads of v 0.5:

107

Last Update:

31 Dec 2019

Package Maintainer(s):

Software Author(s):

  • Gerardo Grignoli

Tags:

gsudo portable sudo for windows

gsudo - a sudo for windows

This is not the latest version of gsudo - a sudo for windows available.

0.5 | Updated: 31 Dec 2019

Downloads:

4,632

Downloads of v 0.5:

107

Maintainer(s):

Software Author(s):

  • Gerardo Grignoli

gsudo - a sudo for windows 0.5

This is not the latest version of gsudo - a sudo for windows available.

All Checks are Passing

2 Passing Test


Validation Testing Passed


Verification Testing Passed

Details

To install gsudo - a sudo for windows, run the following command from the command line or from PowerShell:

>

To upgrade gsudo - a sudo for windows, run the following command from the command line or from PowerShell:

>

To uninstall gsudo - a sudo for windows, run the following command from the command line or from PowerShell:

>

NOTE: This applies to both open source and commercial editions of Chocolatey.

1. Ensure you are set for organizational deployment

Please see the organizational deployment guide

  • Open Source or Commercial:
    • Proxy Repository - Create a proxy nuget repository on Nexus, Artifactory Pro, or a proxy Chocolatey repository on ProGet. Point your upstream to https://chocolatey.org/api/v2. Packages cache on first access automatically. Make sure your choco clients are using your proxy repository as a source and NOT the default community repository. See source command for more information.
    • You can also just download the package and push it to a repository Download

3. Enter your internal repository url

(this should look similar to https://chocolatey.org/api/v2)

4. Choose your deployment method:


choco upgrade gsudo -y --source="'STEP 3 URL'" [other options]

See options you can pass to upgrade.

See best practices for scripting.

Add this to a PowerShell script or use a Batch script with tools and in places where you are calling directly to Chocolatey. If you are integrating, keep in mind enhanced exit codes.

If you do use a PowerShell script, use the following to ensure bad exit codes are shown as failures:


choco upgrade gsudo -y --source="'STEP 3 URL'"
$exitCode = $LASTEXITCODE

Write-Verbose "Exit code was $exitCode"
$validExitCodes = @(0, 1605, 1614, 1641, 3010)
if ($validExitCodes -contains $exitCode) {
  Exit 0
}

Exit $exitCode

- name: Ensure gsudo installed
  win_chocolatey:
    name: gsudo
    state: present
    version: 0.5
    source: STEP 3 URL

See docs at https://docs.ansible.com/ansible/latest/modules/win_chocolatey_module.html.

Coming early 2020! Central Managment Reporting available now! More information...


chocolatey_package 'gsudo' do
  action    :install
  version  '0.5'
  source   'STEP 3 URL'
end

See docs at https://docs.chef.io/resource_chocolatey_package.html.


Chocolatey::Ensure-Package
(
    Name: gsudo,
    Version: 0.5,
    Source: STEP 3 URL
);

Requires Otter Chocolatey Extension. See docs at https://inedo.com/den/otter/chocolatey.


cChocoPackageInstaller gsudo
{
   Name     = 'gsudo'
   Ensure   = 'Present'
   Version  = '0.5'
   Source   = 'STEP 3 URL'
}

Requires cChoco DSC Resource. See docs at https://github.com/chocolatey/cChoco.


package { 'gsudo':
  provider => 'chocolatey',
  ensure   => '0.5',
  source   => 'STEP 3 URL',
}

Requires Puppet Chocolatey Provider module. See docs at https://forge.puppet.com/puppetlabs/chocolatey.


salt '*' chocolatey.install gsudo version="0.5" source="STEP 3 URL"

See docs at https://docs.saltstack.com/en/latest/ref/modules/all/salt.modules.chocolatey.html.

5. If applicable - Chocolatey configuration/installation

See infrastructure management matrix for Chocolatey configuration elements and examples.

This package was approved by moderator mwallner on 06 Jan 2020.

Description

gsudo allows to run commands with elevated permissions within the current console.
It is a sudo equivalent for Windows, with a similar user-experience as the original *nix sudo.

Elevated commands are shown in the caller (non-elevated) console. This allows to run elevated commands without switching to another console.

Usage

gsudo [command] [arguments]
Executes the specified command, elevated, and returns.

Examples

gsudo notepad c:\Windows\System32\drivers\etc\hosts
gsudo cmd

Source


tools\chocolateybeforemodify.ps1
Write-Output "Terminating running gsudo instances."
cmd /c tskill gsudo.exe 2> $null
cmd /c tskill sudo.exe  2> $null
exit 0
tools\chocolateyinstall.ps1
#New-Item -ItemType SymbolicLink -Path "$env:ChocolateyInstall\bin\gsudo.exe" -Target "$env:ChocolateyInstall\lib\gsudo\tools\gsudo.exe"
cmd /c mklink "$env:ChocolateyInstall\bin\gsudo.exe" "$env:ChocolateyInstall\lib\gsudo\tools\gsudo.exe"
#New-Item -ItemType SymbolicLink -Path "$env:ChocolateyInstall\bin\sudo.exe" -Target "$env:ChocolateyInstall\lib\gsudo\tools\gsudo.exe"
cmd /c mklink "$env:ChocolateyInstall\bin\sudo.exe" "$env:ChocolateyInstall\lib\gsudo\tools\gsudo.exe"
tools\chocolateyuninstall.ps1
$ErrorActionPreference = 'SilentlyContinue'

(Get-Item "$env:ChocolateyInstall\bin\sudo.exe").Delete()
(Get-Item "$env:ChocolateyInstall\bin\gsudo.exe").Delete()
tools\gsudo.exe
md5: 0B500F22B9D844A2BC44A34CCEB9A0CC | sha1: 6EF600A200CABF8F62ABD8E944339D03E31DCF1F | sha256: BA69EF38E11F19489700540546915AC24505D60E3D36E2BC5E56EEEC8D57E422 | sha512: 236C46F11953695DB19EBF6C2930B78258425353BF72FFFC0C0F55C29B47EE1293FBBBBDA0FAFC7B5BA65A11D2F41AD5DCEBC8C993A203A49CD32A99BB236EEB
tools\gsudo.exe.config
<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <startup>
    <supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.6" />
  </startup>
</configuration>
tools\gsudo.exe.ignore
 
tools\gsudo.pdb
 
tools\LICENSE.txt
From: https://opensource.org/licenses/MIT

LICENSE

Copyright 2019 Gerardo Grignoli

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
tools\System.Security.Claims.dll
md5: 9D0F9E6289FA7313A48D395FE4247FA4 | sha1: 6A87FA74E76070BDA06CDB1F79C582FC174701F8 | sha256: CB2CFDD49A5E6809578D9EBC6E7202C27B969CBC57D69EC920849F99B04BF3E8 | sha512: 4CA470AEA4923DE035F6B208DEAFBC2611AB1801323D6B2C7885AE4112BD6A0CE30F32EEA65D9D0AD7479FF652D657D6A1AD06F6A1F8A941EA9CE357AC7AA184
tools\System.Security.Principal.Windows.dll
md5: 9F443BED0261034C7E5D70FE0C84E518 | sha1: 35AE25F5C4A14E506CCF2A08F19C381B30E38FA2 | sha256: 77A11C23EAF92C44B74F337C7B70328A5607B2CAC37EEB0A1794B1793E1BE323 | sha512: EA51B3756068BC60B7AA74B307ED5A423496F3D5E1B1AF7FF665B75425FB59E027AA67BEF2416493AEE838D5863C1F7B3706CE98D019229373144174F9967BC2
tools\VERIFICATION.txt
VERIFICATION

#1 - Get hashes from this choco package

powershell -command Get-FileHash tools\*

#2 - Compare with same version release

Go to releases page
https://github.com/gerardog/gsudo/releases

Download same version as this choco package (example v0.4)
https://github.com/gerardog/gsudo/releases/tag/v0.4

unzip and get hashes
powershell -command Get-FileHash *

--- 
Version Hashes for v0.5 
 

Algorithm       Hash                                                                   Path        
---------       ----                                                                   ----        
SHA256          61B0273584210018FA2C9BE1F1A0A4E1C821A62BF4B88ECE22825449223D80BD       C:\git\gs...
SHA256          1E962A050FAA3E6389C0C27E660B9DF6A35FAF76183E899916C450075CB384C0       C:\git\gs...
SHA256          F4EE9CF068D47D76F9F25C2CCE05B0E9881A4D1587D3476E970DEE6E7AC46965       C:\git\gs...
SHA256          BA69EF38E11F19489700540546915AC24505D60E3D36E2BC5E56EEEC8D57E422       C:\git\gs...
SHA256          E2F8FEBF28B49915D142E4B698435D53B7EB3443853BD2892B86FE20E8895620       C:\git\gs...
SHA256          E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855       C:\git\gs...
SHA256          87E83B0F13097051CEE827AF3CA9E2498E404B6F21A00CEA65A258000F3699F5       C:\git\gs...
SHA256          69387DD7F666710395CE91F7CCFBC11ACD533B2D16DE728195651D6A07CB4F15       C:\git\gs...
SHA256          CB2CFDD49A5E6809578D9EBC6E7202C27B969CBC57D69EC920849F99B04BF3E8       C:\git\gs...
SHA256          77A11C23EAF92C44B74F337C7B70328A5607B2CAC37EEB0A1794B1793E1BE323       C:\git\gs...
Get-FileHash : The file 'C:\git\gsudo\src\Scripts\Chocolatey\gsudo\tools\VERIFICATION.txt' cannot 
be read: The process cannot access the file 
'C:\git\gsudo\src\Scripts\Chocolatey\gsudo\tools\VERIFICATION.txt' because it is being used by 
another process.
At line:1 char:1
+ Get-FileHash tools\*.*
+ ~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : ReadError: (C:\git\gsudo\sr...ERIFICATION.txt:PSObject) [Write-Error 
   ], WriteErrorException
    + FullyQualifiedErrorId : FileReadError,Get-FileHash
 


 

Log in or click on link to see number of positives.

In cases where actual malware is found, the packages are subject to removal. Software sometimes has false positives. Moderators do not necessarily validate the safety of the underlying software, only that a package retrieves software from the official distribution point and/or validate embedded software against official distribution point (where distribution rights allow redistribution).

Chocolatey Pro provides runtime protection from possible malware.

Version Downloads Last Updated Status
gsudo - a sudo for windows 0.7.0 1795 Monday, April 6, 2020 Approved
gsudo - a sudo for windows 0.6.0.3 943 Tuesday, February 4, 2020 Approved
gsudo - a sudo for windows 0.6.0.2 78 Saturday, February 1, 2020 Approved
gsudo - a sudo for windows 0.6.0.1 26 Saturday, February 1, 2020 Approved
gsudo - a sudo for windows 0.5.3 108 Thursday, January 23, 2020 Approved
gsudo - a sudo for windows 0.5 107 Tuesday, December 31, 2019 Approved

This package has no dependencies.

Discussion for the gsudo - a sudo for windows Package

Ground Rules:

  • This discussion is only about gsudo - a sudo for windows and the gsudo - a sudo for windows package. If you have feedback for Chocolatey, please contact the Google Group.
  • This discussion will carry over multiple versions. If you have a comment about a particular version, please note that in your comments.
  • The maintainers of this Chocolatey Package will be notified about new comments that are posted to this Disqus thread, however, it is NOT a guarantee that you will get a response. If you do not hear back from the maintainers after posting a message below, please follow up by using the link on the left side of this page or follow this link to contact maintainers. If you still hear nothing back, please follow the package triage process.
  • Tell us what you love about the package or gsudo - a sudo for windows, or tell us what needs improvement.
  • Share your experiences with the package, or extra configuration or gotchas that you've found.
  • If you use a url, the comment will be flagged for moderation until you've been whitelisted. Disqus moderated comments are approved on a weekly schedule if not sooner. It could take between 1-5 days for your comment to show up.
comments powered by Disqus