Code Monkey home page Code Monkey logo

powerremotedesktop's People

Contributors

darkcodersc avatar kaixeb avatar mkht avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

powerremotedesktop's Issues

Connection Dead with unknown error

Thanks your masterwork firstly!
But I Encountered an Error. PRD(your work) server is starting and ready , but once client conn to server ,the connection will dead and noany error! And the client just show a little window with server(but done just a moment) !

thanks your reply!

Exception calling "SetProcessDPIAware" with "0" argument(s): Value cannot be null.

Hey there,
I am guessing that this is my own fault, as I wanted to see if a Linux viewer to connect to a Windows server, but when I attempted to connect to the server (Win 10 pro running in a VM using PowerShell 7.3.0-preview-1) from my desktop Pop_OS 21.10 using PowerShell 7.2.1 I get the following:

Invoke-RemoteDesktopViewer -ServerAddress "192.168.101.147" -ServerPort 2801 -Password "Mys3cUr3P@$$w3rD"

Power Remote Desktop - Version 1.0.3.beta.4
Jean-Pierre LESUEUR (@DarkCoderSc) ###
https://www.github.com/darkcodersc
https://www.phrozen.io

License: Apache License (Version 2.0, January 2004)
https://www.apache.org/licenses/

MethodInvocationException: Exception calling "SetProcessDPIAware" with "0" argument(s): "Value cannot be null. (Parameter 'path1')"

I am guessing that Linux is probably not supported? I wanted to report this, though, just in case. I checked to see if there were any parameters I might have missed for a dpi setting, but didn't see any when searching the readme for dpi, just news that hdpi was supported.

Thanks,
-MH

Out-Null should be avoided because of its low performance.

This project uses the Out-Null cmdlet in several codes, but it should be changed to $null assignment, because Out-Null has a lower performance than $null assignment, it is over 1000 times slower in Windows PowerShell 5.1.
In PowerShell 7.1, there is almost no difference because of the improvements, but $null assignment is still faster.

Performance comparison in Windows PowerShell 5.1

$Buffer = New-Object byte[] 4096

# Out-Null
Measure-Command {(1..1000).ForEach({$Buffer | Out-Null})} | select TotalMilliSeconds

TotalMilliseconds
-----------------
        8050.2508


# $null assignment
Measure-Command {(1..1000).ForEach({$null = $Buffer})} | select TotalMilliSeconds

TotalMilliseconds
-----------------
           6.1887

Help.

Can anyone make this Project Remote Desktop RDP run on my pc without any errors and in running condition, I will also pay his charges to run this software and if anyone can do that then kindly contact me at this email: [email protected]. Visual Studio 2022 in Windows 10

Full Screen Mode

Hello, instruction say to use the ratio option to increase screen size at max of 99, but i can't resize to full screen ( usefull if the client resolution pc and the server PC have different resolution, because if the resolution Is different, also at 99 the screen size Is small). Is possibile to enlarge to full screen or is possibile to add this feature ?

Remote Screen blank

Hello,

Thanks for the wonderful ps script., I'm able to establish connections b/w server and viewer. But on Viewer screen is blank after the connection is established.

Is any tweak needed on my side in the script.

Advice pls.

Thank you,

Satheesh360

Connection test to the localhost

Hello!

I've just installed this module and try to test on the localhost.
When I run Invoke-RemoteDesktopViewer -ServerAddress "127.0.0.1" -ServerPort 2801 -SecurePassword (ConvertTo-SecureString -String "urCompl3xP@ssw0rd" -AsPlainText -Force) in the example,

I have encountered Exception: Could not open a new session with error: "Exception calling ".ctor" with "2" argument(s): target computer denied access"

Anything that I should look for to solve issue?

OS: Windows 10

Thanks.

不好用,并非所说的简单易用

首先,在安装的时候,官方的安装包,并不能直接使用,会有莫名奇妙的错误。手动安装也有一些问题,我在5台电脑上测试过,只有一台电脑成功安装了。

