Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unknown capabilities #11

Open
atroche opened this issue Jul 30, 2021 · 2 comments
Open

Unknown capabilities #11

atroche opened this issue Jul 30, 2021 · 2 comments

Comments

@atroche
Copy link

atroche commented Jul 30, 2021

Hello! I get these errors when I try to connect to my Windows 10 machine:

GLOBAL: RdpError(RdpError { kind: Unknown, message: "CAPABILITY: Unknown capability CapstypeShare" })
GLOBAL: RdpError(RdpError { kind: Unknown, message: "CAPABILITY: Unknown capability CapstypeColorcache" })
GLOBAL: RdpError(RdpError { kind: Unknown, message: "CAPABILITY: Unknown capability CapsettypeLargePointer" })
GLOBAL: RdpError(RdpError { kind: Unknown, message: "CAPABILITY: Unknown capability CapstypeFont" })
GLOBAL: RdpError(RdpError { kind: Unknown, message: "CAPABILITY: Unknown capability CapsettypeBitmapCodecs" })
GLOBAL: RdpError(RdpError { kind: Unknown, message: "CAPABILITY: Unknown capability CapstypeBitmapcacheHostsupport" })
GLOBAL: RdpError(RdpError { kind: Unknown, message: "CAPABILITY: Unknown capability CapstypeRail" })
GLOBAL: RdpError(RdpError { kind: Unknown, message: "CAPABILITY: Unknown capability CapstypeWindow" })
GLOBAL: RdpError(RdpError { kind: Unknown, message: "CAPABILITY: Unknown capability CapsettypeSurfaceCommands" })
GLOBAL: RdpError(RdpError { kind: Unknown, message: "CAPABILITY: Unknown capability CapssettypeFrameAcknowledge" })

using this code drawn from the examples in the README:

use std::net::{SocketAddr, TcpStream};
use rdp::core::client::Connector;
use rdp::core::event::{RdpEvent, PointerEvent, PointerButton};

fn main() {
    let addr = "<MY_IP>:3389".parse::<SocketAddr>().unwrap();
    let tcp = TcpStream::connect(&addr).unwrap();

    let mut connector = Connector::new()
        .screen(800, 600)
        .credentials("".to_string(), "Alistair".to_string(), "<MY_PASSWORD>".to_string());
    let mut client = connector.connect(tcp).unwrap();

    client.write(RdpEvent::Pointer(
        // Send a mouse click down at 100x100
        PointerEvent {
            x: 100 as u16,
            y: 100 as u16,
            button: PointerButton::Left,
            down: true
        }
    )).unwrap();

    client.read(|rdp_event| {
        match rdp_event {
            RdpEvent::Bitmap(bitmap) => {
                dbg!(bitmap.width);
            }
            _ => println!("Unhandled event")
        }
    }).unwrap();
}

Any ideas? Cheers!

@RyanCode
Copy link

Did you solve this problem? I also came across

@Chipusy
Copy link

Chipusy commented Nov 12, 2022

same troubles

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants