{"id":28470745,"url":"https://github.com/score3229/ps3sharp","last_synced_at":"2026-04-29T10:32:47.305Z","repository":{"id":297159822,"uuid":"995832531","full_name":"score3229/PS3Sharp","owner":"score3229","description":"A .NET library for interfacing directly with PS3 and RPCS3 backends, providing memory read/write and management functionalities.","archived":false,"fork":false,"pushed_at":"2025-06-24T16:41:30.000Z","size":38,"stargazers_count":7,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-06-24T16:55:49.160Z","etag":null,"topics":["csharp","dotnet","emulation","game-hacking","gaming","memory-management","modding","process-memory","ps3","ps3-mods","reverse-engineering","rpcs3"],"latest_commit_sha":null,"homepage":"","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/score3229.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-06-04T04:33:11.000Z","updated_at":"2025-06-24T16:41:34.000Z","dependencies_parsed_at":"2025-06-08T04:47:30.369Z","dependency_job_id":null,"html_url":"https://github.com/score3229/PS3Sharp","commit_stats":null,"previous_names":["score3229/ps3sharp"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/score3229/PS3Sharp","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/score3229%2FPS3Sharp","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/score3229%2FPS3Sharp/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/score3229%2FPS3Sharp/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/score3229%2FPS3Sharp/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/score3229","download_url":"https://codeload.github.com/score3229/PS3Sharp/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/score3229%2FPS3Sharp/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":263033068,"owners_count":23403087,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["csharp","dotnet","emulation","game-hacking","gaming","memory-management","modding","process-memory","ps3","ps3-mods","reverse-engineering","rpcs3"],"created_at":"2025-06-07T10:06:15.521Z","updated_at":"2026-04-29T10:32:47.298Z","avatar_url":"https://github.com/score3229.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"# PS3Sharp\n\nPS3Sharp is a cross-platform .NET library for reading and writing memory on **PlayStation 3 (PS3)** consoles and the **RPCS3** emulator. It supports **TMAPI** (DEX), **PS3MAPI** (CEX/DEX via webMAN), **CCAPI** (CEX/DEX), and **RPCS3** — with no native DLL dependencies for cross-platform backends.\n\n**v2.0** is a complete rewrite. PS3Lib and all native dependencies have been dropped. The TMAPI protocol was reverse-engineered from scratch, making PS3Sharp the first library to offer cross-platform TMAPI support — it runs on **Windows, Linux, and macOS** without Target Manager or any Sony tooling installed.\n\n---\n\n## Features\n\n- Cross-platform: Windows, Linux, macOS\n- Direct memory access for PS3 consoles and RPCS3 emulator\n- Read and write all primitive types: byte, int16, int32, int64, float, double, string, bool\n- Built-in `Vector3` and `Vector4` types with `ReadVector3` / `WriteVector3` / `ReadVector4` / `WriteVector4`\n- Generic `ReadEnum\u003cT\u003e` / `WriteEnum\u003cT\u003e` with automatic endian conversion\n- Generic `ReadStruct\u003cT\u003e` / `WriteStruct\u003cT\u003e` with automatic big-endian field swapping\n- Pointer chasing with `GetPointer`\n- Multiple backend support: TMAPI, PS3MAPI, CCAPI, RPCS3\n- No native DLL dependencies for TMAPI, PS3MAPI, and RPCS3\n- Automatic chunking for large memory transfers\n- `IDisposable` on all backends for proper resource cleanup\n- TMAPI seamlessly uses Target Manager DLL when installed, direct TCP otherwise\n\n---\n\n## Platform Notes\n\n| Backend | x64 | x86 | Notes |\n|---------|-----|-----|-------|\n| **RPCS3** | **x64 only** | No | Cross-platform, RPCS3 is a 64-bit process |\n| **TMAPI** | Yes | Yes | Cross-platform, pure C#. Hooks into Target Manager DLL if installed on Windows |\n| **PS3MAPI** | Yes | Yes | Cross-platform, pure C# |\n| **CCAPI** | No | **x86 only** | Windows only, requires CCAPI.dll installed |\n\nIf your project needs both CCAPI and RPCS3, you will need separate builds for each.\n\n---\n\n## Installation\n\nClone the repository and include the project in your solution, or reference the built DLL directly.\n\n```\ngit clone https://github.com/score3229/PS3Sharp.git\n```\n\n---\n\n## Usage\n\n### RPCS3 (emulator)\n\nAttaches to the RPCS3 emulator process for direct memory access. Requires **x64** build. Platform-specific process memory APIs are handled automatically. On Linux/macOS, run with `sudo`.\n\n```csharp\nusing PS3Sharp;\nusing PS3Sharp.Types;\n\nusing var rpcs3 = new PS3Client(\"rpcs3\");\n\nif (rpcs3.Connect())\n{\n    int value = rpcs3.ReadInt32(0xC0000000);\n    Console.WriteLine($\"Value: 0x{value:X}\");\n    rpcs3.Disconnect();\n}\n```\n\n### TMAPI (DEX)\n\nConnects directly to the PS3 debug port over TCP. No Target Manager or ProDG installation required. Works on Windows, Linux, and macOS. On Windows with Target Manager installed, it automatically hooks into the existing connection so it works alongside ProDG.\n\n```csharp\nusing var ps3 = new PS3Client(BackendType.TMAPI, \"10.0.0.4\");\n\nif (ps3.Connect())\n{\n    ps3.WriteInt32(0x00B00000, 0x1337);\n    int value = ps3.ReadInt32(0x00B00000);\n    Console.WriteLine($\"Value: 0x{value:X}\");\n\n    ps3.Disconnect();\n}\n```\n\n### PS3MAPI (CEX/DEX, webMAN)\n\nConnects to the ps3mapi server included in webMAN-MOD. Requires ps3mapi TCP server enabled on the PS3 (port 7887).\n\n```csharp\nusing var ps3 = new PS3Client(BackendType.MAPI, \"10.0.0.4\");\n\nif (ps3.Connect()) // auto-attaches to game process\n{\n    ps3.WriteFloat(0x00B00000, 13.37f);\n    ps3.Disconnect();\n}\n```\n\n### CCAPI (CEX/DEX)\n\nConnects via the CCAPI DLL. Windows only, requires CCAPI installed and your project built as **x86**.\n\n```csharp\nusing var ps3 = new PS3Client(BackendType.CCAPI, \"10.0.0.4\");\n\nif (ps3.Connect()) // auto-attaches to game process\n{\n    ps3.WriteInt32(0x00B00000, 0x1337);\n    ps3.Disconnect();\n}\n```\n\n### Vectors\n\n```csharp\n// read/write 3D position\nVector3 pos = ps3.ReadVector3(0x00B00000);\nps3.WriteVector3(0x00B00000, new Vector3(100f, 50f, 200f));\n\n// read/write position + heading (quaternion, color with alpha, etc.)\nVector4 orientation = ps3.ReadVector4(0x00B00000);\nps3.WriteVector4(0x00B00000, new Vector4(100f, 50f, 200f, 3.14f));\n```\n\n### Structs and Enums\n\n```csharp\n[StructLayout(LayoutKind.Sequential, Pack = 1)]\nstruct PlayerData\n{\n    public int Health;\n    public float PosX;\n    public float PosY;\n    public byte Team;\n}\n\n// fields are automatically big-endian swapped for PS3\nvar player = ps3.ReadStruct\u003cPlayerData\u003e(0x00B00000);\nps3.WriteStruct(0x00B00000, player);\n\n// enums use the underlying type with proper endian conversion\nenum Weapon : int { Pistol = 0, Rifle = 1, Shotgun = 2 }\nps3.WriteEnum(0x00B00000, Weapon.Rifle);\nWeapon w = ps3.ReadEnum\u003cWeapon\u003e(0x00B00000);\n```\n\n---\n\n## Backends\n\n| Backend | Target | Port | Platform | Status |\n|---------|--------|------|----------|--------|\n| **RPCS3** | RPCS3 emulator | N/A | Windows, Linux, macOS (x64) | Fully tested |\n| **TMAPI** | PS3 DEX | 1000 | Windows, Linux, macOS | Fully tested |\n| **PS3MAPI** | PS3 CEX/DEX (webMAN) | 7887 | Windows, Linux, macOS | Fully tested |\n| **CCAPI** | PS3 CEX/DEX | 1979 | Windows only (x86) | Fully tested |\n\n---\n\n## What changed in v2.0\n\n- **Dropped PS3Lib.dll** — no more native DLL dependency or ILRepack build step\n- **Cross-platform TMAPI** — reverse-engineered the SN Systems debug protocol from Wireshark captures. Believed to be the first open-source cross-platform TMAPI implementation\n- **Seamless Target Manager support** — on Windows with ProDG installed, TMAPI automatically routes through the Target Manager DLL so it works alongside the debugger\n- **PS3MAPI support** — FTP-like text protocol for webMAN-MOD CEX/DEX consoles\n- **CCAPI support** — dynamically loads CCAPI.dll when installed on Windows (x86 only)\n- **RPCS3 cross-platform** — Windows (`ReadProcessMemory`), Linux (`pread`/`pwrite`), macOS (`mach_vm_read/write`) with dynamic base address discovery\n- **Shared base class** — all typed read/write methods implemented once in `PS3BackendBase`, eliminating duplication\n- **New API** — `Vector3`, `Vector4`, `ReadEnum\u003cT\u003e`, `WriteEnum\u003cT\u003e`, `ReadStruct\u003cT\u003e`, `WriteStruct\u003cT\u003e` with automatic big-endian field swapping\n- **Automatic chunking** — large reads/writes are split into safe-sized packets transparently\n- **Proper IDisposable** — all backends and the client properly clean up resources\n\n---\n\n## Breaking changes from v1.x\n\n- `PS3Type.TMAPI` / `PS3Type.CCAPI` constructors replaced with `BackendType.TMAPI` / `BackendType.CCAPI` + IP address\n- PS3Lib is no longer bundled or required\n\n---\n\n## Testing\n\nUnit tests are included (35 tests). Integration tests require hardware (PS3 or RPCS3).\n\n---\n\n## Contributing\n\nContributions are welcome! Help with reverse engineering the CCAPI network protocol (custom encrypted, port 1979) would enable cross-platform CCAPI support without the Windows DLL.\n\n---\n\n## License\n\n[MIT License](LICENSE)\n\n---\n\n## Contact\n\nCreated and maintained by Mack Core.\nFeel free to reach out via GitHub or open an issue.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fscore3229%2Fps3sharp","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fscore3229%2Fps3sharp","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fscore3229%2Fps3sharp/lists"}