image

测试运行,也会有莫名其妙的错误,这样使用起来,并非简单易用,除非专业的开发人员,否则会有一定的成本

[Issue] - Cannot find type [TcpListenerEx]: verify that the assembly containing this type is loaded.

Hello @DarkCoderSc ,

I'm trying to run PowerRemoteDesktop_Server module on Windows 10 (1909) and Windows Server 2016, both have powershell 5.1 but I encounter an issue when I run :

Invoke-RemoteDesktopServer -ListenAddress "0.0.0.0" -ListenPort 2801 -SecurePassword (ConvertTo-SecureString -String "P@ssw0rd!2022" -AsPlainText -Force)

Power Remote Desktop Server- Version 4.0.0
Jean-Pierre LESUEUR (@DarkCoderSc) ###
https://www.github.com/darkcodersc
https://www.phrozen.io

License: Apache License (Version 2.0, January 2004)
https://www.apache.org/licenses/

Loading remote desktop server components...
VERBOSE: Initialize new session manager...
VERBOSE: Custom X509 Certificate not specified.
VERBOSE: Generate and Install a new local X509 Certificate.
VERBOSE: Certificate was successfully installed on local machine. Opening...
VERBOSE: @Certificate:
VERBOSE: [Subject]
  CN=PowerRemoteDesktop.Server, O=Phrozen, L=Maisons Laffitte, S=Yvelines, C=FR, OU=Freeware

[Issuer]
  CN=PowerRemoteDesktop.Server, O=Phrozen, L=Maisons Laffitte, S=Yvelines, C=FR, OU=Freeware

[Serial Number]
  128F02D94D36849B471C1963CAC549D2

[Not Before]
  4/10/2022 1:54:43 PM

[Not After]
  4/11/2023 1:54:43 PM

[Thumbprint]
  2819E5C755CCFA6302743B994719D9AE24EF1DBE
VERBOSE: ---
VERBOSE: Session manager initialized.
Remote desktop was closed.
New-Object : Cannot find type [TcpListenerEx]: verify that the assembly containing this type is loaded.
At line:32 char:18
+         return @(& $origNewObject @psBoundParameters)
+                  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidType: (:) [New-Object], PSArgumentException
    + FullyQualifiedErrorId : TypeNotFound,Microsoft.PowerShell.Commands.NewObjectCommand

Many thanks for this tool and for your support!

Problems after the target host is remote desktop

Problems after the target host is remote desktop
Dear Developer Hello!
It's a pleasure to try your open source project, I have some problems after using it, here is my advice:

  1. The target host uses Microsoft's remote desktop connection. After the link is disconnected, the target host enters the lock screen interface. At this time, the PowerRemoteDesktop_Viewer interface enters a black screen, and the interface cannot be reactivated.
  2. After this situation occurs, you cannot enter the target host desktop after restarting the connection in powershell.
  3. I have tried to set the host login mode to automatic login, but I still cannot bypass this scenario.

Additional Issues: Frame Delay and File Delivery
Can the screen lag be improved? (I tried reducing ImageCompressionQuality to 30%, still lag)
Can file transfer be done through the clipboard?
Looking forward to your reply, thank you!
(maybe there is something semantically wrong because I used a translator)

No connection could be made because the target machine actively refused it.

total noob here but im testing this out on 2 machines both on my local network and when running the invoke-remotedesktopviewer command the said error comes up. not sure where to go from here. fyi the machine with the server is port forewarded with the same port im trying to use

heres the output of the veiwer

Power Remote Desktop - Version 4.0.0
Jean-Pierre LESUEUR (@DarkCoderSc) ###
https://www.github.com/darkcodersc
https://www.phrozen.io

License: Apache License (Version 2.0, January 2004)
https://www.apache.org/licenses/

