Compare commits
12 Commits
Author | SHA1 | Date | |
---|---|---|---|
914418860e | |||
7f640273ef | |||
04e99acaff | |||
491fa8fb98 | |||
|
89583a609c | ||
|
a40a668aab | ||
|
218e186f7e | ||
|
fdce795536 | ||
|
8ae043fc12 | ||
|
ee119e10d6 | ||
|
2c0eef4970 | ||
|
865adb9f3d |
10
CHANGELOG.md
Normal file
10
CHANGELOG.md
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
# Change log
|
||||||
|
|
||||||
|
All notable changes to the project will be documented in this file. This project adheres to [Semantic Versioning](http://semver.org).
|
||||||
|
|
||||||
|
## [1.0.1] - 2020-06-11
|
||||||
|
### Added:
|
||||||
|
- Added `go.mod` file so this package can now be consumed as a module. Since the major version is still `1` and it does not have any module-only dependencies, it can still be used by non-module projects as well.
|
||||||
|
|
||||||
|
## [1.0.0] - 2019-07-16
|
||||||
|
Initial release of this fork. The only change from the upstream code is that its dependency on `github.com/Azure/go-ntlmssp` has been replaced with `github.com/launchdarkly/go-ntlmssp`(https://github.com/launchdarkly/go-ntlmssp).
|
@@ -2,10 +2,11 @@
|
|||||||
|
|
||||||
[](https://opensource.org/licenses/MIT)
|
[](https://opensource.org/licenses/MIT)
|
||||||
[](https://godoc.org/github.com/launchdarkly/go-ntlm-proxy-auth)
|
[](https://godoc.org/github.com/launchdarkly/go-ntlm-proxy-auth)
|
||||||
|
[](https://circleci.com/gh/launchdarkly/go-ntlm-proxy-auth)
|
||||||
|
|
||||||
With this package, you can connect to http/https servers protected by an NTLM proxy in Golang.
|
With this package, you can connect to http/https servers protected by an NTLM proxy in Golang.
|
||||||
|
|
||||||
This is a fork of https://github.com/Codehardt/go-ntlm-proxy-auth which adds support for HTTPS proxy URLs. It also uses the fork https://github.com/launchdarkly/go-ntlmssp instead of `github.com/Azure/go-ntlmssp`.
|
This is a fork of https://github.com/launchdarkly/go-ntlm-proxy-auth to enable extra debugging
|
||||||
|
|
||||||
## Example: NewNTLMProxyDialContext
|
## Example: NewNTLMProxyDialContext
|
||||||
|
|
||||||
|
7
go.mod
Normal file
7
go.mod
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
module git.coadcorp.com/nathan/go-ntlm-proxy-auth
|
||||||
|
|
||||||
|
go 1.24.1
|
||||||
|
|
||||||
|
require git.coadcorp.com/nathan/go-ntlmssp v1.0.5
|
||||||
|
|
||||||
|
require golang.org/x/crypto v0.36.0 // indirect
|
10
go.sum
Normal file
10
go.sum
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
git.coadcorp.com/nathan/go-ntlmssp v1.0.2 h1:7vx6sF5AK97ff+1PXxQnCd3AZ4ey/X61Qd4y7Y2OG7s=
|
||||||
|
git.coadcorp.com/nathan/go-ntlmssp v1.0.2/go.mod h1:/0x9Ju5bWF978Vb+kMMfl+GYk5/j7CFq5yAsjEXOG8g=
|
||||||
|
git.coadcorp.com/nathan/go-ntlmssp v1.0.3 h1:X0nF9f6MPcnV5sPsPpaERcHGucCzeDl484hA4DwGsNA=
|
||||||
|
git.coadcorp.com/nathan/go-ntlmssp v1.0.3/go.mod h1:/0x9Ju5bWF978Vb+kMMfl+GYk5/j7CFq5yAsjEXOG8g=
|
||||||
|
git.coadcorp.com/nathan/go-ntlmssp v1.0.4 h1:46bdUfeI6wefpEpJFWsD4LyZVKREPMdfU9zrwQKLOZc=
|
||||||
|
git.coadcorp.com/nathan/go-ntlmssp v1.0.4/go.mod h1:/0x9Ju5bWF978Vb+kMMfl+GYk5/j7CFq5yAsjEXOG8g=
|
||||||
|
git.coadcorp.com/nathan/go-ntlmssp v1.0.5 h1:ODZUSXMV/d2NWgwTx6VkexmoFpBG0hXW2mvEIVKu4sg=
|
||||||
|
git.coadcorp.com/nathan/go-ntlmssp v1.0.5/go.mod h1:/0x9Ju5bWF978Vb+kMMfl+GYk5/j7CFq5yAsjEXOG8g=
|
||||||
|
golang.org/x/crypto v0.36.0 h1:AnAEvhDddvBdpY+uR+MyHmuZzzNqXSe/GvuDeob5L34=
|
||||||
|
golang.org/x/crypto v0.36.0/go.mod h1:Y4J0ReaxCR1IMaabaSMugxJES1EpwhBHhv2bDHklZvc=
|
6
ntlm.go
6
ntlm.go
@@ -7,13 +7,13 @@ import (
|
|||||||
"encoding/base64"
|
"encoding/base64"
|
||||||
"errors"
|
"errors"
|
||||||
"fmt"
|
"fmt"
|
||||||
"io/ioutil"
|
"io"
|
||||||
"net"
|
"net"
|
||||||
"net/http"
|
"net/http"
|
||||||
"net/url"
|
"net/url"
|
||||||
"strings"
|
"strings"
|
||||||
|
|
||||||
ntlmssp "github.com/launchdarkly/go-ntlmssp"
|
ntlmssp "git.coadcorp.com/nathan/go-ntlmssp"
|
||||||
)
|
)
|
||||||
|
|
||||||
// DialContext is the DialContext function that should be wrapped with a
|
// DialContext is the DialContext function that should be wrapped with a
|
||||||
@@ -86,7 +86,7 @@ func dialAndNegotiate(addr, proxyUsername, proxyPassword, proxyDomain string, ba
|
|||||||
debugf("ntlm> Could not read response from proxy: %s", err)
|
debugf("ntlm> Could not read response from proxy: %s", err)
|
||||||
return conn, err
|
return conn, err
|
||||||
}
|
}
|
||||||
_, err = ioutil.ReadAll(resp.Body)
|
_, err = io.ReadAll(resp.Body)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
debugf("ntlm> Could not read response body from proxy: %s", err)
|
debugf("ntlm> Could not read response body from proxy: %s", err)
|
||||||
return conn, err
|
return conn, err
|
||||||
|
Reference in New Issue
Block a user