[GH-ISSUE #3] Install-TransportAgent: Could not load file or assembly #2

Closed
opened 2026-02-26 10:35:09 +03:00 by kerem · 6 comments
Owner

Originally created by @ChronoGuru on GitHub (Apr 11, 2013).
Original GitHub issue: https://github.com/Pro/dkim-exchange/issues/3

Following the instructions, I have the files in the file location mentioned. When I run the command for "Install-TransportAgent" this is the output error I receive:

"[PS] C:\Windows\system32>Install-TransportAgent -Name "Exchange DKIM" -TransportAgentFactory "Exchange.DkimSigner.DkimSi
gningRoutingAgentFactory" -AssemblyPath "C:\Program Files\Exchange DKIM\Exchange.DkimSigner.dll"
Install-TransportAgent : Could not load file or assembly 'file:///C:\Program Files\Exchange DKIM\Exchange.DkimSigner.dl
l' or one of its dependencies. The module was expected to contain an assembly manifest.
At line:1 char:23

  • Install-TransportAgent <<<< -Name "Exchange DKIM" -TransportAgentFactory "Exchange.DkimSigner.DkimSigningRoutingAgen
    tFactory" -AssemblyPath "C:\Program Files\Exchange DKIM\Exchange.DkimSigner.dll"
    • CategoryInfo : InvalidArgument: (:) [Install-TransportAgent], BadImageFormatException
    • FullyQualifiedErrorId : 3A0C3419,Microsoft.Exchange.Management.AgentTasks.InstallTransportAgent"
Originally created by @ChronoGuru on GitHub (Apr 11, 2013). Original GitHub issue: https://github.com/Pro/dkim-exchange/issues/3 Following the instructions, I have the files in the file location mentioned. When I run the command for "Install-TransportAgent" this is the output error I receive: "[PS] C:\Windows\system32>Install-TransportAgent -Name "Exchange DKIM" -TransportAgentFactory "Exchange.DkimSigner.DkimSi gningRoutingAgentFactory" -AssemblyPath "C:\Program Files\Exchange DKIM\Exchange.DkimSigner.dll" Install-TransportAgent : Could not load file or assembly 'file:///C:\Program Files\Exchange DKIM\Exchange.DkimSigner.dl l' or one of its dependencies. The module was expected to contain an assembly manifest. At line:1 char:23 - Install-TransportAgent <<<< -Name "Exchange DKIM" -TransportAgentFactory "Exchange.DkimSigner.DkimSigningRoutingAgen tFactory" -AssemblyPath "C:\Program Files\Exchange DKIM\Exchange.DkimSigner.dll" - CategoryInfo : InvalidArgument: (:) [Install-TransportAgent], BadImageFormatException - FullyQualifiedErrorId : 3A0C3419,Microsoft.Exchange.Management.AgentTasks.InstallTransportAgent"
kerem closed this issue 2026-02-26 10:35:10 +03:00
Author
Owner

@ChronoGuru commented on GitHub (Apr 12, 2013):

I resolved this by renaming the files and commands from Exchange.DkimSigner.dl to ExchangeDkimSigner.dll......looks like the extra period in the filename was causing the issue.

Thank you very much for this! I spent a good portion of the day implementing it but so far it's working well! I can't believe the lengths we have to go through just to email Yahoo.

<!-- gh-comment-id:16287819 --> @ChronoGuru commented on GitHub (Apr 12, 2013): I resolved this by renaming the files and commands from Exchange.DkimSigner.dl to ExchangeDkimSigner.dll......looks like the extra period in the filename was causing the issue. Thank you very much for this! I spent a good portion of the day implementing it but so far it's working well! I can't believe the lengths we have to go through just to email Yahoo.
Author
Owner

@Pro commented on GitHub (Apr 12, 2013):

Can you tell which OS and Exchange Version you use?
We are using Win 2008 R2 and Exchange 2010 (newest Service Pack) and didn't have that problem...

<!-- gh-comment-id:16288168 --> @Pro commented on GitHub (Apr 12, 2013): Can you tell which OS and Exchange Version you use? We are using Win 2008 R2 and Exchange 2010 (newest Service Pack) and didn't have that problem...
Author
Owner

@ChronoGuru commented on GitHub (Apr 12, 2013):

Same actually, 2008 R2 and Exchange 2010 SP3. I'm not sure of the difference between our environments then unfortunately, I just know I had to do that to get it to work. For some reason it didn't like the extra period in the filename, so I had to change:

"Install-TransportAgent -Name "Exchange DKIM" -TransportAgentFactory "Exchange.DkimSigner.DkimSigningRoutingAgentFactory" -AssemblyPath "C:\Program Files\Exchange DKIM\Exchange.DkimSigner.dll"

to:

"Install-TransportAgent -Name "Exchange DKIM" -TransportAgentFactory "Exchange.DkimSigner.DkimSigningRoutingAgentFactory" -AssemblyPath "C:\Program Files\Exchange DKIM\ExchangeDkimSigner.dll"

As well as rename both the Exchange.DkimSigner.dll config and application extension to match.

<!-- gh-comment-id:16288301 --> @ChronoGuru commented on GitHub (Apr 12, 2013): Same actually, 2008 R2 and Exchange 2010 SP3. I'm not sure of the difference between our environments then unfortunately, I just know I had to do that to get it to work. For some reason it didn't like the extra period in the filename, so I had to change: "Install-TransportAgent -Name "Exchange DKIM" -TransportAgentFactory "Exchange.DkimSigner.DkimSigningRoutingAgentFactory" -AssemblyPath "C:\Program Files\Exchange DKIM\Exchange.DkimSigner.dll" to: "Install-TransportAgent -Name "Exchange DKIM" -TransportAgentFactory "Exchange.DkimSigner.DkimSigningRoutingAgentFactory" -AssemblyPath "C:\Program Files\Exchange DKIM\ExchangeDkimSigner.dll" As well as rename both the Exchange.DkimSigner.dll config and application extension to match.
Author
Owner

@Pro commented on GitHub (Apr 12, 2013):

Ok, thanks.
I think this is related to:
http://social.msdn.microsoft.com/Forums/en-US/vsdebug/thread/9ad17869-63cc-4529-bfaf-9099db500e0d/
This means that renaming the file to any other filename (with or without extra period) fixes the problem.

I'll dig deeper, to find the cause of this problem.

<!-- gh-comment-id:16288382 --> @Pro commented on GitHub (Apr 12, 2013): Ok, thanks. I think this is related to: http://social.msdn.microsoft.com/Forums/en-US/vsdebug/thread/9ad17869-63cc-4529-bfaf-9099db500e0d/ This means that renaming the file to any other filename (with or without extra period) fixes the problem. I'll dig deeper, to find the cause of this problem.
Author
Owner

@ChronoGuru commented on GitHub (Apr 12, 2013):

No problem, thanks again for uploading this! You're a life saver.

<!-- gh-comment-id:16288416 --> @ChronoGuru commented on GitHub (Apr 12, 2013): No problem, thanks again for uploading this! You're a life saver.
Author
Owner

@Pro commented on GitHub (Nov 26, 2013):

Today I commited a new install script. This should fix common install problems.
Simply follow the the instructions here: https://github.com/Pro/dkim-exchange#update-from-version-05 or install from scratch https://github.com/Pro/dkim-exchange#installing-the-transport-agent

<!-- gh-comment-id:29335146 --> @Pro commented on GitHub (Nov 26, 2013): Today I commited a new install script. This should fix common install problems. Simply follow the the instructions here: https://github.com/Pro/dkim-exchange#update-from-version-05 or install from scratch https://github.com/Pro/dkim-exchange#installing-the-transport-agent
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/dkim-exchange-Pro#2
No description provided.