Skip to content

Commit aa8eb08

Browse files
author
david.kotval
committed
fix: corrected libgssapi behavior so it works on linux
1 parent 36c4db8 commit aa8eb08

File tree

4 files changed

+57
-4
lines changed

4 files changed

+57
-4
lines changed

Cargo.lock

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

connectorx-python/Cargo.lock

Lines changed: 53 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

connectorx/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ regex = {version = "1", optional = true}
5050
rusqlite = {version = "0.27.0", features = ["column_decltype", "chrono", "bundled"], optional = true}
5151
rust_decimal = {version = "1", features = ["db-postgres"], optional = true}
5252
rust_decimal_macros = {version = "1", optional = true}
53-
tiberius = {version = "0.5", features = ["rust_decimal", "chrono"], optional = true}
53+
tiberius = {version = "0.5", features = ["rust_decimal", "chrono", "integrated-auth-gssapi"], optional = true}
5454
tokio = {version = "1", features = ["rt", "rt-multi-thread", "net"], optional = true}
5555
tokio-util = {version = "0.6", optional = true}
5656
urlencoding = {version = "2.1", optional = true}

connectorx/src/sources/mssql/mod.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ pub fn mssql_config(url: &Url) -> Config {
6363
// Using SQL Server authentication.
6464
#[allow(unused)]
6565
let params: HashMap<String, String> = url.query_pairs().into_owned().collect();
66-
#[cfg_attr(any(target_os = "windows", feature = "integrated-auth-gssapi"))]
66+
#[cfg(any(windows,feature = "integrated-auth-gssapi"))]
6767
match params.get("trusted_connection") {
6868
// pefer trusted_connection if set to true
6969
Some(v) if v == "true" => {
@@ -78,7 +78,7 @@ pub fn mssql_config(url: &Url) -> Config {
7878
));
7979
}
8080
};
81-
#[cfg(not(windows))]
81+
#[cfg(all(not(windows),not(feature = "integrated-auth-gssapi")))]
8282
config.authentication(AuthMethod::sql_server(
8383
decode(url.username())?.to_owned(),
8484
decode(url.password().unwrap_or(""))?.to_owned(),

0 commit comments

Comments
 (0)