nsISecurityWarningDialogs.h 8.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215
  1. /*
  2. * DO NOT EDIT. THIS FILE IS GENERATED FROM c:/mozilla/security/manager/boot/public/nsISecurityWarningDialogs.idl
  3. */
  4. #ifndef __gen_nsISecurityWarningDialogs_h__
  5. #define __gen_nsISecurityWarningDialogs_h__
  6. #ifndef __gen_nsISupports_h__
  7. #include "nsISupports.h"
  8. #endif
  9. /* For IDL files that don't want to include root IDL files. */
  10. #ifndef NS_NO_VTABLE
  11. #define NS_NO_VTABLE
  12. #endif
  13. class nsIInterfaceRequestor; /* forward declaration */
  14. /* starting interface: nsISecurityWarningDialogs */
  15. #define NS_ISECURITYWARNINGDIALOGS_IID_STR "1c399d06-1dd2-11b2-bc58-c87cbcacdb78"
  16. #define NS_ISECURITYWARNINGDIALOGS_IID \
  17. {0x1c399d06, 0x1dd2, 0x11b2, \
  18. { 0xbc, 0x58, 0xc8, 0x7c, 0xbc, 0xac, 0xdb, 0x78 }}
  19. /**
  20. * Functions that display warnings for transitions between secure
  21. * and insecure pages, posts to insecure servers etc.
  22. *
  23. * @status FROZEN
  24. */
  25. class NS_NO_VTABLE nsISecurityWarningDialogs : public nsISupports {
  26. public:
  27. NS_DEFINE_STATIC_IID_ACCESSOR(NS_ISECURITYWARNINGDIALOGS_IID)
  28. /**
  29. * Inform the user that a transition
  30. * from an insecure page
  31. * to a secure page
  32. * is happening.
  33. *
  34. * @param ctx A user interface context.
  35. *
  36. * @return true if the user confirms to continue
  37. */
  38. /* boolean confirmEnteringSecure (in nsIInterfaceRequestor ctx); */
  39. NS_IMETHOD ConfirmEnteringSecure(nsIInterfaceRequestor *ctx, PRBool *_retval) = 0;
  40. /**
  41. * Inform the user that a transition
  42. * from an insecure page
  43. * or from a secure page
  44. * to a weak security page
  45. * is happening.
  46. *
  47. * @param ctx A user interface context.
  48. *
  49. * @return true if the user confirms to continue
  50. */
  51. /* boolean confirmEnteringWeak (in nsIInterfaceRequestor ctx); */
  52. NS_IMETHOD ConfirmEnteringWeak(nsIInterfaceRequestor *ctx, PRBool *_retval) = 0;
  53. /**
  54. * Inform the user that a transition
  55. * from a secure page
  56. * to an insecure page
  57. * is happening.
  58. *
  59. * @param ctx A user interface context.
  60. *
  61. * @return true if the user confirms to continue
  62. */
  63. /* boolean confirmLeavingSecure (in nsIInterfaceRequestor ctx); */
  64. NS_IMETHOD ConfirmLeavingSecure(nsIInterfaceRequestor *ctx, PRBool *_retval) = 0;
  65. /**
  66. * Inform the user the currently displayed page
  67. * contains some secure and some insecure page components.
  68. *
  69. * @param ctx A user interface context.
  70. *
  71. * @return true if the user decides to show insecure objects.
  72. */
  73. /* boolean confirmMixedMode (in nsIInterfaceRequestor ctx); */
  74. NS_IMETHOD ConfirmMixedMode(nsIInterfaceRequestor *ctx, PRBool *_retval) = 0;
  75. /**
  76. * Inform the user that information is being submitted
  77. * to an insecure page.
  78. *
  79. * @param ctx A user interface context.
  80. *
  81. * @return true if the user confirms to submit.
  82. */
  83. /* boolean confirmPostToInsecure (in nsIInterfaceRequestor ctx); */
  84. NS_IMETHOD ConfirmPostToInsecure(nsIInterfaceRequestor *ctx, PRBool *_retval) = 0;
  85. /**
  86. * Inform the user: Although the currently displayed
  87. * page was loaded using a secure connection, and the UI probably
  88. * currently indicates a secure page,
  89. * that information is being submitted to an insecure page.
  90. *
  91. * @param ctx A user interface context.
  92. *
  93. * @return true if the user confirms to submit.
  94. */
  95. /* boolean confirmPostToInsecureFromSecure (in nsIInterfaceRequestor ctx); */
  96. NS_IMETHOD ConfirmPostToInsecureFromSecure(nsIInterfaceRequestor *ctx, PRBool *_retval) = 0;
  97. };
  98. /* Use this macro when declaring classes that implement this interface. */
  99. #define NS_DECL_NSISECURITYWARNINGDIALOGS \
  100. NS_IMETHOD ConfirmEnteringSecure(nsIInterfaceRequestor *ctx, PRBool *_retval); \
  101. NS_IMETHOD ConfirmEnteringWeak(nsIInterfaceRequestor *ctx, PRBool *_retval); \
  102. NS_IMETHOD ConfirmLeavingSecure(nsIInterfaceRequestor *ctx, PRBool *_retval); \
  103. NS_IMETHOD ConfirmMixedMode(nsIInterfaceRequestor *ctx, PRBool *_retval); \
  104. NS_IMETHOD ConfirmPostToInsecure(nsIInterfaceRequestor *ctx, PRBool *_retval); \
  105. NS_IMETHOD ConfirmPostToInsecureFromSecure(nsIInterfaceRequestor *ctx, PRBool *_retval);
  106. /* Use this macro to declare functions that forward the behavior of this interface to another object. */
  107. #define NS_FORWARD_NSISECURITYWARNINGDIALOGS(_to) \
  108. NS_IMETHOD ConfirmEnteringSecure(nsIInterfaceRequestor *ctx, PRBool *_retval) { return _to ConfirmEnteringSecure(ctx, _retval); } \
  109. NS_IMETHOD ConfirmEnteringWeak(nsIInterfaceRequestor *ctx, PRBool *_retval) { return _to ConfirmEnteringWeak(ctx, _retval); } \
  110. NS_IMETHOD ConfirmLeavingSecure(nsIInterfaceRequestor *ctx, PRBool *_retval) { return _to ConfirmLeavingSecure(ctx, _retval); } \
  111. NS_IMETHOD ConfirmMixedMode(nsIInterfaceRequestor *ctx, PRBool *_retval) { return _to ConfirmMixedMode(ctx, _retval); } \
  112. NS_IMETHOD ConfirmPostToInsecure(nsIInterfaceRequestor *ctx, PRBool *_retval) { return _to ConfirmPostToInsecure(ctx, _retval); } \
  113. NS_IMETHOD ConfirmPostToInsecureFromSecure(nsIInterfaceRequestor *ctx, PRBool *_retval) { return _to ConfirmPostToInsecureFromSecure(ctx, _retval); }
  114. /* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
  115. #define NS_FORWARD_SAFE_NSISECURITYWARNINGDIALOGS(_to) \
  116. NS_IMETHOD ConfirmEnteringSecure(nsIInterfaceRequestor *ctx, PRBool *_retval) { return !_to ? NS_ERROR_NULL_POINTER : _to->ConfirmEnteringSecure(ctx, _retval); } \
  117. NS_IMETHOD ConfirmEnteringWeak(nsIInterfaceRequestor *ctx, PRBool *_retval) { return !_to ? NS_ERROR_NULL_POINTER : _to->ConfirmEnteringWeak(ctx, _retval); } \
  118. NS_IMETHOD ConfirmLeavingSecure(nsIInterfaceRequestor *ctx, PRBool *_retval) { return !_to ? NS_ERROR_NULL_POINTER : _to->ConfirmLeavingSecure(ctx, _retval); } \
  119. NS_IMETHOD ConfirmMixedMode(nsIInterfaceRequestor *ctx, PRBool *_retval) { return !_to ? NS_ERROR_NULL_POINTER : _to->ConfirmMixedMode(ctx, _retval); } \
  120. NS_IMETHOD ConfirmPostToInsecure(nsIInterfaceRequestor *ctx, PRBool *_retval) { return !_to ? NS_ERROR_NULL_POINTER : _to->ConfirmPostToInsecure(ctx, _retval); } \
  121. NS_IMETHOD ConfirmPostToInsecureFromSecure(nsIInterfaceRequestor *ctx, PRBool *_retval) { return !_to ? NS_ERROR_NULL_POINTER : _to->ConfirmPostToInsecureFromSecure(ctx, _retval); }
  122. #if 0
  123. /* Use the code below as a template for the implementation class for this interface. */
  124. /* Header file */
  125. class nsSecurityWarningDialogs : public nsISecurityWarningDialogs
  126. {
  127. public:
  128. NS_DECL_ISUPPORTS
  129. NS_DECL_NSISECURITYWARNINGDIALOGS
  130. nsSecurityWarningDialogs();
  131. private:
  132. ~nsSecurityWarningDialogs();
  133. protected:
  134. /* additional members */
  135. };
  136. /* Implementation file */
  137. NS_IMPL_ISUPPORTS1(nsSecurityWarningDialogs, nsISecurityWarningDialogs)
  138. nsSecurityWarningDialogs::nsSecurityWarningDialogs()
  139. {
  140. /* member initializers and constructor code */
  141. }
  142. nsSecurityWarningDialogs::~nsSecurityWarningDialogs()
  143. {
  144. /* destructor code */
  145. }
  146. /* boolean confirmEnteringSecure (in nsIInterfaceRequestor ctx); */
  147. NS_IMETHODIMP nsSecurityWarningDialogs::ConfirmEnteringSecure(nsIInterfaceRequestor *ctx, PRBool *_retval)
  148. {
  149. return NS_ERROR_NOT_IMPLEMENTED;
  150. }
  151. /* boolean confirmEnteringWeak (in nsIInterfaceRequestor ctx); */
  152. NS_IMETHODIMP nsSecurityWarningDialogs::ConfirmEnteringWeak(nsIInterfaceRequestor *ctx, PRBool *_retval)
  153. {
  154. return NS_ERROR_NOT_IMPLEMENTED;
  155. }
  156. /* boolean confirmLeavingSecure (in nsIInterfaceRequestor ctx); */
  157. NS_IMETHODIMP nsSecurityWarningDialogs::ConfirmLeavingSecure(nsIInterfaceRequestor *ctx, PRBool *_retval)
  158. {
  159. return NS_ERROR_NOT_IMPLEMENTED;
  160. }
  161. /* boolean confirmMixedMode (in nsIInterfaceRequestor ctx); */
  162. NS_IMETHODIMP nsSecurityWarningDialogs::ConfirmMixedMode(nsIInterfaceRequestor *ctx, PRBool *_retval)
  163. {
  164. return NS_ERROR_NOT_IMPLEMENTED;
  165. }
  166. /* boolean confirmPostToInsecure (in nsIInterfaceRequestor ctx); */
  167. NS_IMETHODIMP nsSecurityWarningDialogs::ConfirmPostToInsecure(nsIInterfaceRequestor *ctx, PRBool *_retval)
  168. {
  169. return NS_ERROR_NOT_IMPLEMENTED;
  170. }
  171. /* boolean confirmPostToInsecureFromSecure (in nsIInterfaceRequestor ctx); */
  172. NS_IMETHODIMP nsSecurityWarningDialogs::ConfirmPostToInsecureFromSecure(nsIInterfaceRequestor *ctx, PRBool *_retval)
  173. {
  174. return NS_ERROR_NOT_IMPLEMENTED;
  175. }
  176. /* End of implementation class template. */
  177. #endif
  178. #define NS_SECURITYWARNINGDIALOGS_CONTRACTID "@mozilla.org/nsSecurityWarningDialogs;1"
  179. #endif /* __gen_nsISecurityWarningDialogs_h__ */