Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do you install a certificate in a PFX file in to the personal container of the NT-AUTHORITY\NetworkService?

I have a .PXF file used to strongly name several of our .NET assemblies. VS2010/MSBUILD seems to expect this to be in the personal container for the user account running VS2010/MSBUILD. This is all just fine and dandy when working in an interactive user account, but when atempting an automated build via TFS 2010 on the build agent the account used by the build agent (by default) is NT-AUTHORITY/NetworkService.

Since I cannot log in an interacive session as NetworkService I cant just install the PFX from an interactive sessions shell.

So can anyone tell me how I install a PFX certificate in the personal cert store of the NetworkService account?

like image 833
Pete Stensønes Avatar asked Apr 17 '11 18:04

Pete Stensønes


1 Answers

Answer Courtesey of Richard Reposed from serverfault

You need to open the Network Service certificate store, and add it.

To open the store:

  • From Start | Run: mmc.exe
  • File | Add/Remove Snapins and select Certificates then Add.
  • When prompted for the type of account select Service Account
  • Select local/remote computer as required
  • Select any service that's running as Network Service ("Remote Procedure Call (RPC)" run as Network Service by default)
  • Finish the wizard and OK to close the add/remove dialog.
  • On the applicable catrgory right click and select add tasks to find the import etc. operations.
like image 105
Pete Stensønes Avatar answered Nov 20 '22 16:11

Pete Stensønes