aboutsummaryrefslogtreecommitdiffstats
path: root/Source/SPSSHTunnel.h
diff options
context:
space:
mode:
authorstuconnolly <stuart02@gmail.com>2011-02-08 21:02:48 +0000
committerstuconnolly <stuart02@gmail.com>2011-02-08 21:02:48 +0000
commitf5a99e49839174bdfa2364fbba1c963da4a3481b (patch)
treef882f789e74db49e800775f366d0bf1dcce56385 /Source/SPSSHTunnel.h
parentfd4305711129a5b6a5ff4571f2b39295bcddf831 (diff)
downloadsequelpro-f5a99e49839174bdfa2364fbba1c963da4a3481b.tar.gz
sequelpro-f5a99e49839174bdfa2364fbba1c963da4a3481b.tar.bz2
sequelpro-f5a99e49839174bdfa2364fbba1c963da4a3481b.zip
When the user cancels the SSH password prompt, prevent further prompts and also suppress the error detail dialog. Fixes issue #975.
Diffstat (limited to 'Source/SPSSHTunnel.h')
-rw-r--r--Source/SPSSHTunnel.h72
1 files changed, 39 insertions, 33 deletions
diff --git a/Source/SPSSHTunnel.h b/Source/SPSSHTunnel.h
index 067cf42a..4afec738 100644
--- a/Source/SPSSHTunnel.h
+++ b/Source/SPSSHTunnel.h
@@ -27,18 +27,11 @@
@interface SPSSHTunnel : NSObject <MCPConnectionProxy>
{
- IBOutlet NSWindow *sshQuestionDialog;
- IBOutlet NSTextField *sshQuestionText;
- IBOutlet NSButton *sshPasswordKeychainCheckbox;
- IBOutlet NSWindow *sshPasswordDialog;
- IBOutlet NSTextField *sshPasswordText;
- IBOutlet NSSecureTextField *sshPasswordField;
+ id delegate;
NSWindow *parentWindow;
NSTask *task;
NSPipe *standardError;
- id delegate;
- SEL stateChangeSelector;
NSConnection *tunnelConnection;
NSString *lastError;
NSString *tunnelConnectionName;
@@ -53,9 +46,6 @@
NSString *identityFilePath;
NSMutableArray *debugMessages;
NSLock *debugMessagesLock;
- BOOL useHostFallback;
- BOOL requestedResponse;
- BOOL passwordInKeychain;
NSInteger sshPort;
NSInteger remotePort;
NSInteger localPort;
@@ -64,29 +54,45 @@
NSLock *answerAvailableLock;
NSString *currentKeyName;
+
+ SEL stateChangeSelector;
+
+ BOOL useHostFallback;
+ BOOL requestedResponse;
+ BOOL passwordInKeychain;
+ BOOL passwordPromptCancelled;
+
+ IBOutlet NSWindow *sshQuestionDialog;
+ IBOutlet NSTextField *sshQuestionText;
+ IBOutlet NSButton *sshPasswordKeychainCheckbox;
+ IBOutlet NSWindow *sshPasswordDialog;
+ IBOutlet NSTextField *sshPasswordText;
+ IBOutlet NSSecureTextField *sshPasswordField;
}
-- (id) initToHost:(NSString *) theHost port:(NSInteger) thePort login:(NSString *) theLogin tunnellingToPort:(NSInteger) targetPort onHost:(NSString *) targetHost;
-- (BOOL) setConnectionStateChangeSelector:(SEL)theStateChangeSelector delegate:(id)theDelegate;
-- (void) setParentWindow:(NSWindow *)theWindow;
-- (BOOL) setPasswordKeychainName:(NSString *)theName account:(NSString *)theAccount;
-- (BOOL) setPassword:(NSString *)thePassword;
-- (BOOL) setKeyFilePath:(NSString *)thePath;
-- (NSInteger) state;
-- (NSString *) lastError;
-- (NSString *) debugMessages;
-- (NSInteger) localPort;
-- (NSInteger) localPortFallback;
-- (void) connect;
-- (void) launchTask:(id) dummy;
-- (void) disconnect;
-- (void) standardErrorHandler:(NSNotification*)aNotification;
-- (NSString *) getPasswordWithVerificationHash:(NSString *)theHash;
-- (BOOL) getResponseForQuestion:(NSString *)theQuestion;
-- (void) workerGetResponseForQuestion:(NSString *)theQuestion;
-- (NSString *) getPasswordForQuery:(NSString *)theQuery verificationHash:(NSString *)theHash;
-- (void) workerGetPasswordForQuery:(NSString *)theQuery;
-- (IBAction) closeSSHQuestionSheet:(id)sender;
-- (IBAction) closeSSHPasswordSheet:(id)sender;
+@property (readonly) BOOL passwordPromptCancelled;
+
+- (id)initToHost:(NSString *)theHost port:(NSInteger)thePort login:(NSString *)theLogin tunnellingToPort:(NSInteger)targetPort onHost:(NSString *)targetHost;
+- (BOOL)setConnectionStateChangeSelector:(SEL)theStateChangeSelector delegate:(id)theDelegate;
+- (void)setParentWindow:(NSWindow *)theWindow;
+- (BOOL)setPasswordKeychainName:(NSString *)theName account:(NSString *)theAccount;
+- (BOOL)setPassword:(NSString *)thePassword;
+- (BOOL)setKeyFilePath:(NSString *)thePath;
+- (NSInteger)state;
+- (NSString *)lastError;
+- (NSString *)debugMessages;
+- (NSInteger)localPort;
+- (NSInteger)localPortFallback;
+- (void)connect;
+- (void)launchTask:(id)dummy;
+- (void)disconnect;
+- (void)standardErrorHandler:(NSNotification*)aNotification;
+- (NSString *)getPasswordWithVerificationHash:(NSString *)theHash;
+- (BOOL)getResponseForQuestion:(NSString *)theQuestion;
+- (void)workerGetResponseForQuestion:(NSString *)theQuestion;
+- (NSString *)getPasswordForQuery:(NSString *)theQuery verificationHash:(NSString *)theHash;
+- (void)workerGetPasswordForQuery:(NSString *)theQuery;
+- (IBAction)closeSSHQuestionSheet:(id)sender;
+- (IBAction)closeSSHPasswordSheet:(id)sender;
@end