Diffstat (limited to 'noncore/settings/networksettings/ppp/modem.h') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/settings/networksettings/ppp/modem.h | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/noncore/settings/networksettings/ppp/modem.h b/noncore/settings/networksettings/ppp/modem.h index c23524a..052be4a 100644 --- a/noncore/settings/networksettings/ppp/modem.h +++ b/noncore/settings/networksettings/ppp/modem.h | |||
@@ -57,36 +57,51 @@ public: | |||
57 | bool dataMode() const { return data_mode; } | 57 | bool dataMode() const { return data_mode; } |
58 | void setDataMode(bool set) { data_mode = set; } | 58 | void setDataMode(bool set) { data_mode = set; } |
59 | const QString modemMessage(); | 59 | const QString modemMessage(); |
60 | speed_t modemspeed(); | 60 | speed_t modemspeed(); |
61 | static QString parseModemSpeed(const QString &); | 61 | static QString parseModemSpeed(const QString &); |
62 | void notify(const QObject *, const char *); | 62 | void notify(const QObject *, const char *); |
63 | void stop(); | 63 | void stop(); |
64 | void flush(); | 64 | void flush(); |
65 | 65 | ||
66 | int lockdevice(); | 66 | int lockdevice(); |
67 | void unlockdevice(); | 67 | void unlockdevice(); |
68 | 68 | ||
69 | bool setSecret(int,const char*,const char*); | ||
70 | bool removeSecret(int); | ||
71 | void killPPPDaemon(); | ||
72 | int pppdExitStatus(); | ||
73 | bool execPPPDaemon(const QString & arguments); | ||
74 | int openResolv(int flags); | ||
75 | bool setHostname(const QString & name); | ||
76 | |||
69 | public: | 77 | public: |
78 | enum Auth { PAP = 1, CHAP }; | ||
70 | static Modem *modem; | 79 | static Modem *modem; |
80 | int lastStatus; | ||
71 | 81 | ||
72 | signals: | 82 | signals: |
73 | void charWaiting(unsigned char); | 83 | void charWaiting(unsigned char); |
74 | 84 | ||
75 | private slots: | 85 | private slots: |
76 | void startNotifier(); | 86 | void startNotifier(); |
77 | void stopNotifier(); | 87 | void stopNotifier(); |
78 | void readtty(int); | 88 | void readtty(int); |
79 | 89 | ||
80 | private: | 90 | private: |
91 | enum { MaxPathLen = 30, MaxStrLen = 40, MaxArgs = 100 }; | ||
92 | enum { Original=0x100, New=0x200, Old=0x400 } Version; | ||
93 | |||
94 | const char* authFile(Auth method, int version = Original ); | ||
95 | bool createAuthFile(Auth method,const char *username,const char *password); | ||
81 | void escape_to_command_mode(); | 96 | void escape_to_command_mode(); |
82 | int openLockfile(QString,int); | 97 | int openLockfile(QString,int); |
83 | 98 | ||
84 | private: | 99 | private: |
85 | QString device; | 100 | QString device; |
86 | QString lockfile; | 101 | QString lockfile; |
87 | int modemfd; | 102 | int modemfd; |
88 | QSocketNotifier *sn; | 103 | QSocketNotifier *sn; |
89 | bool data_mode; | 104 | bool data_mode; |
90 | QString errmsg; | 105 | QString errmsg; |
91 | struct termios initial_tty; | 106 | struct termios initial_tty; |
92 | struct termios tty; | 107 | struct termios tty; |