NTLM/Negotiate authentication over HTTP
Перейти к файлу
microsoft-github-policy-service[bot] 754e693213
Auto merge mandatory file pr
This pr is auto merged as it contains a mandatory file and is opened for more than 10 days.
2022-11-28 19:35:59 +00:00
.travis.yml Fix golint import path 2019-11-15 20:26:31 +00:00
LICENSE Update LICENSE 2016-03-04 13:44:56 -08:00
README.md update README with example 2017-07-25 09:51:09 -04:00
SECURITY.md Microsoft mandatory file 2022-10-18 18:18:00 +00:00
authenticate_message.go Support UPN 2022-06-13 13:15:25 +00:00
authheader.go Adding Basic() method alongside of IsBasic() 2021-12-09 11:20:09 +01:00
avids.go Initial commit of implementation 2015-10-16 21:50:49 -07:00
challenge_message.go Initial commit of implementation 2015-10-16 21:50:49 -07:00
messageheader.go Initial commit of implementation 2015-10-16 21:50:49 -07:00
negotiate_flags.go gofmt 2018-04-13 09:50:16 +01:00
negotiate_message.go Negotiation fails for servers where 'NTLMv2 session security' is required (#18) 2018-08-10 10:55:52 -07:00
negotiator.go Fix SAM case 2022-06-13 14:24:43 +00:00
nlmp.go Initial commit of implementation 2015-10-16 21:50:49 -07:00
nlmp_test.go added test TestCalculateNTLMv2ResponseWithHash 2020-06-13 11:40:16 -05:00
unicode.go Initial commit of implementation 2015-10-16 21:50:49 -07:00
varfield.go Initial commit of implementation 2015-10-16 21:50:49 -07:00
version.go add version, domain and workstation fields 2018-04-12 18:05:24 +01:00

README.md

go-ntlmssp

Golang package that provides NTLM/Negotiate authentication over HTTP

GoDoc Build Status

Protocol details from https://msdn.microsoft.com/en-us/library/cc236621.aspx Implementation hints from http://davenport.sourceforge.net/ntlm.html

This package only implements authentication, no key exchange or encryption. It only supports Unicode (UTF16LE) encoding of protocol strings, no OEM encoding. This package implements NTLMv2.

Usage

url, user, password := "http://www.example.com/secrets", "robpike", "pw123"
client := &http.Client{
  Transport: ntlmssp.Negotiator{
    RoundTripper:&http.Transport{},
  },
}

req, _ := http.NewRequest("GET", url, nil)
req.SetBasicAuth(user, password)
res, _ := client.Do(req)

This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact opencode@microsoft.com with any additional questions or comments.