Skip to content

Commit cbadf4f

Browse files
NuGet instructions
1 parent 1abaad6 commit cbadf4f

1 file changed

Lines changed: 29 additions & 0 deletions

File tree

Src/DSInternals.Replication/PACKAGE.md

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,35 @@ The **DSInternals.Replication** package implements a client for the **Active Dir
1313
- **KDS Root Key Access**: Retrieve Key Distribution Service root keys for gMSA password computation
1414
- **Schema Replication**: Replicate the Active Directory schema
1515

16+
## Platform Compatibility
17+
18+
Applications using this library may encounter the `BadImageFormatException` or `FileNotFoundException` exceptions
19+
when trying to load the `DSInternals.Replication.Interop.dll` assembly.
20+
This is because the assembly contains platform-specific code.
21+
To resolve this issue, ensure that your project is configured to target the appropriate platform (x64, x86, or arm64).
22+
23+
Modern SDK-style projects should contain these settings:
24+
25+
```xml
26+
<PropertyGroup>
27+
<TargetFrameworks>net10.0-windows;net48</TargetFrameworks>
28+
<RuntimeIdentifier>win-x64</RuntimeIdentifier>
29+
</PropertyGroup>
30+
<ItemGroup>
31+
<PackageReference Include="DSInternals.Replication" Version="6.3.0" />
32+
</ItemGroup>
33+
```
34+
35+
Legacy .NET Framework projects using `packages.config` should contain the following settings:
36+
37+
```xml
38+
<Import Project="packages\DSInternals.Replication.6.3.0\build\net48\DSInternals.Replication.props" Condition="Exists('packages\DSInternals.Replication.6.3.0\build\net48\DSInternals.Replication.props')" />
39+
<PropertyGroup>
40+
<Prefer32Bit>false</Prefer32Bit>
41+
<PreferNativeArm64>true</PreferNativeArm64>
42+
</PropertyGroup>
43+
```
44+
1645
## Usage Examples
1746

1847
### Connecting to a Domain Controller

0 commit comments

Comments
 (0)