michael@0: /* -*- Mode: idl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ michael@0: /* This Source Code Form is subject to the terms of the Mozilla Public michael@0: * License, v. 2.0. If a copy of the MPL was not distributed with this michael@0: * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ michael@0: michael@0: #include "nsISupports.idl" michael@0: michael@0: [scriptable, uuid(bd9dc0fa-68ce-47d0-8859-6418c2ae8576)] michael@0: interface nsIAuthPromptProvider : nsISupports michael@0: { michael@0: /** michael@0: * Normal (non-proxy) prompt request. michael@0: */ michael@0: const uint32_t PROMPT_NORMAL = 0; michael@0: michael@0: /** michael@0: * Proxy auth request. michael@0: */ michael@0: const uint32_t PROMPT_PROXY = 1; michael@0: michael@0: /** michael@0: * Request a prompt interface for the given prompt reason; michael@0: * @throws NS_ERROR_NOT_AVAILABLE if no prompt is allowed or michael@0: * available for the given reason. michael@0: * michael@0: * @param aPromptReason The reason for the auth prompt; michael@0: * one of #PROMPT_NORMAL or #PROMPT_PROXY michael@0: * @param iid The desired interface, e.g. michael@0: * NS_GET_IID(nsIAuthPrompt2). michael@0: * @returns an nsIAuthPrompt2 interface, or throws NS_ERROR_NOT_AVAILABLE michael@0: */ michael@0: void getAuthPrompt(in uint32_t aPromptReason, in nsIIDRef iid, michael@0: [iid_is(iid),retval] out nsQIResult result); michael@0: };