tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

nsHttpNTLMAuth.h (883B)


      1 /* This Source Code Form is subject to the terms of the Mozilla Public
      2 * License, v. 2.0. If a copy of the MPL was not distributed with this
      3 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
      4 
      5 #ifndef nsHttpNTLMAuth_h__
      6 #define nsHttpNTLMAuth_h__
      7 
      8 #include "nsIHttpAuthenticator.h"
      9 #include "mozilla/StaticPtr.h"
     10 
     11 namespace mozilla {
     12 namespace net {
     13 
     14 class nsHttpNTLMAuth : public nsIHttpAuthenticator {
     15 public:
     16  NS_DECL_ISUPPORTS
     17  NS_DECL_NSIHTTPAUTHENTICATOR
     18 
     19  nsHttpNTLMAuth() = default;
     20 
     21  static already_AddRefed<nsIHttpAuthenticator> GetOrCreate();
     22 
     23 private:
     24  virtual ~nsHttpNTLMAuth() = default;
     25 
     26  // This flag indicates whether we are using the native NTLM implementation
     27  // or the internal one.
     28  bool mUseNative{false};
     29 
     30  static StaticRefPtr<nsHttpNTLMAuth> gSingleton;
     31 };
     32 
     33 }  // namespace net
     34 }  // namespace mozilla
     35 
     36 #endif  // !nsHttpNTLMAuth_h__