From 6412be75e44d6cdb3e87e43b462bf63e094fc9bc Mon Sep 17 00:00:00 2001 From: "shaver%mozilla.org" Date: Tue, 12 Sep 2000 02:35:29 +0000 Subject: [PATCH] Part 1.1 of 18352 (remove extensions/ dependencies from non-extensions/ code): Teach netwerk about nsIPasswordManager. (Craves better interfaces, current versions just C&P'd from wallet's.) r=valeski,a=brendan --- netwerk/base/public/MANIFEST | 1 + netwerk/base/public/MANIFEST_IDL | 1 + netwerk/base/public/Makefile.in | 36 +++++++++--------- netwerk/base/public/makefile.win | 2 + netwerk/base/public/nsIPasswordManager.idl | 38 +++++++++++++++++++ netwerk/base/public/nsIPasswordManagerUtils.h | 30 +++++++++++++++ 6 files changed, 91 insertions(+), 17 deletions(-) create mode 100644 netwerk/base/public/nsIPasswordManager.idl create mode 100644 netwerk/base/public/nsIPasswordManagerUtils.h diff --git a/netwerk/base/public/MANIFEST b/netwerk/base/public/MANIFEST index 73716e1f718..372fd7e9c38 100644 --- a/netwerk/base/public/MANIFEST +++ b/netwerk/base/public/MANIFEST @@ -5,3 +5,4 @@ netCore.h nsNetUtil.h nsUnixColorPrintf.h +nsIPasswordManagerUtils.h diff --git a/netwerk/base/public/MANIFEST_IDL b/netwerk/base/public/MANIFEST_IDL index dddea9cbd12..ee5d07d2d46 100644 --- a/netwerk/base/public/MANIFEST_IDL +++ b/netwerk/base/public/MANIFEST_IDL @@ -5,6 +5,7 @@ nsIAuthenticator.idl nsIChannel.idl nsIFileTransportService.idl +nsIPasswordManager.idl nsIPrompt.idl nsIProtocolProxyService.idl nsIProxyAutoConfig.idl diff --git a/netwerk/base/public/Makefile.in b/netwerk/base/public/Makefile.in index ae5c5b14742..36d4696b905 100644 --- a/netwerk/base/public/Makefile.in +++ b/netwerk/base/public/Makefile.in @@ -30,31 +30,32 @@ MODULE = necko XPIDLSRCS = \ nsIAuthenticator.idl \ - nsIFileStreams.idl \ - nsIRequest.idl \ nsIChannel.idl \ - nsIURI.idl \ - nsIURL.idl \ - nsIStreamObserver.idl \ - nsIStreamListener.idl \ + nsIFileStreams.idl \ + nsIFileTransportService.idl \ nsIIOService.idl \ - nsIPrompt.idl \ - nsIProtocolHandler.idl \ - nsIProgressEventSink.idl \ + nsILoadGroup.idl \ nsINetModRegEntry.idl \ nsINetModuleMgr.idl \ nsINetNotify.idl \ - nsILoadGroup.idl \ - nsIFileTransportService.idl \ - nsISocketTransportService.idl \ - nsIStreamIO.idl \ - nsIStreamLoader.idl \ - nsISocketTransport.idl \ - nsIURLParser.idl \ + nsIPasswordManager.idl \ + nsIProgressEventSink.idl \ + nsIPrompt.idl \ + nsIProtocolHandler.idl \ + nsIProtocolProxyService.idl \ nsIProxy.idl \ nsIProxyAutoConfig.idl \ nsIProxyAutoConfigUtils.idl \ - nsIProtocolProxyService.idl \ + nsIRequest.idl \ + nsISocketTransport.idl \ + nsISocketTransportService.idl \ + nsIStreamIO.idl \ + nsIStreamListener.idl \ + nsIStreamLoader.idl \ + nsIStreamObserver.idl \ + nsIURI.idl \ + nsIURL.idl \ + nsIURLParser.idl \ nsIWebFilters.idl \ $(NULL) @@ -62,6 +63,7 @@ EXPORTS = \ netCore.h \ nsNetUtil.h \ nsUnixColorPrintf.h \ + nsIPasswordManagerUtils.h \ $(NULL) include $(topsrcdir)/config/rules.mk diff --git a/netwerk/base/public/makefile.win b/netwerk/base/public/makefile.win index aab4b5ca4af..ce6e8782cf2 100644 --- a/netwerk/base/public/makefile.win +++ b/netwerk/base/public/makefile.win @@ -28,6 +28,7 @@ EXPORTS = \ netCore.h \ nsNetUtil.h \ nsUnixColorPrintf.h \ + nsIPasswordManagerUtils.h \ $(NULL) XPIDLSRCS = \ @@ -40,6 +41,7 @@ XPIDLSRCS = \ .\nsINetModRegEntry.idl \ .\nsINetModuleMgr.idl \ .\nsINetNotify.idl \ + .\nsIPasswordManager.idl \ .\nsIProgressEventSink.idl \ .\nsIPrompt.idl \ .\nsIProtocolHandler.idl \ diff --git a/netwerk/base/public/nsIPasswordManager.idl b/netwerk/base/public/nsIPasswordManager.idl new file mode 100644 index 00000000000..f9ea531ca2a --- /dev/null +++ b/netwerk/base/public/nsIPasswordManager.idl @@ -0,0 +1,38 @@ +/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 4 -*- + * + * The contents of this file are subject to the Mozilla Public + * License Version 1.1 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.mozilla.org/MPL/ + * + * Software distributed under the License is distributed on an "AS + * IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or + * implied. See the License for the specific language governing + * rights and limitations under the License. + * + * The Original Code is mozilla.org code. + * + * The Initial Developer of the Original Code is Zero-Knowledge + * Systems, Inc. Portions created by Zero-Knowledge are Copyright + * (C) 2000 Zero-Knowledge Systems, Inc. All Rights Reserved. + * + * Contributor(s): + */ + +#include "nsISupports.idl" + +/** + * Interface for password management (aka single-signon) componentry. + */ + +/* XXXshaver these came from the old wallet interfaces, and seem questionable */ +native nsAutoString(nsAutoString); +[ref] native nsAutoStringRef(nsAutoString); + +[scriptable, uuid(110c808c-1dd2-11b2-8de5-814d4485c444)] +interface nsIPasswordManager : nsISupports { + void removeUser(in string key, in wstring user); + void storePassword(in string key, in wstring user, in wstring pass); + [noscript] void getSignonListForViewer(in nsAutoStringRef aSignonList); + [noscript] void getRejectListForViewer(in nsAutoStringRef aRejectList); +}; diff --git a/netwerk/base/public/nsIPasswordManagerUtils.h b/netwerk/base/public/nsIPasswordManagerUtils.h new file mode 100644 index 00000000000..df726c7b763 --- /dev/null +++ b/netwerk/base/public/nsIPasswordManagerUtils.h @@ -0,0 +1,30 @@ +/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 4 -*- + * + * The contents of this file are subject to the Mozilla Public + * License Version 1.1 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.mozilla.org/MPL/ + * + * Software distributed under the License is distributed on an "AS + * IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or + * implied. See the License for the specific language governing + * rights and limitations under the License. + * + * The Original Code is mozilla.org code. + * + * The Initial Developer of the Original Code is Zero-Knowledge + * Systems, Inc. Portions created by Zero-Knowledge are Copyright + * (C) 2000 Zero-Knowledge Systems, Inc. All Rights Reserved. + * + * Contributor(s): + */ + +#ifndef NSIPASSWORDMANAGERUTILS_H__ +#define NSIPASSWORDMANAGERUTILS_H__ + +#include "nsIPasswordManager.h" + +/* XXX love me, rayw, love me true */ +#define PASSWORDMANAGER_PROGID "mozilla.network.password-manager.1" + +#endif /* NSIPASSWORDMANAGERUTILS_H__ */