VERBOSE: Server address: "127.0.0.1:2801"
Start new remote desktop session...
VERBOSE: Request new session with remote server: "127.0.0.1:2801"...
VERBOSE: Establish first contact with remote server...
VERBOSE: Connect: "127.0.0.1:2801..."
VERBOSE: Close existing session...
VERBOSE: Session closed.
VERBOSE: Free environement.
VERBOSE: Close existing session...
VERBOSE: Session closed.
VERBOSE: Free runspaces...
Remote desktop session has ended.
Exception:
Line |
1004 |              throw "Could not open a new session with error: ""$($_)""
     |              ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
     | Could not open a new session with error: "Exception calling ".ctor" with "2" argument(s): "No connection could be made because the target machine actively refused it. [::ffff:127.0.0.1]:2801""

Happy to close straight away

Hi! Just a quick message (sorry to raise an issue).

I'm not much of a coder so take this with a grain of salt but...

You work is some of the best Powershell I've ever seen including the open source stuff from Microsoft.

Easy To Understand, Explicit, Easy To Follow

Just want to say thank you for your work and please keep it up!

Isn't there a glitch in the password generation algorithm?

There appears to be a problem with the algorithm for password generation using Get-Random used in several places in the project.

For example, the following code seems to expect to generate a random string of 128 characters, but in fact it generates a string of only 94 characters.
Furthermore, it is not completely random, since the same character can never appear more than once in the string.

https://github.com/DarkCoderSc/PowerRemoteDesktop/blob/ea4ed0da37d621cf4f55985a999fcc3b09e6cd9c/PowerRemoteDesktop_Server/PowerRemoteDesktop_Server.psm1#L700

# This code generates only 94-digit string and same character never appears more than once
$candidate = (-join ((33..126) | Get-Random -Count 128 | ForEach-Object{[char] $_}))
$candidate.Length  # -> 94

If you want to fix this algorithm, I suggest the following code. I will submit a PR for the dev branch if you request it.

# This code generates fully random 128 characters string
-join ((1..128) | ForEach-Object {Get-Random -input ([char[]](33..126))})

I don't fully understand the intent of the code, so if this is the intended behavior rather than a bug, please ignore it.

Running on windows 7

What add-ons do I need to install so that this script also works on windows 7?
I'm running it with the command:
Invoke-Expression (Get-Content .\PowerRemoteDesktop_Server.psm1 -Raw)

I get the error:

Get-Content : Cannot find a parameter that matches the parameter name "Raw".
line:1 character:69
+ Invoke-Expression (Get-Content .\PowerRemoteDesktop_Server.psm1 -Raw <<<< )
    + CategoryInfo : InvalidArgument: (:) [Get-Content], ParameterBindingException
    + FullyQualifiedErrorId : NamedParameterNotFound,Microsoft.PowerShell.Commands.GetContentCommand

[Request] Can this tool support sound transfer?

As title, if this tool able to pass the sound of the system? Maybe it needs something like a virtual sound card installed if the machine has no equipment.
And thanks for this amazing tool!

Installation fails? Invoke-RemoteDesktopServer fails.

System: Windows 11, admin powershell.

PS C:\WINDOWS\system32> Invoke-RemoteDesktopServer
Invoke-RemoteDesktopServer : The command "Invoke-RemoteDesktopServer" was found in the module "PowerRemoteDesktop_Server," but the module could not be loaded. If you want more information, run "Import-Module PowerRemoteDesktop_Server."
At line:1 char:1
+ Invoke-RemoteDesktopServer
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : ObjectNotFound: (Invoke-RemoteDesktopServer:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CouldNotAutoloadMatchingModule

PS C:\WINDOWS\system32> Import-Module PowerRemoteDesktop_Server.
Import-Module : The specified module "PowerRemoteDesktop_Server." was not loaded because a valid module file was not found in any module directory.
At line:1 char:1
+ Import-Module PowerRemoteDesktop_Server.
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : ResourceUnavailable: (PowerRemoteDesktop_Server.:String) [Import-Module], FileNotFoundException
    + FullyQualifiedErrorId : Modules_ModuleNotFound,Microsoft.PowerShell.Commands.ImportModuleCommand

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.