---
title: SqlPackageParams System Parameter – DacFx Encryption and Certificate Trust
description: The SqlPackageParams System Parameter sets the encryption and certificate trust options Nodinite passes to SqlPackage.exe (DacFx) when it creates or updates Log Databases. JSON format, default values, and when to change them.
---

# SqlPackageParams - System Parameter

The **SqlPackageParams** [System Parameter][System Parameters] sets the connection security options that <span class="nodinite-product-name" title="The node that unites different systems. Or as we call it Nodinite">Nodinite</span> passes to `SqlPackage.exe` (DacFx) when it deploys [Log Databases][]: whether the connection is encrypted, and whether the SQL Server certificate is trusted without validation. The [Logging Service][] reads it when it creates a new Log Database; the path to `SqlPackage.exe` comes from [SqlPackageExecutable][].

<h2 id="at-a-glance"><i class="fal fa-table" aria-hidden="true"></i> At a Glance</h2>

| Property | Value |
| --- | --- |
| Key | `SqlPackageParams` |
| Data type | json |
| Default | `{"TargetTrustServerCertificate":true,"TargetEncryptConnection":true,"SourceTrustServerCertificate":false,"SourceEncryptConnection":true}` |
| Read by | [Logging Service][] |
| Takes effect | Within about 15 seconds; no restart needed |
| Status | ✅ Active |
| Since | Nodinite 5.4.1.26 |

## <i class="fal fa-gears" aria-hidden="true"></i> How It Works

When the [Logging Service][] creates a new [Log Database][Log Databases], it runs `SqlPackage.exe` and adds one command-line option per property in this parameter, for example `/TargetEncryptConnection:true /TargetTrustServerCertificate:true`. The **Target** options apply to the SQL Server instance that receives the Log Database. The **Source** options apply when `SqlPackage.exe` reads from a source database connection instead of a `.dacpac` file. The [Update Log Database][] guide generates `SqlPackage.exe` commands with the same kind of options.

DacFx 161 and later (built on Microsoft.Data.SqlClient) encrypt connections by default. With a self-signed SQL Server certificate, a connection then fails unless the certificate is trusted, which is why `TargetTrustServerCertificate` defaults to `true`. Use DacFx 161 or later; see [SqlPackageExecutable][].

## <i class="fal fa-code" aria-hidden="true"></i> Value Format

A JSON object; each property maps to the `SqlPackage.exe` option with the same name.

| Property | Type | Default | Meaning |
| --- | --- | --- | --- |
| `TargetTrustServerCertificate` | boolean | `true` | Trust the target SQL Server's certificate without validating it. Set `false` when the SQL Server has a certificate from a trusted CA |
| `TargetEncryptConnection` | boolean | `true` | Encrypt the connection to the target SQL Server. Keep `true` |
| `SourceTrustServerCertificate` | boolean | `false` | Trust the source SQL Server's certificate without validating it |
| `SourceEncryptConnection` | boolean | `true` | Encrypt the connection to the source SQL Server. Keep `true` |

```json
{"TargetTrustServerCertificate":true,"TargetEncryptConnection":true,"SourceTrustServerCertificate":false,"SourceEncryptConnection":true}
```

## <i class="fal fa-lightbulb" aria-hidden="true"></i> Choosing a Value

* **Keep the default** unless your security policy requires certificate validation.
* **Production with a CA-signed SQL Server certificate**: set `TargetTrustServerCertificate` to `false`, so the certificate is validated. The certificate must then match the server name in [SqlServer][] and chain to a trusted root on the <span class="nodinite-product-name" title="The node that unites different systems. Or as we call it Nodinite">Nodinite</span> application server.
* **Self-signed certificate** (common in test): keep `TargetTrustServerCertificate` = `true`; with `false`, Log Database creation fails with a certificate trust error.
* **Don't turn encryption off.** Setting `TargetEncryptConnection` or `SourceEncryptConnection` to `false` sends the deployment unencrypted.

## <i class="fal fa-hand-point-right" aria-hidden="true"></i> Next Steps

* <i class="fal fa-database" aria-hidden="true"></i> [Update Log Database][]  
* <i class="fal fa-list" aria-hidden="true"></i> [Manage Log Databases][]  
* <i class="fal fa-pen-to-square" aria-hidden="true"></i> [Manage System Parameters][]  

## <i class="fal fa-link-horizontal" aria-hidden="true"></i> Related Topics

* <i class="fal fa-pen-square" aria-hidden="true"></i> [SqlPackageExecutable][]  
* <i class="fal fa-server" aria-hidden="true"></i> [SqlServer][]  
* <i class="fal fa-life-ring" aria-hidden="true"></i> [LogDatabaseRecovery][]  
* <i class="fal fa-hard-drive" aria-hidden="true"></i> [Logging Service][]  
* <i class="fal fa-database" aria-hidden="true"></i> [Log Databases][]  
* <i class="fal fa-cog" aria-hidden="true"></i> [System Parameters][]  

<aside aria-label="Note" class="nodinite-note nodinite-note--note">
<p class="nodinite-note__label" aria-hidden="true"><i class="far fa-fw fa-note"></i> Note</p>
<div class="nodinite-note__content"><p><span class="nodinite-product-name" title="The node that unites different systems. Or as we call it Nodinite">Nodinite</span> v6 and its Install and Update Tool are no longer supported. Older installations needed matching versions: DacFx 161 or later requires <span class="nodinite-product-name" title="The node that unites different systems. Or as we call it Nodinite">Nodinite</span> 5.4.1.26 or later (Install and Update Tool 6.0.0.5 or later); earlier <span class="nodinite-product-name" title="The node that unites different systems. Or as we call it Nodinite">Nodinite</span> versions need DacFx older than 161.</p></div>
</aside>

[Log Databases]:https://docs.nodinite.com/core-services/log-databases/overview/
[LogDatabaseRecovery]:https://docs.nodinite.com/administration/settings/system-parameters/logdatabaserecovery/
[Logging Service]:https://docs.nodinite.com/core-services/logging-service/overview/
[Manage Log Databases]:https://docs.nodinite.com/administration/settings/log-databases/overview/
[Manage System Parameters]:https://docs.nodinite.com/administration/settings/system-parameters/manage-system-parameters/
[SqlPackageExecutable]:https://docs.nodinite.com/administration/settings/system-parameters/sqlpackageexecutable/
[SqlServer]:https://docs.nodinite.com/administration/settings/system-parameters/sqlserver/
[System Parameters]:https://docs.nodinite.com/administration/settings/system-parameters/overview/
[Update Log Database]:https://docs.nodinite.com/administration/settings/log-databases/update-log-database/