1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
|
Controlling KVpnc using DCOP
========================
DCOP use is simple:
dcop kvpnc-<pid> KVpncInterface <command>
The PID (process identifier number) can be obtained by:
ps ax | grep kvpnc | grep -v grep
The first number in line is the PID.
Hint: You can use kdcop for browsing the applications which can be controlled and their functions.
KVpnc provides the following functions:
--------------------------------------------------
QCStringList interfaces()
QCStringList functions()
TQString getVersion()
void doConnect()
void doDisconnect()
uint getConnectedTime()
TQString getStatus()
TQString getCurrentProfile()
void setProfile(TQString profilename)
void createNewProfile()
void createNewProfileWithWizard()
void deleteCurrentProfile()
void openPreferences()
void doImportCert()
void doImportPcf()
void doImportPcf(TQString file)
void doImportOpenvpnConfig()
void doImportOpenvpnConfig(TQString file)
QStringList profiles()
QStringList toolinfo()
void doQuit()
void doGenerateOpenvpnKey()
void doSendFeedbackMail()
QStringList getProfileTypes()
Return and parameter data types:
------------------------------------------
TQString text (TQString format)
QStringList string list - list of text (TQString format)
QCStringList string list - list of text (C format)
uint unsigned int - number
void empty - no return value
Examples:
-------------
1. List all profile names
root@linux# dcop kvpnc-3957 KVpncInterface profiles
profile1
profile2
profile3
2. Get information about tools
root@linux# dcop kvpnc-3957 KVpncInterface toolinfo
vpnc,Found,0.3.3,full,
gnome-ssh-askpass,Found,No info,full,
ksshaskpass,Found,0.4.1,full,
ssh,Found,5.1p1,full,
tail,Found,6.10,full,
cisco_cert_mgr,Found,4.8.01 (0640),full,
vtund,Not found,No info,none,
bash,Found,No info,full,
pkcs11-tool,Found,No info,full,
route,Found,1.98,full,
ifconfig,Found,1.42,full,
ip,Found,iproute2-ss080725,full,
ping,Found,iputils-sss20071127,full,
killall,Found,22.6,full,
kill,Found,3.2.7,full,
openvpn,Found,2.1_rc11,full,
openssl,Found,0.9.8g,full,
iptables,Found,v1.4.1.1,full,
setkey,Found,0.7.1,full,
openl2tpd,Found,No info,full,
xl2tpd,Found,xl2tpd-1.2.0,full,
l2tpd,Not found,No info,none,
pptp,Found,1.7.2,full,
pppd,Found,2.4.4,full,
ipsec,Found,strongSwan U4.2.4,full,
racoonctl,Found,No info,full,
vpnclient,Found,4.8.01 (0640),full,
3. change current profile to hs_harz
dcop kvpnc-3957 KVpncInterface setProfile 'hs_harz'
|