Skip to content

Conversation

@paulinek13
Copy link
Contributor

@paulinek13 paulinek13 commented Dec 22, 2025

Description

Resolves #343

This PR introduces WebSocketCopilotTarget, enabling sending prompts to Microsoft Copilot via WebSocket.
Implementation reference: powerpwn/copilot/copilot_connector/copilot_connector.py

Warning

It's a work-in-progress. Core functionality is implemented as of 9823509. Try websocket_copilot_simple_example.py to test.

Current limitations:

  • Authentication (Puppeteer-based approach from reference) is not yet implemented. One must manually copy the full WebSocket URL from the browser.
  • There are still quite a few TODOs in the code, some of which I plan to address in different PRs – like Puppeteer-based authentication or supporting more data types – to make them easier to work on and review.
  • Unit and possibly integration tests are still NOT implemented
  • Maybe other stuff I forgot about :))

Tests and Documentation

TODO

@paulinek13 paulinek13 changed the title [✏️ DRAFT] FEAT: add WebSocket-based prompt target for Microsoft Copilot [DRAFT] FEAT: add WebSocket-based prompt target for Microsoft Copilot Dec 22, 2025
- Rename _parse_message() to _parse_raw_message()
- Split on record separator (\x1e) and processes all frames, not just first
- Add FINAL_DATA_FRAME (type 3) enum value for completion signals
- Extract bot message parsing logic into lambda for reusability
- Fixes stop condition to handle FINAL_DATA_FRAME and remove flawed
  "is_user_input and PING" logic
…way because of `enterprise-prod-first-party-app-policy`

This reverts commit 276290f.
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

Successfully merging this pull request may close these issues.

FEAT Add Copilot Target

1 participant