diff -r 000000000000 -r 6474c204b198 security/manager/ssl/public/nsITokenPasswordDialogs.idl --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/security/manager/ssl/public/nsITokenPasswordDialogs.idl Wed Dec 31 06:09:35 2014 +0100 @@ -0,0 +1,34 @@ +/* This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ + +#include "nsISupports.idl" + +interface nsIInterfaceRequestor; + + +/** + * nsITokenPasswordDialogs + * This is the interface for setting and changing password + * on a PKCS11 token. + */ +[scriptable, uuid(be26b580-1dd1-11b2-9946-c598d0d07727)] +interface nsITokenPasswordDialogs : nsISupports +{ + /** + * setPassword - sets the password/PIN on the named token. + * The canceled output value should be set to TRUE when + * the user (or implementation) cancels the operation. + */ + void setPassword(in nsIInterfaceRequestor ctx, in wstring tokenName, + out boolean canceled); + + void getPassword(in nsIInterfaceRequestor ctx, + in wstring tokenName, + out wstring password, + out boolean canceled); +}; + +%{C++ +#define NS_TOKENPASSWORDSDIALOG_CONTRACTID "@mozilla.org/nsTokenPasswordDialogs;1" +%}