Skip to content

[Feature Request] Add ability to include custom binaries (not app bundles) into code signing pipeline #23848

Open

Description

@snechaev

Task/Context

I want to include ffmpeg executables (not dylib-s, but "exe") in my app bundle and run them via Process.Start(). The resulting app bundle should be able to pass apple notarization and review processes.
A typical solution is to add ffmpeg as a Content and sign it.

      <Content Include="ffmpeg">
        <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
      </Content>

Current NET SDK Implementation

By default, the .NET build pipeline won't sign ffmpeg, as it is just a file without an extension.

Current Implementation Customization Options

We have the following options to customize the signing process:

  • <CodesignBundle/> msbuild item group, which allows adding an application bundle (but not a ordinal executable) to the "to be signed" list. This works well if my helper application is an app bundle. Unfortunately, it does not work for ffmpeg, which is a single console executable.
  • <SkipCodesignItems/> msbuild item group, which allows using pre-signed binaries (and not to break the signature during the build). This may be helpful for the binaries built by me, but not for the ready-to-use binary builds of the ffmpeg taken from the official ffmpeg site.
  • Fully custom logic like <Exec Command="codesign" .../>. This works, but making it consistent with the project signing settings requires a lot of code and finally it is a little bit "code smell."

So, none of the existing options provides an easy-to-use and robust solution.

Proposal

Extend or rework the <CodesignBundle/> functionality to allow signing not only app bundles but also single executable files.

Note: such a binaries (e.g. ffmpeg) are often distributed as a bundles containing multiple executables (e.g. ffmpeg and ffprobe) as well as their dependencies (dylibs, etc). Therefore, the wildcards support (to be able to include the whole folder with all its content and, ideally, somehow filter out non-binary/non-signable files) will be more important in this scenario than in case when including app bundles.

Activity

  1. added
    macOS
    Mac Catalyst
    on Sep 19, 2025
  2. rolfbjarne commented on Sep 19, 2025

    @rolfbjarne
  3. added this to the .NET 11 milestone on Sep 19, 2025
  4. modified the milestones: .NET 11, .NET 12 on Jul 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Mac CatalystmacOS

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions