Unaffiliated

Home Documentation & Help
Steamworks Documentation
Steam DRM

Overview

The Steam DRM wrapper is an important part of Steam platform because it verifies game ownership and ensures that Steamworks features work properly by launching Steam before launching the game.

Automated Steam DRM Wrapper

The Steam wrapper can be applied from within your SteamPipe upload script. This performs an initialization request to the Steam servers via the logged in client, then posts your plaintext executable to the Steam back end via HTTP. The wrap is performed server side, and then steamcmd downloads the wrapped executable.

To perform a DRM wrap with SteamPipe, have your script login and then run the drm_wrap Steam command:
drm_wrap [appid] [input filename] [output filename] [toolname] [flags]

Parameters:
  • appid - Your numeric application ID
  • input filename - Relative or absolute path to input plaintext executable. Remember to quote paths that may contain spaces!
  • output filename - Relative or absolute path where the tool will write the output wrapped executable.
  • toolname - "drmtoolp" for the new portable tool. "drmtool" for old legacy win32 tool.
  • flags - Bitmask of the following numeric flags specifying tool behavior.
  • 0 - Normal wrap (most protection)
  • 6 - Compatibility mode (Disables Steam DRM )
  • 32 - Skip debugger check
  • 38 - compatibility mode and also skip debugger check (least protection)

Example run_build.bat script to login, apply DRM, build and upload the build to Steam (where App ID is 480):
builder\steamcmd.exe +login mysteamaccount mysteampassword +drm_wrap 480 "D:\src\steamworkssdk\steamworksexample\release\steamworksexample.exe" "D:\src\steamworkssdk\tools\ContentBuilder\content\windows_content\SteamworksExample.exe" drmtoolp 0 +run_app_build ..\scripts\app_build_480.vdf +quit

Manual Steam DRM Wrapper

To quickly wrap an exe with the Steam wrapper use the Steamworks App Data Admin page to wrap the primary game exe.

  1. Select the game you want to add DRM to on your App Admin page
  2. Select Edit Steamworks Settings in the Technical Tools Section of the App Admin page
  3. From the Security Tab, select DRM.
  4. Upload the primary game exe - See the automated wrapper section above for more information on the tool execution options.
  5. Download the exe back to your local machine
  6. Rename the exe back to the original name
  7. Copy it to the source location for your Content Tool depots
  8. Build a new version of your depot
  9. Test that depot on your local content server

Using the Steam Wrapper with Other DRM

The Steam wrapper can and should be used in combination with other DRM solutions. To do so, apply the Steam wrapper in compatibility mode first before applying any other DRM. Apply it first so that it does not interfere with the DRM solution. Compatibility mode will disable DRM capabilities of the wrapper.

Submit the exe in compatibility mode by either selecting it in the drop down on the Steamworks page or using the appropriate flags in the automated drmtool.

Frequently Asked Questions

Q. My C# / .Net game doesn't run after applying the Steam wrapper
A. The Steam wrapper doesn't support .Net applications. Instead of using the DRM wrapper, use SteamAPI_RestartAppIfNecessary.

My game doesn't run after applying the Steam DRM wrapper
A. The Steam wrapper can break other DRM tools. See Using the Steam Wrapper with Other DRM, as there may be a conflict.

Do I need to apply DRM to my exe every time I make a new build?
A. Yes, each build you intend to publish needs to be wrapped with the Steam wrapper. Try automating it using the Automated Steam Wrapper process documented above.