├── .gitignore
├── .idea
├── goproxy-gui.iml
├── misc.xml
├── modules.xml
└── vcs.xml
├── AddMappingForm.go
├── AddMappingFormImpl.go
├── LICENSE
├── Lazarus
├── AddMappingForm.gfm
├── AddMappingForm.go
├── AddMappingFormImpl.go
├── MainForm.gfm
├── MainForm.go
├── MainFormImpl.go
├── NewProxyServerForm.gfm
├── NewProxyServerForm.go
├── NewProxyServerFormImpl.go
├── SettingForm.go
├── SettingFormImpl.go
├── backup
│ ├── project1.lpi
│ ├── project1.lpr
│ ├── project1.lps
│ ├── unit1.lfm
│ ├── unit1.pas
│ ├── unit2.lfm
│ ├── unit2.pas
│ ├── unit3.lfm
│ └── unit3.pas
├── defaultRes_windows.syso
├── icon
│ ├── cloud_computing_128px_1217935_easyicon.net.ico
│ ├── help_128px_1117612_easyicon.net.ico
│ ├── main.ico
│ ├── rocket_128px_1231680_easyicon.net.ico
│ ├── rocket_625px_1231680_easyicon.net.png
│ ├── server_128px_1217869_easyicon.net.ico
│ └── settings_128px_1217844_easyicon.net.ico
├── lib
│ └── x86_64-win64
│ │ ├── project1.compiled
│ │ ├── project1.o
│ │ ├── project1.obj
│ │ ├── project1.res
│ │ ├── unit1.lfm
│ │ ├── unit1.o
│ │ ├── unit1.ppu
│ │ ├── unit2.lfm
│ │ ├── unit2.o
│ │ ├── unit2.ppu
│ │ ├── unit3.lfm
│ │ ├── unit3.o
│ │ └── unit3.ppu
├── main.go
├── project1.lpi
├── project1.lpr
├── project1.lps
├── project1.res
├── unit1.lfm
├── unit1.pas
├── unit2.lfm
├── unit2.pas
├── unit3.lfm
├── unit3.pas
└── util.go
├── MainForm.go
├── MainFormImpl.go
├── NewProxyServerForm.go
├── NewProxyServerFormImpl.go
├── README.md
├── SettingForm.go
├── SettingFormImpl.go
├── _v_images
├── 20181205123101138_30945.png
├── 20181205123142504_31841.png
├── 20181205123154027_31227.png
└── 20181205123203611_16017.png
├── goproxy.db
├── govcl.syso
├── main.go
├── syso
├── build.bat
├── govcl.rc
└── main.manifest
└── util.go
/.gitignore:
--------------------------------------------------------------------------------
1 | # Binaries for programs and plugins
2 | *.exe
3 | *.exe~
4 | *.dll
5 | *.so
6 | *.dylib
7 | .idea
8 |
9 | # Test binary, build with `go test -c`
10 | *.test
11 |
12 | # Output of the go coverage tool, specifically when used with LiteIDE
13 | *.out
14 |
--------------------------------------------------------------------------------
/.idea/goproxy-gui.iml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/.idea/misc.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/.idea/modules.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/.idea/vcs.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/AddMappingForm.go:
--------------------------------------------------------------------------------
1 | // 由res2go自动生成,不要编辑。
2 | package main
3 |
4 | import (
5 | "github.com/ying32/govcl/vcl"
6 | )
7 |
8 | type TAddMappingForm struct {
9 | *vcl.TForm
10 | Label1 *vcl.TLabel
11 | TypeComboBox *vcl.TComboBox
12 | Label2 *vcl.TLabel
13 | LocalPort *vcl.TEdit
14 | Label3 *vcl.TLabel
15 | RemotePort *vcl.TEdit
16 | ConfirmBtn *vcl.TButton
17 | CancelBtn *vcl.TButton
18 |
19 | //::private::
20 | TAddMappingFormFields
21 | }
22 |
23 | var AddMappingForm *TAddMappingForm
24 |
25 |
26 |
27 |
28 | // 以字节形式加载
29 | // vcl.Application.CreateForm(addMappingFormBytes, &AddMappingForm)
30 |
31 | var addMappingFormBytes = []byte("\x54\x50\x46\x30\x0F\x54\x41\x64\x64\x4D\x61\x70\x70\x69\x6E\x67\x46\x6F\x72\x6D\x0E\x41\x64\x64\x4D\x61\x70\x70\x69\x6E\x67\x46\x6F\x72\x6D\x04\x4C\x65\x66\x74\x03\xEE\x02\x06\x48\x65\x69\x67\x68\x74\x03\xDA\x00\x03\x54\x6F\x70\x03\x75\x01\x05\x57\x69\x64\x74\x68\x03\x70\x01\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x12\xE6\x96\xB0\xE5\xA2\x9E\xE7\xA9\xBF\xE9\x80\x8F\xE6\x98\xA0\xE5\xB0\x84\x0C\x43\x6C\x69\x65\x6E\x74\x48\x65\x69\x67\x68\x74\x03\xDA\x00\x0B\x43\x6C\x69\x65\x6E\x74\x57\x69\x64\x74\x68\x03\x70\x01\x0D\x44\x65\x73\x69\x67\x6E\x54\x69\x6D\x65\x50\x50\x49\x02\x78\x0A\x4C\x43\x4C\x56\x65\x72\x73\x69\x6F\x6E\x06\x07\x32\x2E\x30\x2E\x32\x2E\x30\x00\x06\x54\x4C\x61\x62\x65\x6C\x06\x4C\x61\x62\x65\x6C\x31\x04\x4C\x65\x66\x74\x02\x50\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x20\x05\x57\x69\x64\x74\x68\x02\x1E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE7\xB1\xBB\xE5\x9E\x8B\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x09\x54\x43\x6F\x6D\x62\x6F\x42\x6F\x78\x0C\x54\x79\x70\x65\x43\x6F\x6D\x62\x6F\x42\x6F\x78\x04\x4C\x65\x66\x74\x03\xA0\x00\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x18\x05\x57\x69\x64\x74\x68\x02\x7D\x0A\x49\x74\x65\x6D\x48\x65\x69\x67\x68\x74\x02\x14\x09\x49\x74\x65\x6D\x49\x6E\x64\x65\x78\x02\x00\x0D\x49\x74\x65\x6D\x73\x2E\x53\x74\x72\x69\x6E\x67\x73\x01\x06\x03\x74\x63\x70\x06\x03\x75\x64\x70\x00\x08\x4F\x6E\x43\x68\x61\x6E\x67\x65\x07\x12\x54\x79\x70\x65\x43\x6F\x6D\x62\x6F\x42\x6F\x78\x43\x68\x61\x6E\x67\x65\x05\x53\x74\x79\x6C\x65\x07\x0E\x63\x73\x44\x72\x6F\x70\x44\x6F\x77\x6E\x4C\x69\x73\x74\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x00\x04\x54\x65\x78\x74\x06\x03\x74\x63\x70\x00\x00\x06\x54\x4C\x61\x62\x65\x6C\x06\x4C\x61\x62\x65\x6C\x32\x04\x4C\x65\x66\x74\x02\x40\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x48\x05\x57\x69\x64\x74\x68\x02\x3C\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x0C\xE6\x9C\xAC\xE5\x9C\xB0\xE7\xAB\xAF\xE5\x8F\xA3\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x05\x54\x45\x64\x69\x74\x09\x4C\x6F\x63\x61\x6C\x50\x6F\x72\x74\x04\x4C\x65\x66\x74\x03\xA0\x00\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x40\x05\x57\x69\x64\x74\x68\x02\x7D\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x01\x00\x00\x06\x54\x4C\x61\x62\x65\x6C\x06\x4C\x61\x62\x65\x6C\x33\x04\x4C\x65\x66\x74\x02\x40\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x78\x05\x57\x69\x64\x74\x68\x02\x3C\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x0C\xE8\xBF\x9C\xE7\xA8\x8B\xE7\xAB\xAF\xE5\x8F\xA3\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x05\x54\x45\x64\x69\x74\x0A\x52\x65\x6D\x6F\x74\x65\x50\x6F\x72\x74\x04\x4C\x65\x66\x74\x03\xA0\x00\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x70\x05\x57\x69\x64\x74\x68\x02\x7D\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x02\x00\x00\x07\x54\x42\x75\x74\x74\x6F\x6E\x0A\x43\x6F\x6E\x66\x69\x72\x6D\x42\x74\x6E\x04\x4C\x65\x66\x74\x02\x38\x06\x48\x65\x69\x67\x68\x74\x02\x1F\x03\x54\x6F\x70\x03\xA8\x00\x05\x57\x69\x64\x74\x68\x02\x5E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE7\xA1\xAE\xE5\xAE\x9A\x07\x4F\x6E\x43\x6C\x69\x63\x6B\x07\x0F\x43\x6F\x6E\x66\x69\x72\x6D\x42\x74\x6E\x43\x6C\x69\x63\x6B\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x03\x00\x00\x07\x54\x42\x75\x74\x74\x6F\x6E\x09\x43\x61\x6E\x63\x65\x6C\x42\x74\x6E\x04\x4C\x65\x66\x74\x03\xBF\x00\x06\x48\x65\x69\x67\x68\x74\x02\x1F\x03\x54\x6F\x70\x03\xA8\x00\x05\x57\x69\x64\x74\x68\x02\x5E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE5\x8F\x96\xE6\xB6\x88\x07\x4F\x6E\x43\x6C\x69\x63\x6B\x07\x0E\x43\x61\x6E\x63\x65\x6C\x42\x74\x6E\x43\x6C\x69\x63\x6B\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x04\x00\x00\x00")
32 |
--------------------------------------------------------------------------------
/AddMappingFormImpl.go:
--------------------------------------------------------------------------------
1 | // 由res2go自动生成。
2 | // 在这里写你的事件。
3 |
4 | package main
5 |
6 | import (
7 | "github.com/ying32/govcl/vcl"
8 | )
9 |
10 | //::private::
11 | type TAddMappingFormFields struct {
12 | }
13 |
14 |
15 | func (f *TAddMappingForm) OnTypeComboBoxChange(sender vcl.IObject) {
16 |
17 | }
18 |
19 |
20 | func (f *TAddMappingForm) OnConfirmBtnClick(sender vcl.IObject) {
21 | //NewProxyServerForm.ListView1.
22 | }
23 |
24 |
25 | func (f *TAddMappingForm) OnCancelBtnClick(sender vcl.IObject) {
26 |
27 | }
28 |
29 |
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
1 | Apache License
2 | Version 2.0, January 2004
3 | http://www.apache.org/licenses/
4 |
5 | TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
6 |
7 | 1. Definitions.
8 |
9 | "License" shall mean the terms and conditions for use, reproduction,
10 | and distribution as defined by Sections 1 through 9 of this document.
11 |
12 | "Licensor" shall mean the copyright owner or entity authorized by
13 | the copyright owner that is granting the License.
14 |
15 | "Legal Entity" shall mean the union of the acting entity and all
16 | other entities that control, are controlled by, or are under common
17 | control with that entity. For the purposes of this definition,
18 | "control" means (i) the power, direct or indirect, to cause the
19 | direction or management of such entity, whether by contract or
20 | otherwise, or (ii) ownership of fifty percent (50%) or more of the
21 | outstanding shares, or (iii) beneficial ownership of such entity.
22 |
23 | "You" (or "Your") shall mean an individual or Legal Entity
24 | exercising permissions granted by this License.
25 |
26 | "Source" form shall mean the preferred form for making modifications,
27 | including but not limited to software source code, documentation
28 | source, and configuration files.
29 |
30 | "Object" form shall mean any form resulting from mechanical
31 | transformation or translation of a Source form, including but
32 | not limited to compiled object code, generated documentation,
33 | and conversions to other media types.
34 |
35 | "Work" shall mean the work of authorship, whether in Source or
36 | Object form, made available under the License, as indicated by a
37 | copyright notice that is included in or attached to the work
38 | (an example is provided in the Appendix below).
39 |
40 | "Derivative Works" shall mean any work, whether in Source or Object
41 | form, that is based on (or derived from) the Work and for which the
42 | editorial revisions, annotations, elaborations, or other modifications
43 | represent, as a whole, an original work of authorship. For the purposes
44 | of this License, Derivative Works shall not include works that remain
45 | separable from, or merely link (or bind by name) to the interfaces of,
46 | the Work and Derivative Works thereof.
47 |
48 | "Contribution" shall mean any work of authorship, including
49 | the original version of the Work and any modifications or additions
50 | to that Work or Derivative Works thereof, that is intentionally
51 | submitted to Licensor for inclusion in the Work by the copyright owner
52 | or by an individual or Legal Entity authorized to submit on behalf of
53 | the copyright owner. For the purposes of this definition, "submitted"
54 | means any form of electronic, verbal, or written communication sent
55 | to the Licensor or its representatives, including but not limited to
56 | communication on electronic mailing lists, source code control systems,
57 | and issue tracking systems that are managed by, or on behalf of, the
58 | Licensor for the purpose of discussing and improving the Work, but
59 | excluding communication that is conspicuously marked or otherwise
60 | designated in writing by the copyright owner as "Not a Contribution."
61 |
62 | "Contributor" shall mean Licensor and any individual or Legal Entity
63 | on behalf of whom a Contribution has been received by Licensor and
64 | subsequently incorporated within the Work.
65 |
66 | 2. Grant of Copyright License. Subject to the terms and conditions of
67 | this License, each Contributor hereby grants to You a perpetual,
68 | worldwide, non-exclusive, no-charge, royalty-free, irrevocable
69 | copyright license to reproduce, prepare Derivative Works of,
70 | publicly display, publicly perform, sublicense, and distribute the
71 | Work and such Derivative Works in Source or Object form.
72 |
73 | 3. Grant of Patent License. Subject to the terms and conditions of
74 | this License, each Contributor hereby grants to You a perpetual,
75 | worldwide, non-exclusive, no-charge, royalty-free, irrevocable
76 | (except as stated in this section) patent license to make, have made,
77 | use, offer to sell, sell, import, and otherwise transfer the Work,
78 | where such license applies only to those patent claims licensable
79 | by such Contributor that are necessarily infringed by their
80 | Contribution(s) alone or by combination of their Contribution(s)
81 | with the Work to which such Contribution(s) was submitted. If You
82 | institute patent litigation against any entity (including a
83 | cross-claim or counterclaim in a lawsuit) alleging that the Work
84 | or a Contribution incorporated within the Work constitutes direct
85 | or contributory patent infringement, then any patent licenses
86 | granted to You under this License for that Work shall terminate
87 | as of the date such litigation is filed.
88 |
89 | 4. Redistribution. You may reproduce and distribute copies of the
90 | Work or Derivative Works thereof in any medium, with or without
91 | modifications, and in Source or Object form, provided that You
92 | meet the following conditions:
93 |
94 | (a) You must give any other recipients of the Work or
95 | Derivative Works a copy of this License; and
96 |
97 | (b) You must cause any modified files to carry prominent notices
98 | stating that You changed the files; and
99 |
100 | (c) You must retain, in the Source form of any Derivative Works
101 | that You distribute, all copyright, patent, trademark, and
102 | attribution notices from the Source form of the Work,
103 | excluding those notices that do not pertain to any part of
104 | the Derivative Works; and
105 |
106 | (d) If the Work includes a "NOTICE" text file as part of its
107 | distribution, then any Derivative Works that You distribute must
108 | include a readable copy of the attribution notices contained
109 | within such NOTICE file, excluding those notices that do not
110 | pertain to any part of the Derivative Works, in at least one
111 | of the following places: within a NOTICE text file distributed
112 | as part of the Derivative Works; within the Source form or
113 | documentation, if provided along with the Derivative Works; or,
114 | within a display generated by the Derivative Works, if and
115 | wherever such third-party notices normally appear. The contents
116 | of the NOTICE file are for informational purposes only and
117 | do not modify the License. You may add Your own attribution
118 | notices within Derivative Works that You distribute, alongside
119 | or as an addendum to the NOTICE text from the Work, provided
120 | that such additional attribution notices cannot be construed
121 | as modifying the License.
122 |
123 | You may add Your own copyright statement to Your modifications and
124 | may provide additional or different license terms and conditions
125 | for use, reproduction, or distribution of Your modifications, or
126 | for any such Derivative Works as a whole, provided Your use,
127 | reproduction, and distribution of the Work otherwise complies with
128 | the conditions stated in this License.
129 |
130 | 5. Submission of Contributions. Unless You explicitly state otherwise,
131 | any Contribution intentionally submitted for inclusion in the Work
132 | by You to the Licensor shall be under the terms and conditions of
133 | this License, without any additional terms or conditions.
134 | Notwithstanding the above, nothing herein shall supersede or modify
135 | the terms of any separate license agreement you may have executed
136 | with Licensor regarding such Contributions.
137 |
138 | 6. Trademarks. This License does not grant permission to use the trade
139 | names, trademarks, service marks, or product names of the Licensor,
140 | except as required for reasonable and customary use in describing the
141 | origin of the Work and reproducing the content of the NOTICE file.
142 |
143 | 7. Disclaimer of Warranty. Unless required by applicable law or
144 | agreed to in writing, Licensor provides the Work (and each
145 | Contributor provides its Contributions) on an "AS IS" BASIS,
146 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
147 | implied, including, without limitation, any warranties or conditions
148 | of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
149 | PARTICULAR PURPOSE. You are solely responsible for determining the
150 | appropriateness of using or redistributing the Work and assume any
151 | risks associated with Your exercise of permissions under this License.
152 |
153 | 8. Limitation of Liability. In no event and under no legal theory,
154 | whether in tort (including negligence), contract, or otherwise,
155 | unless required by applicable law (such as deliberate and grossly
156 | negligent acts) or agreed to in writing, shall any Contributor be
157 | liable to You for damages, including any direct, indirect, special,
158 | incidental, or consequential damages of any character arising as a
159 | result of this License or out of the use or inability to use the
160 | Work (including but not limited to damages for loss of goodwill,
161 | work stoppage, computer failure or malfunction, or any and all
162 | other commercial damages or losses), even if such Contributor
163 | has been advised of the possibility of such damages.
164 |
165 | 9. Accepting Warranty or Additional Liability. While redistributing
166 | the Work or Derivative Works thereof, You may choose to offer,
167 | and charge a fee for, acceptance of support, warranty, indemnity,
168 | or other liability obligations and/or rights consistent with this
169 | License. However, in accepting such obligations, You may act only
170 | on Your own behalf and on Your sole responsibility, not on behalf
171 | of any other Contributor, and only if You agree to indemnify,
172 | defend, and hold each Contributor harmless for any liability
173 | incurred by, or claims asserted against, such Contributor by reason
174 | of your accepting any such warranty or additional liability.
175 |
176 | END OF TERMS AND CONDITIONS
177 |
178 | APPENDIX: How to apply the Apache License to your work.
179 |
180 | To apply the Apache License to your work, attach the following
181 | boilerplate notice, with the fields enclosed by brackets "[]"
182 | replaced with your own identifying information. (Don't include
183 | the brackets!) The text should be enclosed in the appropriate
184 | comment syntax for the file format. We also recommend that a
185 | file or class name and description of purpose be included on the
186 | same "printed page" as the copyright notice for easier
187 | identification within third-party archives.
188 |
189 | Copyright [yyyy] [name of copyright owner]
190 |
191 | Licensed under the Apache License, Version 2.0 (the "License");
192 | you may not use this file except in compliance with the License.
193 | You may obtain a copy of the License at
194 |
195 | http://www.apache.org/licenses/LICENSE-2.0
196 |
197 | Unless required by applicable law or agreed to in writing, software
198 | distributed under the License is distributed on an "AS IS" BASIS,
199 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
200 | See the License for the specific language governing permissions and
201 | limitations under the License.
202 |
--------------------------------------------------------------------------------
/Lazarus/AddMappingForm.gfm:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yangjinhe/goproxy-gui/b39c69d72aafc54d28a6930c6f7c1b5d56169e8e/Lazarus/AddMappingForm.gfm
--------------------------------------------------------------------------------
/Lazarus/AddMappingForm.go:
--------------------------------------------------------------------------------
1 | // 由res2go自动生成,不要编辑。
2 | package main
3 |
4 | import (
5 | "github.com/ying32/govcl/vcl"
6 | )
7 |
8 | type TAddMappingForm struct {
9 | *vcl.TForm
10 | Label1 *vcl.TLabel
11 | TypeComboBox *vcl.TComboBox
12 | Label2 *vcl.TLabel
13 | LocalPort *vcl.TEdit
14 | Label3 *vcl.TLabel
15 | RemotePort *vcl.TEdit
16 | ConfirmBtn *vcl.TButton
17 | CancelBtn *vcl.TButton
18 |
19 | //::private::
20 | TAddMappingFormFields
21 | }
22 |
23 | var AddMappingForm *TAddMappingForm
24 |
25 |
26 |
27 |
28 | // 以字节形式加载
29 | // vcl.Application.CreateForm(addMappingFormBytes, &AddMappingForm)
30 |
31 | var addMappingFormBytes = []byte("\x54\x50\x46\x30\x0F\x54\x41\x64\x64\x4D\x61\x70\x70\x69\x6E\x67\x46\x6F\x72\x6D\x0E\x41\x64\x64\x4D\x61\x70\x70\x69\x6E\x67\x46\x6F\x72\x6D\x04\x4C\x65\x66\x74\x03\xEE\x02\x06\x48\x65\x69\x67\x68\x74\x03\xDA\x00\x03\x54\x6F\x70\x03\x75\x01\x05\x57\x69\x64\x74\x68\x03\x70\x01\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x12\xE6\x96\xB0\xE5\xA2\x9E\xE7\xA9\xBF\xE9\x80\x8F\xE6\x98\xA0\xE5\xB0\x84\x0C\x43\x6C\x69\x65\x6E\x74\x48\x65\x69\x67\x68\x74\x03\xDA\x00\x0B\x43\x6C\x69\x65\x6E\x74\x57\x69\x64\x74\x68\x03\x70\x01\x0D\x44\x65\x73\x69\x67\x6E\x54\x69\x6D\x65\x50\x50\x49\x02\x78\x0A\x4C\x43\x4C\x56\x65\x72\x73\x69\x6F\x6E\x06\x07\x32\x2E\x30\x2E\x32\x2E\x30\x00\x06\x54\x4C\x61\x62\x65\x6C\x06\x4C\x61\x62\x65\x6C\x31\x04\x4C\x65\x66\x74\x02\x50\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x20\x05\x57\x69\x64\x74\x68\x02\x1E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE7\xB1\xBB\xE5\x9E\x8B\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x09\x54\x43\x6F\x6D\x62\x6F\x42\x6F\x78\x0C\x54\x79\x70\x65\x43\x6F\x6D\x62\x6F\x42\x6F\x78\x04\x4C\x65\x66\x74\x03\xA0\x00\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x18\x05\x57\x69\x64\x74\x68\x02\x7D\x0A\x49\x74\x65\x6D\x48\x65\x69\x67\x68\x74\x02\x14\x09\x49\x74\x65\x6D\x49\x6E\x64\x65\x78\x02\x00\x0D\x49\x74\x65\x6D\x73\x2E\x53\x74\x72\x69\x6E\x67\x73\x01\x06\x03\x74\x63\x70\x06\x03\x75\x64\x70\x00\x08\x4F\x6E\x43\x68\x61\x6E\x67\x65\x07\x12\x54\x79\x70\x65\x43\x6F\x6D\x62\x6F\x42\x6F\x78\x43\x68\x61\x6E\x67\x65\x05\x53\x74\x79\x6C\x65\x07\x0E\x63\x73\x44\x72\x6F\x70\x44\x6F\x77\x6E\x4C\x69\x73\x74\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x00\x04\x54\x65\x78\x74\x06\x03\x74\x63\x70\x00\x00\x06\x54\x4C\x61\x62\x65\x6C\x06\x4C\x61\x62\x65\x6C\x32\x04\x4C\x65\x66\x74\x02\x40\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x48\x05\x57\x69\x64\x74\x68\x02\x3C\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x0C\xE6\x9C\xAC\xE5\x9C\xB0\xE7\xAB\xAF\xE5\x8F\xA3\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x05\x54\x45\x64\x69\x74\x09\x4C\x6F\x63\x61\x6C\x50\x6F\x72\x74\x04\x4C\x65\x66\x74\x03\xA0\x00\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x40\x05\x57\x69\x64\x74\x68\x02\x7D\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x01\x00\x00\x06\x54\x4C\x61\x62\x65\x6C\x06\x4C\x61\x62\x65\x6C\x33\x04\x4C\x65\x66\x74\x02\x40\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x78\x05\x57\x69\x64\x74\x68\x02\x3C\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x0C\xE8\xBF\x9C\xE7\xA8\x8B\xE7\xAB\xAF\xE5\x8F\xA3\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x05\x54\x45\x64\x69\x74\x0A\x52\x65\x6D\x6F\x74\x65\x50\x6F\x72\x74\x04\x4C\x65\x66\x74\x03\xA0\x00\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x70\x05\x57\x69\x64\x74\x68\x02\x7D\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x02\x00\x00\x07\x54\x42\x75\x74\x74\x6F\x6E\x0A\x43\x6F\x6E\x66\x69\x72\x6D\x42\x74\x6E\x04\x4C\x65\x66\x74\x02\x38\x06\x48\x65\x69\x67\x68\x74\x02\x1F\x03\x54\x6F\x70\x03\xA8\x00\x05\x57\x69\x64\x74\x68\x02\x5E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE7\xA1\xAE\xE5\xAE\x9A\x07\x4F\x6E\x43\x6C\x69\x63\x6B\x07\x0F\x43\x6F\x6E\x66\x69\x72\x6D\x42\x74\x6E\x43\x6C\x69\x63\x6B\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x03\x00\x00\x07\x54\x42\x75\x74\x74\x6F\x6E\x09\x43\x61\x6E\x63\x65\x6C\x42\x74\x6E\x04\x4C\x65\x66\x74\x03\xBF\x00\x06\x48\x65\x69\x67\x68\x74\x02\x1F\x03\x54\x6F\x70\x03\xA8\x00\x05\x57\x69\x64\x74\x68\x02\x5E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE5\x8F\x96\xE6\xB6\x88\x07\x4F\x6E\x43\x6C\x69\x63\x6B\x07\x0E\x43\x61\x6E\x63\x65\x6C\x42\x74\x6E\x43\x6C\x69\x63\x6B\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x04\x00\x00\x00")
32 |
--------------------------------------------------------------------------------
/Lazarus/AddMappingFormImpl.go:
--------------------------------------------------------------------------------
1 | // 由res2go自动生成。
2 | // 在这里写你的事件。
3 |
4 | package main
5 |
6 | import (
7 | "github.com/ying32/govcl/vcl"
8 | )
9 |
10 | //::private::
11 | type TAddMappingFormFields struct {
12 | }
13 |
14 |
15 | func (f *TAddMappingForm) OnTypeComboBoxChange(sender vcl.IObject) {
16 |
17 | }
18 |
19 |
20 | func (f *TAddMappingForm) OnConfirmBtnClick(sender vcl.IObject) {
21 | //NewProxyServerForm.ListView1.
22 | }
23 |
24 |
25 | func (f *TAddMappingForm) OnCancelBtnClick(sender vcl.IObject) {
26 |
27 | }
28 |
29 |
--------------------------------------------------------------------------------
/Lazarus/MainForm.gfm:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yangjinhe/goproxy-gui/b39c69d72aafc54d28a6930c6f7c1b5d56169e8e/Lazarus/MainForm.gfm
--------------------------------------------------------------------------------
/Lazarus/MainFormImpl.go:
--------------------------------------------------------------------------------
1 | // 由res2go自动生成。
2 | // 在这里写你的事件。
3 |
4 | package main
5 |
6 | import (
7 | "github.com/ying32/govcl/vcl"
8 | )
9 |
10 | //::private::
11 | type TMainFormFields struct {
12 | }
13 |
14 |
15 | func (f *TMainForm) OnSettingsBtnClick(sender vcl.IObject) {
16 |
17 | }
18 |
19 |
20 | func (f *TMainForm) OnUpdateBtnClick(sender vcl.IObject) {
21 |
22 | }
23 |
24 |
25 | func (f *TMainForm) OnHelpBtnClick(sender vcl.IObject) {
26 |
27 | }
28 |
29 |
30 | func (f *TMainForm) OnAddServerClick(sender vcl.IObject) {
31 | NewProxyServerForm.ShowModal()
32 | }
33 |
34 |
35 | func (f *TMainForm) OnSetActivityServerClick(sender vcl.IObject) {
36 |
37 | }
38 |
39 |
40 | func (f *TMainForm) OnPingServerClick(sender vcl.IObject) {
41 |
42 | }
43 |
44 |
45 | func (f *TMainForm) OnShowMainWindowClick(sender vcl.IObject) {
46 |
47 | }
48 |
49 |
50 | func (f *TMainForm) OnExitMainWindowClick(sender vcl.IObject) {
51 |
52 | }
53 |
54 |
--------------------------------------------------------------------------------
/Lazarus/NewProxyServerForm.gfm:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yangjinhe/goproxy-gui/b39c69d72aafc54d28a6930c6f7c1b5d56169e8e/Lazarus/NewProxyServerForm.gfm
--------------------------------------------------------------------------------
/Lazarus/NewProxyServerForm.go:
--------------------------------------------------------------------------------
1 | // 由res2go自动生成,不要编辑。
2 | package main
3 |
4 | import (
5 | "github.com/ying32/govcl/vcl"
6 | )
7 |
8 | type TNewProxyServerForm struct {
9 | *vcl.TForm
10 | GroupBox1 *vcl.TGroupBox
11 | Label1 *vcl.TLabel
12 | IpInput *vcl.TEdit
13 | Label2 *vcl.TLabel
14 | PortInput *vcl.TEdit
15 | Label3 *vcl.TLabel
16 | ServerProtocolComboBox *vcl.TComboBox
17 | GroupBox2 *vcl.TGroupBox
18 | Label12 *vcl.TLabel
19 | LocalIp *vcl.TEdit
20 | Label13 *vcl.TLabel
21 | LocalPort *vcl.TEdit
22 | Label14 *vcl.TLabel
23 | LocalProtocolComboBox *vcl.TComboBox
24 | GroupBox3 *vcl.TGroupBox
25 | Label10 *vcl.TLabel
26 | DnsInput *vcl.TEdit
27 | Label11 *vcl.TLabel
28 | TTLInput *vcl.TEdit
29 | GroupBox4 *vcl.TGroupBox
30 | ListView1 *vcl.TListView
31 | ConfirmBtn *vcl.TButton
32 | CancelBtn *vcl.TButton
33 | Label15 *vcl.TLabel
34 | ProxyTypeComboBox *vcl.TComboBox
35 | PageControl1 *vcl.TPageControl
36 | TlsPage *vcl.TTabSheet
37 | CrtLabel *vcl.TLabel
38 | CrtInput *vcl.TEdit
39 | KeyLabel *vcl.TLabel
40 | KeyInput *vcl.TEdit
41 | SelectCrtBtn *vcl.TButton
42 | SelectKeyBtn *vcl.TButton
43 | SSHPage *vcl.TTabSheet
44 | SshUserNameLabel *vcl.TLabel
45 | SshUserNameInput *vcl.TEdit
46 | SshPwdLabel *vcl.TLabel
47 | SshPwdInput *vcl.TEdit
48 | SshKeyLabel *vcl.TLabel
49 | SshKeyInput *vcl.TEdit
50 | SelectPrivateKeyBtn *vcl.TButton
51 | KcpPage *vcl.TTabSheet
52 | KcpPwdLabel *vcl.TLabel
53 | KcpPwdInput *vcl.TEdit
54 | Label4 *vcl.TLabel
55 | ServerNameInput *vcl.TEdit
56 | PopupMenu1 *vcl.TPopupMenu
57 | AddMapping *vcl.TMenuItem
58 | ModifyMapping *vcl.TMenuItem
59 | DelMapping *vcl.TMenuItem
60 | ActionList1 *vcl.TActionList
61 | SelectCrtAction *vcl.TAction
62 | SelectKeyAction *vcl.TAction
63 | SelectPrivateKeyAction *vcl.TAction
64 | SelectCrtDialog *vcl.TOpenDialog
65 | SelectKeyDialog *vcl.TOpenDialog
66 | SelectPrivateKeyDialog *vcl.TOpenDialog
67 |
68 | //::private::
69 | TNewProxyServerFormFields
70 | }
71 |
72 | var NewProxyServerForm *TNewProxyServerForm
73 |
74 |
75 |
76 |
77 | // 以字节形式加载
78 | // vcl.Application.CreateForm(newProxyServerFormBytes, &NewProxyServerForm)
79 |
80 | var newProxyServerFormBytes = []byte("\x54\x50\x46\x30\x13\x54\x4E\x65\x77\x50\x72\x6F\x78\x79\x53\x65\x72\x76\x65\x72\x46\x6F\x72\x6D\x12\x4E\x65\x77\x50\x72\x6F\x78\x79\x53\x65\x72\x76\x65\x72\x46\x6F\x72\x6D\x04\x4C\x65\x66\x74\x03\xFC\x01\x06\x48\x65\x69\x67\x68\x74\x03\x31\x02\x03\x54\x6F\x70\x03\xB7\x00\x05\x57\x69\x64\x74\x68\x03\x95\x02\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x0C\xE6\x96\xB0\xE5\xA2\x9E\xE6\x9C\x8D\xE5\x8A\xA1\x0C\x43\x6C\x69\x65\x6E\x74\x48\x65\x69\x67\x68\x74\x03\x31\x02\x0B\x43\x6C\x69\x65\x6E\x74\x57\x69\x64\x74\x68\x03\x95\x02\x0D\x44\x65\x73\x69\x67\x6E\x54\x69\x6D\x65\x50\x50\x49\x02\x78\x0A\x4C\x43\x4C\x56\x65\x72\x73\x69\x6F\x6E\x06\x07\x32\x2E\x30\x2E\x32\x2E\x30\x00\x09\x54\x47\x72\x6F\x75\x70\x42\x6F\x78\x09\x47\x72\x6F\x75\x70\x42\x6F\x78\x31\x04\x4C\x65\x66\x74\x02\x10\x06\x48\x65\x69\x67\x68\x74\x03\xB8\x00\x03\x54\x6F\x70\x02\x30\x05\x57\x69\x64\x74\x68\x03\x80\x02\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x0F\xE6\x9C\x8D\xE5\x8A\xA1\xE5\x99\xA8\xE9\x85\x8D\xE7\xBD\xAE\x0C\x43\x6C\x69\x65\x6E\x74\x48\x65\x69\x67\x68\x74\x03\x9F\x00\x0B\x43\x6C\x69\x65\x6E\x74\x57\x69\x64\x74\x68\x03\x7C\x02\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x00\x00\x06\x54\x4C\x61\x62\x65\x6C\x06\x4C\x61\x62\x65\x6C\x31\x04\x4C\x65\x66\x74\x02\x10\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x10\x05\x57\x69\x64\x74\x68\x02\x1E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE5\x9C\xB0\xE5\x9D\x80\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x05\x54\x45\x64\x69\x74\x07\x49\x70\x49\x6E\x70\x75\x74\x04\x4C\x65\x66\x74\x02\x48\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x08\x05\x57\x69\x64\x74\x68\x03\xC8\x00\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x00\x00\x00\x06\x54\x4C\x61\x62\x65\x6C\x06\x4C\x61\x62\x65\x6C\x32\x04\x4C\x65\x66\x74\x03\x28\x01\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x10\x05\x57\x69\x64\x74\x68\x02\x1E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE7\xAB\xAF\xE5\x8F\xA3\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x05\x54\x45\x64\x69\x74\x09\x50\x6F\x72\x74\x49\x6E\x70\x75\x74\x04\x4C\x65\x66\x74\x03\x60\x01\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x08\x05\x57\x69\x64\x74\x68\x02\x64\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x01\x00\x00\x06\x54\x4C\x61\x62\x65\x6C\x06\x4C\x61\x62\x65\x6C\x33\x04\x4C\x65\x66\x74\x02\x0C\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x38\x05\x57\x69\x64\x74\x68\x02\x22\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x07\x20\xE5\x8D\x8F\xE8\xAE\xAE\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x09\x54\x43\x6F\x6D\x62\x6F\x42\x6F\x78\x16\x53\x65\x72\x76\x65\x72\x50\x72\x6F\x74\x6F\x63\x6F\x6C\x43\x6F\x6D\x62\x6F\x42\x6F\x78\x04\x4C\x65\x66\x74\x02\x48\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x30\x05\x57\x69\x64\x74\x68\x02\x7D\x0A\x49\x74\x65\x6D\x48\x65\x69\x67\x68\x74\x02\x14\x09\x49\x74\x65\x6D\x49\x6E\x64\x65\x78\x02\x00\x0D\x49\x74\x65\x6D\x73\x2E\x53\x74\x72\x69\x6E\x67\x73\x01\x06\x03\x74\x63\x70\x06\x03\x74\x6C\x73\x06\x03\x6B\x63\x70\x06\x03\x73\x73\x68\x06\x02\x77\x73\x06\x03\x77\x73\x73\x00\x08\x4F\x6E\x43\x68\x61\x6E\x67\x65\x07\x1C\x53\x65\x72\x76\x65\x72\x50\x72\x6F\x74\x6F\x63\x6F\x6C\x43\x6F\x6D\x62\x6F\x42\x6F\x78\x43\x68\x61\x6E\x67\x65\x05\x53\x74\x79\x6C\x65\x07\x0E\x63\x73\x44\x72\x6F\x70\x44\x6F\x77\x6E\x4C\x69\x73\x74\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x02\x04\x54\x65\x78\x74\x06\x03\x74\x63\x70\x00\x00\x00\x09\x54\x47\x72\x6F\x75\x70\x42\x6F\x78\x09\x47\x72\x6F\x75\x70\x42\x6F\x78\x32\x04\x4C\x65\x66\x74\x02\x10\x06\x48\x65\x69\x67\x68\x74\x02\x78\x03\x54\x6F\x70\x03\xE8\x00\x05\x57\x69\x64\x74\x68\x03\x80\x02\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x0C\xE6\x9C\xAC\xE5\x9C\xB0\xE9\x85\x8D\xE7\xBD\xAE\x0C\x43\x6C\x69\x65\x6E\x74\x48\x65\x69\x67\x68\x74\x02\x5F\x0B\x43\x6C\x69\x65\x6E\x74\x57\x69\x64\x74\x68\x03\x7C\x02\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x01\x00\x06\x54\x4C\x61\x62\x65\x6C\x07\x4C\x61\x62\x65\x6C\x31\x32\x04\x4C\x65\x66\x74\x02\x0C\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x08\x05\x57\x69\x64\x74\x68\x02\x1E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE5\x9C\xB0\xE5\x9D\x80\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x05\x54\x45\x64\x69\x74\x07\x4C\x6F\x63\x61\x6C\x49\x70\x04\x4C\x65\x66\x74\x02\x48\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x00\x05\x57\x69\x64\x74\x68\x03\xC8\x00\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x00\x04\x54\x65\x78\x74\x06\x09\x31\x32\x37\x2E\x30\x2E\x30\x2E\x31\x00\x00\x06\x54\x4C\x61\x62\x65\x6C\x07\x4C\x61\x62\x65\x6C\x31\x33\x04\x4C\x65\x66\x74\x03\x40\x01\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x08\x05\x57\x69\x64\x74\x68\x02\x1E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE7\xAB\xAF\xE5\x8F\xA3\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x05\x54\x45\x64\x69\x74\x09\x4C\x6F\x63\x61\x6C\x50\x6F\x72\x74\x04\x4C\x65\x66\x74\x03\x70\x01\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x00\x05\x57\x69\x64\x74\x68\x02\x64\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x01\x04\x54\x65\x78\x74\x06\x04\x31\x30\x38\x30\x00\x00\x06\x54\x4C\x61\x62\x65\x6C\x07\x4C\x61\x62\x65\x6C\x31\x34\x04\x4C\x65\x66\x74\x02\x0C\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x30\x05\x57\x69\x64\x74\x68\x02\x1E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE5\x8D\x8F\xE8\xAE\xAE\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x09\x54\x43\x6F\x6D\x62\x6F\x42\x6F\x78\x15\x4C\x6F\x63\x61\x6C\x50\x72\x6F\x74\x6F\x63\x6F\x6C\x43\x6F\x6D\x62\x6F\x42\x6F\x78\x04\x4C\x65\x66\x74\x02\x48\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x28\x05\x57\x69\x64\x74\x68\x02\x7D\x0A\x49\x74\x65\x6D\x48\x65\x69\x67\x68\x74\x02\x14\x09\x49\x74\x65\x6D\x49\x6E\x64\x65\x78\x02\x01\x0D\x49\x74\x65\x6D\x73\x2E\x53\x74\x72\x69\x6E\x67\x73\x01\x06\x03\x74\x6C\x73\x06\x03\x74\x63\x70\x06\x03\x6B\x63\x70\x00\x08\x4F\x6E\x43\x68\x61\x6E\x67\x65\x07\x1B\x4C\x6F\x63\x61\x6C\x50\x72\x6F\x74\x6F\x63\x6F\x6C\x43\x6F\x6D\x62\x6F\x42\x6F\x78\x43\x68\x61\x6E\x67\x65\x05\x53\x74\x79\x6C\x65\x07\x0E\x63\x73\x44\x72\x6F\x70\x44\x6F\x77\x6E\x4C\x69\x73\x74\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x02\x04\x54\x65\x78\x74\x06\x03\x74\x63\x70\x00\x00\x00\x09\x54\x47\x72\x6F\x75\x70\x42\x6F\x78\x09\x47\x72\x6F\x75\x70\x42\x6F\x78\x33\x04\x4C\x65\x66\x74\x02\x10\x06\x48\x65\x69\x67\x68\x74\x02\x58\x03\x54\x6F\x70\x03\x60\x01\x05\x57\x69\x64\x74\x68\x03\x80\x02\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x0C\xE5\x85\xB6\xE4\xBB\x96\xE9\x85\x8D\xE7\xBD\xAE\x0C\x43\x6C\x69\x65\x6E\x74\x48\x65\x69\x67\x68\x74\x02\x3F\x0B\x43\x6C\x69\x65\x6E\x74\x57\x69\x64\x74\x68\x03\x7C\x02\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x02\x00\x06\x54\x4C\x61\x62\x65\x6C\x07\x4C\x61\x62\x65\x6C\x31\x30\x04\x4C\x65\x66\x74\x02\x0C\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x11\x05\x57\x69\x64\x74\x68\x02\x20\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x03\x44\x4E\x53\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x05\x54\x45\x64\x69\x74\x08\x44\x6E\x73\x49\x6E\x70\x75\x74\x04\x4C\x65\x66\x74\x02\x40\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x09\x05\x57\x69\x64\x74\x68\x03\xB8\x00\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x00\x04\x54\x65\x78\x74\x06\x0A\x38\x2E\x38\x2E\x38\x2E\x38\x3A\x35\x33\x00\x00\x06\x54\x4C\x61\x62\x65\x6C\x07\x4C\x61\x62\x65\x6C\x31\x31\x04\x4C\x65\x66\x74\x03\x10\x01\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x11\x05\x57\x69\x64\x74\x68\x02\x33\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x08\x54\x54\x4C\x28\xE7\xA7\x92\x29\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x05\x54\x45\x64\x69\x74\x08\x54\x54\x4C\x49\x6E\x70\x75\x74\x04\x4C\x65\x66\x74\x03\x58\x01\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x09\x05\x57\x69\x64\x74\x68\x02\x64\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x01\x04\x54\x65\x78\x74\x06\x03\x36\x30\x30\x00\x00\x00\x09\x54\x47\x72\x6F\x75\x70\x42\x6F\x78\x09\x47\x72\x6F\x75\x70\x42\x6F\x78\x34\x04\x4C\x65\x66\x74\x02\x10\x06\x48\x65\x69\x67\x68\x74\x03\x08\x01\x03\x54\x6F\x70\x03\xE8\x00\x05\x57\x69\x64\x74\x68\x03\x80\x02\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x0C\xE7\xA9\xBF\xE9\x80\x8F\xE6\x98\xA0\xE5\xB0\x84\x0C\x43\x6C\x69\x65\x6E\x74\x48\x65\x69\x67\x68\x74\x03\xEF\x00\x0B\x43\x6C\x69\x65\x6E\x74\x57\x69\x64\x74\x68\x03\x7C\x02\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x03\x07\x56\x69\x73\x69\x62\x6C\x65\x08\x00\x09\x54\x4C\x69\x73\x74\x56\x69\x65\x77\x09\x4C\x69\x73\x74\x56\x69\x65\x77\x31\x04\x4C\x65\x66\x74\x02\x00\x06\x48\x65\x69\x67\x68\x74\x03\xE8\x00\x03\x54\x6F\x70\x02\x00\x05\x57\x69\x64\x74\x68\x03\x78\x02\x07\x43\x6F\x6C\x75\x6D\x6E\x73\x0E\x01\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE7\xB1\xBB\xE5\x9E\x8B\x05\x57\x69\x64\x74\x68\x02\x64\x00\x01\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x0C\xE8\xBF\x9C\xE7\xA8\x8B\xE7\xAB\xAF\xE5\x8F\xA3\x05\x57\x69\x64\x74\x68\x02\x64\x00\x01\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x0C\xE6\x9C\xAC\xE5\x9C\xB0\xE7\xAB\xAF\xE5\x8F\xA3\x05\x57\x69\x64\x74\x68\x02\x64\x00\x00\x09\x50\x6F\x70\x75\x70\x4D\x65\x6E\x75\x07\x0A\x50\x6F\x70\x75\x70\x4D\x65\x6E\x75\x31\x09\x52\x6F\x77\x53\x65\x6C\x65\x63\x74\x09\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x00\x09\x56\x69\x65\x77\x53\x74\x79\x6C\x65\x07\x08\x76\x73\x52\x65\x70\x6F\x72\x74\x00\x00\x00\x07\x54\x42\x75\x74\x74\x6F\x6E\x0A\x43\x6F\x6E\x66\x69\x72\x6D\x42\x74\x6E\x04\x4C\x65\x66\x74\x03\xB0\x00\x06\x48\x65\x69\x67\x68\x74\x02\x1F\x03\x54\x6F\x70\x03\x08\x02\x05\x57\x69\x64\x74\x68\x02\x5E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE7\xA1\xAE\xE5\xAE\x9A\x07\x4F\x6E\x43\x6C\x69\x63\x6B\x07\x0F\x43\x6F\x6E\x66\x69\x72\x6D\x42\x74\x6E\x43\x6C\x69\x63\x6B\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x04\x00\x00\x07\x54\x42\x75\x74\x74\x6F\x6E\x09\x43\x61\x6E\x63\x65\x6C\x42\x74\x6E\x04\x4C\x65\x66\x74\x03\x70\x01\x06\x48\x65\x69\x67\x68\x74\x02\x1F\x03\x54\x6F\x70\x03\x08\x02\x05\x57\x69\x64\x74\x68\x02\x5E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE5\x8F\x96\xE6\xB6\x88\x07\x4F\x6E\x43\x6C\x69\x63\x6B\x07\x0E\x43\x61\x6E\x63\x65\x6C\x42\x74\x6E\x43\x6C\x69\x63\x6B\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x05\x00\x00\x06\x54\x4C\x61\x62\x65\x6C\x07\x4C\x61\x62\x65\x6C\x31\x35\x04\x4C\x65\x66\x74\x02\x10\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x10\x05\x57\x69\x64\x74\x68\x02\x3C\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x0C\xE4\xBB\xA3\xE7\x90\x86\xE7\xB1\xBB\xE5\x9E\x8B\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x09\x54\x43\x6F\x6D\x62\x6F\x42\x6F\x78\x11\x50\x72\x6F\x78\x79\x54\x79\x70\x65\x43\x6F\x6D\x62\x6F\x42\x6F\x78\x04\x4C\x65\x66\x74\x02\x58\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x08\x05\x57\x69\x64\x74\x68\x02\x7D\x0A\x49\x74\x65\x6D\x48\x65\x69\x67\x68\x74\x02\x14\x09\x49\x74\x65\x6D\x49\x6E\x64\x65\x78\x02\x01\x0D\x49\x74\x65\x6D\x73\x2E\x53\x74\x72\x69\x6E\x67\x73\x01\x06\x04\x48\x54\x54\x50\x06\x03\x53\x50\x53\x06\x03\x54\x43\x50\x06\x03\x55\x44\x50\x06\x05\x53\x4F\x43\x4B\x53\x06\x06\xE7\xA9\xBF\xE9\x80\x8F\x00\x08\x4F\x6E\x43\x68\x61\x6E\x67\x65\x07\x17\x50\x72\x6F\x78\x79\x54\x79\x70\x65\x43\x6F\x6D\x62\x6F\x42\x6F\x78\x43\x68\x61\x6E\x67\x65\x05\x53\x74\x79\x6C\x65\x07\x0E\x63\x73\x44\x72\x6F\x70\x44\x6F\x77\x6E\x4C\x69\x73\x74\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x06\x04\x54\x65\x78\x74\x06\x03\x53\x50\x53\x00\x00\x0C\x54\x50\x61\x67\x65\x43\x6F\x6E\x74\x72\x6F\x6C\x0C\x50\x61\x67\x65\x43\x6F\x6E\x74\x72\x6F\x6C\x31\x04\x4C\x65\x66\x74\x02\x18\x06\x48\x65\x69\x67\x68\x74\x02\x38\x03\x54\x6F\x70\x03\xA0\x00\x05\x57\x69\x64\x74\x68\x03\x58\x02\x0A\x41\x63\x74\x69\x76\x65\x50\x61\x67\x65\x07\x07\x4B\x63\x70\x50\x61\x67\x65\x08\x53\x68\x6F\x77\x54\x61\x62\x73\x08\x08\x54\x61\x62\x49\x6E\x64\x65\x78\x02\x02\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x07\x07\x56\x69\x73\x69\x62\x6C\x65\x08\x00\x09\x54\x54\x61\x62\x53\x68\x65\x65\x74\x07\x54\x6C\x73\x50\x61\x67\x65\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x07\x54\x6C\x73\x50\x61\x67\x65\x0C\x43\x6C\x69\x65\x6E\x74\x48\x65\x69\x67\x68\x74\x02\x30\x0B\x43\x6C\x69\x65\x6E\x74\x57\x69\x64\x74\x68\x03\x50\x02\x00\x06\x54\x4C\x61\x62\x65\x6C\x08\x43\x72\x74\x4C\x61\x62\x65\x6C\x04\x4C\x65\x66\x74\x02\x08\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x10\x05\x57\x69\x64\x74\x68\x02\x1E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE8\xAF\x81\xE4\xB9\xA6\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x05\x54\x45\x64\x69\x74\x08\x43\x72\x74\x49\x6E\x70\x75\x74\x04\x4C\x65\x66\x74\x02\x30\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x08\x05\x57\x69\x64\x74\x68\x03\xC0\x00\x08\x52\x65\x61\x64\x4F\x6E\x6C\x79\x09\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x00\x00\x00\x06\x54\x4C\x61\x62\x65\x6C\x08\x4B\x65\x79\x4C\x61\x62\x65\x6C\x04\x4C\x65\x66\x74\x03\x30\x01\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x10\x05\x57\x69\x64\x74\x68\x02\x1E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE5\xAF\x86\xE9\x92\xA5\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x05\x54\x45\x64\x69\x74\x08\x4B\x65\x79\x49\x6E\x70\x75\x74\x04\x4C\x65\x66\x74\x03\x50\x01\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x08\x05\x57\x69\x64\x74\x68\x03\xC4\x00\x08\x52\x65\x61\x64\x4F\x6E\x6C\x79\x09\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x01\x00\x00\x07\x54\x42\x75\x74\x74\x6F\x6E\x0C\x53\x65\x6C\x65\x63\x74\x43\x72\x74\x42\x74\x6E\x04\x4C\x65\x66\x74\x03\xF0\x00\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x08\x05\x57\x69\x64\x74\x68\x02\x18\x06\x41\x63\x74\x69\x6F\x6E\x07\x0F\x53\x65\x6C\x65\x63\x74\x43\x72\x74\x41\x63\x74\x69\x6F\x6E\x07\x4F\x6E\x43\x6C\x69\x63\x6B\x07\x11\x53\x65\x6C\x65\x63\x74\x43\x72\x74\x42\x74\x6E\x43\x6C\x69\x63\x6B\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x02\x00\x00\x07\x54\x42\x75\x74\x74\x6F\x6E\x0C\x53\x65\x6C\x65\x63\x74\x4B\x65\x79\x42\x74\x6E\x04\x4C\x65\x66\x74\x03\x10\x02\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x08\x05\x57\x69\x64\x74\x68\x02\x18\x06\x41\x63\x74\x69\x6F\x6E\x07\x0F\x53\x65\x6C\x65\x63\x74\x4B\x65\x79\x41\x63\x74\x69\x6F\x6E\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x03\x00\x00\x00\x09\x54\x54\x61\x62\x53\x68\x65\x65\x74\x07\x53\x53\x48\x50\x61\x67\x65\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x07\x53\x53\x48\x50\x61\x67\x65\x0C\x43\x6C\x69\x65\x6E\x74\x48\x65\x69\x67\x68\x74\x02\x30\x0B\x43\x6C\x69\x65\x6E\x74\x57\x69\x64\x74\x68\x03\x50\x02\x00\x06\x54\x4C\x61\x62\x65\x6C\x10\x53\x73\x68\x55\x73\x65\x72\x4E\x61\x6D\x65\x4C\x61\x62\x65\x6C\x04\x4C\x65\x66\x74\x02\x00\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x10\x05\x57\x69\x64\x74\x68\x02\x2D\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x09\xE7\x94\xA8\xE6\x88\xB7\xE5\x90\x8D\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x05\x54\x45\x64\x69\x74\x10\x53\x73\x68\x55\x73\x65\x72\x4E\x61\x6D\x65\x49\x6E\x70\x75\x74\x04\x4C\x65\x66\x74\x02\x47\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x08\x05\x57\x69\x64\x74\x68\x02\x64\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x00\x00\x00\x06\x54\x4C\x61\x62\x65\x6C\x0B\x53\x73\x68\x50\x77\x64\x4C\x61\x62\x65\x6C\x04\x4C\x65\x66\x74\x03\xDF\x00\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x10\x05\x57\x69\x64\x74\x68\x02\x1E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE5\xAF\x86\xE7\xA0\x81\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x05\x54\x45\x64\x69\x74\x0B\x53\x73\x68\x50\x77\x64\x49\x6E\x70\x75\x74\x04\x4C\x65\x66\x74\x03\x13\x01\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x08\x05\x57\x69\x64\x74\x68\x02\x64\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x01\x00\x00\x06\x54\x4C\x61\x62\x65\x6C\x0B\x53\x73\x68\x4B\x65\x79\x4C\x61\x62\x65\x6C\x04\x4C\x65\x66\x74\x03\xAF\x01\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x10\x05\x57\x69\x64\x74\x68\x02\x1E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE7\xA7\x81\xE9\x92\xA5\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x05\x54\x45\x64\x69\x74\x0B\x53\x73\x68\x4B\x65\x79\x49\x6E\x70\x75\x74\x04\x4C\x65\x66\x74\x03\xD0\x01\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x08\x05\x57\x69\x64\x74\x68\x02\x64\x08\x52\x65\x61\x64\x4F\x6E\x6C\x79\x09\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x02\x00\x00\x07\x54\x42\x75\x74\x74\x6F\x6E\x13\x53\x65\x6C\x65\x63\x74\x50\x72\x69\x76\x61\x74\x65\x4B\x65\x79\x42\x74\x6E\x04\x4C\x65\x66\x74\x03\x2F\x02\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x08\x05\x57\x69\x64\x74\x68\x02\x18\x06\x41\x63\x74\x69\x6F\x6E\x07\x16\x53\x65\x6C\x65\x63\x74\x50\x72\x69\x76\x61\x74\x65\x4B\x65\x79\x41\x63\x74\x69\x6F\x6E\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x03\x00\x00\x00\x09\x54\x54\x61\x62\x53\x68\x65\x65\x74\x07\x4B\x63\x70\x50\x61\x67\x65\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x07\x4B\x63\x70\x50\x61\x67\x65\x0C\x43\x6C\x69\x65\x6E\x74\x48\x65\x69\x67\x68\x74\x02\x30\x0B\x43\x6C\x69\x65\x6E\x74\x57\x69\x64\x74\x68\x03\x50\x02\x00\x06\x54\x4C\x61\x62\x65\x6C\x0B\x4B\x63\x70\x50\x77\x64\x4C\x61\x62\x65\x6C\x04\x4C\x65\x66\x74\x02\x08\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x10\x05\x57\x69\x64\x74\x68\x02\x1E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE5\xAF\x86\xE9\x92\xA5\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x05\x54\x45\x64\x69\x74\x0B\x4B\x63\x70\x50\x77\x64\x49\x6E\x70\x75\x74\x04\x4C\x65\x66\x74\x02\x40\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x08\x05\x57\x69\x64\x74\x68\x02\x64\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x00\x00\x00\x00\x00\x06\x54\x4C\x61\x62\x65\x6C\x06\x4C\x61\x62\x65\x6C\x34\x04\x4C\x65\x66\x74\x03\x20\x01\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x10\x05\x57\x69\x64\x74\x68\x02\x1E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE5\x90\x8D\xE7\xA7\xB0\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x05\x54\x45\x64\x69\x74\x0F\x53\x65\x72\x76\x65\x72\x4E\x61\x6D\x65\x49\x6E\x70\x75\x74\x04\x4C\x65\x66\x74\x03\x68\x01\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x08\x05\x57\x69\x64\x74\x68\x03\xC8\x00\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x08\x00\x00\x0A\x54\x50\x6F\x70\x75\x70\x4D\x65\x6E\x75\x0A\x50\x6F\x70\x75\x70\x4D\x65\x6E\x75\x31\x04\x6C\x65\x66\x74\x03\xF0\x01\x03\x74\x6F\x70\x03\x08\x02\x00\x09\x54\x4D\x65\x6E\x75\x49\x74\x65\x6D\x0A\x41\x64\x64\x4D\x61\x70\x70\x69\x6E\x67\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE6\x96\xB0\xE5\xA2\x9E\x07\x4F\x6E\x43\x6C\x69\x63\x6B\x07\x0F\x41\x64\x64\x4D\x61\x70\x70\x69\x6E\x67\x43\x6C\x69\x63\x6B\x00\x00\x09\x54\x4D\x65\x6E\x75\x49\x74\x65\x6D\x0D\x4D\x6F\x64\x69\x66\x79\x4D\x61\x70\x70\x69\x6E\x67\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE4\xBF\xAE\xE6\x94\xB9\x07\x4F\x6E\x43\x6C\x69\x63\x6B\x07\x12\x4D\x6F\x64\x69\x66\x79\x4D\x61\x70\x70\x69\x6E\x67\x43\x6C\x69\x63\x6B\x00\x00\x09\x54\x4D\x65\x6E\x75\x49\x74\x65\x6D\x0A\x44\x65\x6C\x4D\x61\x70\x70\x69\x6E\x67\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE5\x88\xA0\xE9\x99\xA4\x07\x4F\x6E\x43\x6C\x69\x63\x6B\x07\x0F\x44\x65\x6C\x4D\x61\x70\x70\x69\x6E\x67\x43\x6C\x69\x63\x6B\x00\x00\x00\x0B\x54\x41\x63\x74\x69\x6F\x6E\x4C\x69\x73\x74\x0B\x41\x63\x74\x69\x6F\x6E\x4C\x69\x73\x74\x31\x04\x6C\x65\x66\x74\x03\x70\x02\x03\x74\x6F\x70\x03\x08\x02\x00\x07\x54\x41\x63\x74\x69\x6F\x6E\x0F\x53\x65\x6C\x65\x63\x74\x43\x72\x74\x41\x63\x74\x69\x6F\x6E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x03\x2E\x2E\x2E\x09\x4F\x6E\x45\x78\x65\x63\x75\x74\x65\x07\x16\x53\x65\x6C\x65\x63\x74\x43\x72\x74\x41\x63\x74\x69\x6F\x6E\x45\x78\x65\x63\x75\x74\x65\x00\x00\x07\x54\x41\x63\x74\x69\x6F\x6E\x0F\x53\x65\x6C\x65\x63\x74\x4B\x65\x79\x41\x63\x74\x69\x6F\x6E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x03\x2E\x2E\x2E\x09\x4F\x6E\x45\x78\x65\x63\x75\x74\x65\x07\x16\x53\x65\x6C\x65\x63\x74\x4B\x65\x79\x41\x63\x74\x69\x6F\x6E\x45\x78\x65\x63\x75\x74\x65\x00\x00\x07\x54\x41\x63\x74\x69\x6F\x6E\x16\x53\x65\x6C\x65\x63\x74\x50\x72\x69\x76\x61\x74\x65\x4B\x65\x79\x41\x63\x74\x69\x6F\x6E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x03\x2E\x2E\x2E\x09\x4F\x6E\x45\x78\x65\x63\x75\x74\x65\x07\x1D\x53\x65\x6C\x65\x63\x74\x50\x72\x69\x76\x61\x74\x65\x4B\x65\x79\x41\x63\x74\x69\x6F\x6E\x45\x78\x65\x63\x75\x74\x65\x00\x00\x00\x0B\x54\x4F\x70\x65\x6E\x44\x69\x61\x6C\x6F\x67\x0F\x53\x65\x6C\x65\x63\x74\x43\x72\x74\x44\x69\x61\x6C\x6F\x67\x04\x6C\x65\x66\x74\x03\x10\x02\x03\x74\x6F\x70\x03\x08\x02\x00\x00\x0B\x54\x4F\x70\x65\x6E\x44\x69\x61\x6C\x6F\x67\x0F\x53\x65\x6C\x65\x63\x74\x4B\x65\x79\x44\x69\x61\x6C\x6F\x67\x04\x6C\x65\x66\x74\x03\x30\x02\x03\x74\x6F\x70\x03\x08\x02\x00\x00\x0B\x54\x4F\x70\x65\x6E\x44\x69\x61\x6C\x6F\x67\x16\x53\x65\x6C\x65\x63\x74\x50\x72\x69\x76\x61\x74\x65\x4B\x65\x79\x44\x69\x61\x6C\x6F\x67\x04\x6C\x65\x66\x74\x03\x50\x02\x03\x74\x6F\x70\x03\x08\x02\x00\x00\x00")
81 |
--------------------------------------------------------------------------------
/Lazarus/NewProxyServerFormImpl.go:
--------------------------------------------------------------------------------
1 | // 由res2go自动生成。
2 | // 在这里写你的事件。
3 |
4 | package main
5 |
6 | import (
7 | "github.com/ying32/govcl/vcl"
8 | )
9 |
10 | //::private::
11 | type TNewProxyServerFormFields struct {
12 | }
13 |
14 |
15 | func (f *TNewProxyServerForm) OnServerProtocolComboBoxChange(sender vcl.IObject) {
16 | text := NewProxyServerForm.ServerProtocolComboBox.Text()
17 | switch text {
18 | case "tls":
19 | NewProxyServerForm.PageControl1.SetVisible(true)
20 | NewProxyServerForm.PageControl1.SetActivePageIndex(0)
21 | break;
22 | case "ssh":
23 | NewProxyServerForm.PageControl1.SetVisible(true)
24 | NewProxyServerForm.PageControl1.SetActivePageIndex(1)
25 | break;
26 | case "kcp":
27 | NewProxyServerForm.PageControl1.SetVisible(true)
28 | NewProxyServerForm.PageControl1.SetActivePageIndex(2)
29 | break;
30 | default:
31 | NewProxyServerForm.PageControl1.SetVisible(false)
32 | }
33 | }
34 |
35 |
36 | func (f *TNewProxyServerForm) OnLocalProtocolComboBoxChange(sender vcl.IObject) {
37 |
38 | }
39 |
40 |
41 | func (f *TNewProxyServerForm) OnConfirmBtnClick(sender vcl.IObject) {
42 | proxyType := NewProxyServerForm.ProxyTypeComboBox.Text()
43 | remoteIp := NewProxyServerForm.IpInput.Text()
44 | remotePort := NewProxyServerForm.PortInput.Text()
45 | remoteProtocol := NewProxyServerForm.ServerProtocolComboBox.Text()
46 |
47 | crtLocation := NewProxyServerForm.CrtInput.Text()
48 | keyLocation := NewProxyServerForm.KeyInput.Text()
49 |
50 | sshPrivateKey := NewProxyServerForm.SshKeyInput.Text()
51 | sshUserName := NewProxyServerForm.SshUserNameInput.Text()
52 | sshPwd := NewProxyServerForm.SshPwdInput.Text()
53 |
54 | kcpPwd := NewProxyServerForm.KcpPwdInput.Text()
55 |
56 | localProtocol := NewProxyServerForm.LocalProtocolComboBox.Text()
57 | localIp := NewProxyServerForm.LocalIp.Text()
58 | localPort := NewProxyServerForm.LocalPort.Text()
59 |
60 | dns := NewProxyServerForm.DnsInput.Text()
61 | dnsTtl := NewProxyServerForm.TTLInput.Text()
62 |
63 | p := ProxyInfo{0,
64 | "",
65 | proxyType, remoteIp,remotePort, remoteProtocol,
66 | localIp, localPort, localProtocol, crtLocation, keyLocation,
67 | sshUserName, sshPwd, sshPrivateKey, kcpPwd, dns, dnsTtl}
68 | addNewProxyInfo(p)
69 | }
70 |
71 |
72 | func (f *TNewProxyServerForm) OnCancelBtnClick(sender vcl.IObject) {
73 |
74 | }
75 |
76 |
77 | func (f *TNewProxyServerForm) OnProxyTypeComboBoxChange(sender vcl.IObject) {
78 | text := NewProxyServerForm.ProxyTypeComboBox.Text()
79 | if text == "穿透" {
80 | NewProxyServerForm.GroupBox2.SetVisible(false)
81 | NewProxyServerForm.GroupBox3.SetVisible(false)
82 | NewProxyServerForm.GroupBox4.SetVisible(true)
83 | } else {
84 | NewProxyServerForm.GroupBox2.SetVisible(true)
85 | NewProxyServerForm.GroupBox3.SetVisible(true)
86 | NewProxyServerForm.GroupBox4.SetVisible(false)
87 | }
88 | }
89 |
90 | func (f *TNewProxyServerForm) OnAddMappingClick(sender vcl.IObject) {
91 | AddMappingForm.ShowModal()
92 | }
93 |
94 |
95 | func (f *TNewProxyServerForm) OnModifyMappingClick(sender vcl.IObject) {
96 |
97 | }
98 |
99 |
100 | func (f *TNewProxyServerForm) OnDelMappingClick(sender vcl.IObject) {
101 |
102 | }
103 |
104 |
105 | func (f *TNewProxyServerForm) OnSelectCrtActionExecute(sender vcl.IObject) {
106 | NewProxyServerForm.SelectCrtDialog.SetFilter("证书文件(*.CRT;*.CER)|*.CRT;*.CER|全部文件(*.*)|*.*")
107 | NewProxyServerForm.SelectCrtDialog.SetDefaultExt("*.CRT")
108 | if NewProxyServerForm.SelectCrtDialog.Execute() {
109 | strFileName := NewProxyServerForm.SelectCrtDialog.FileName()
110 | if strFileName != "" {
111 | NewProxyServerForm.CrtInput.SetText(strFileName)
112 | }
113 | }
114 | }
115 |
116 |
117 | func (f *TNewProxyServerForm) OnSelectKeyActionExecute(sender vcl.IObject) {
118 | NewProxyServerForm.SelectKeyDialog.SetFilter("密钥文件(*.KEY)|*.KEY|全部文件(*.*)|*.*")
119 | NewProxyServerForm.SelectKeyDialog.SetDefaultExt("*.KEY")
120 | if NewProxyServerForm.SelectKeyDialog.Execute() {
121 | strFileName := NewProxyServerForm.SelectKeyDialog.FileName()
122 | if strFileName != "" {
123 | NewProxyServerForm.KeyInput.SetText(strFileName)
124 | }
125 | }
126 | }
127 |
128 |
129 | func (f *TNewProxyServerForm) OnSelectPrivateKeyActionExecute(sender vcl.IObject) {
130 | NewProxyServerForm.SelectKeyDialog.SetFilter("密钥文件(*.PEM)|*.PEM|全部文件(*.*)|*.*")
131 | NewProxyServerForm.SelectKeyDialog.SetDefaultExt("*.PEM")
132 | if NewProxyServerForm.SelectKeyDialog.Execute() {
133 | strFileName := NewProxyServerForm.SelectKeyDialog.FileName()
134 | if strFileName != "" {
135 | NewProxyServerForm.SshKeyInput.SetText(strFileName)
136 | }
137 | }
138 | }
139 |
140 |
141 | func (f *TNewProxyServerForm) OnSelectCrtBtnClick(sender vcl.IObject) {
142 |
143 | }
144 |
145 |
--------------------------------------------------------------------------------
/Lazarus/SettingForm.go:
--------------------------------------------------------------------------------
1 | // 由res2go自动生成,不要编辑。
2 | package main
3 |
4 | import (
5 | "github.com/ying32/govcl/vcl"
6 | )
7 |
8 | type TSettingForm struct {
9 | *vcl.TForm
10 | AutoStartChk *vcl.TCheckBox
11 | SysProxyChk *vcl.TCheckBox
12 | PortEdit *vcl.TEdit
13 | PortLabel *vcl.TLabel
14 | ConfirmBtn *vcl.TButton
15 | CancelBtn *vcl.TButton
16 |
17 | //::private::
18 | TSettingFormFields
19 | }
20 |
21 | var SettingForm *TSettingForm
22 |
23 |
24 |
25 |
26 | // 以字节形式加载
27 | // vcl.Application.CreateForm(settingFormBytes, &SettingForm)
28 |
29 | var settingFormBytes = []byte("\x54\x50\x46\x30\x0C\x54\x53\x65\x74\x74\x69\x6E\x67\x46\x6F\x72\x6D\x0B\x53\x65\x74\x74\x69\x6E\x67\x46\x6F\x72\x6D\x04\x4C\x65\x66\x74\x03\x48\x02\x06\x48\x65\x69\x67\x68\x74\x03\xA4\x00\x03\x54\x6F\x70\x03\xDC\x01\x05\x57\x69\x64\x74\x68\x03\xE5\x01\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x0C\xE7\xB3\xBB\xE7\xBB\x9F\xE8\xAE\xBE\xE7\xBD\xAE\x0C\x43\x6C\x69\x65\x6E\x74\x48\x65\x69\x67\x68\x74\x03\xA4\x00\x0B\x43\x6C\x69\x65\x6E\x74\x57\x69\x64\x74\x68\x03\xE5\x01\x0D\x44\x65\x73\x69\x67\x6E\x54\x69\x6D\x65\x50\x50\x49\x02\x78\x0A\x4C\x43\x4C\x56\x65\x72\x73\x69\x6F\x6E\x06\x07\x31\x2E\x38\x2E\x34\x2E\x30\x00\x09\x54\x43\x68\x65\x63\x6B\x42\x6F\x78\x0C\x41\x75\x74\x6F\x53\x74\x61\x72\x74\x43\x68\x6B\x04\x4C\x65\x66\x74\x02\x37\x06\x48\x65\x69\x67\x68\x74\x02\x18\x03\x54\x6F\x70\x02\x10\x05\x57\x69\x64\x74\x68\x02\x54\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x0C\xE8\x87\xAA\xE5\x8A\xA8\xE5\x90\xAF\xE5\x8A\xA8\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x00\x00\x00\x09\x54\x43\x68\x65\x63\x6B\x42\x6F\x78\x0B\x53\x79\x73\x50\x72\x6F\x78\x79\x43\x68\x6B\x04\x4C\x65\x66\x74\x02\x37\x06\x48\x65\x69\x67\x68\x74\x02\x18\x03\x54\x6F\x70\x02\x40\x05\x57\x69\x64\x74\x68\x02\x54\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x0C\xE7\xB3\xBB\xE7\xBB\x9F\xE4\xBB\xA3\xE7\x90\x86\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x01\x00\x00\x05\x54\x45\x64\x69\x74\x08\x50\x6F\x72\x74\x45\x64\x69\x74\x04\x4C\x65\x66\x74\x03\xD0\x00\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x3C\x05\x57\x69\x64\x74\x68\x03\x98\x00\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x02\x04\x54\x65\x78\x74\x06\x0E\x31\x32\x37\x2E\x30\x2E\x30\x2E\x31\x3A\x38\x30\x38\x30\x00\x00\x06\x54\x4C\x61\x62\x65\x6C\x09\x50\x6F\x72\x74\x4C\x61\x62\x65\x6C\x04\x4C\x65\x66\x74\x03\xA8\x00\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x42\x05\x57\x69\x64\x74\x68\x02\x1E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE7\xAB\xAF\xE5\x8F\xA3\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x07\x54\x42\x75\x74\x74\x6F\x6E\x0A\x43\x6F\x6E\x66\x69\x72\x6D\x42\x74\x6E\x04\x4C\x65\x66\x74\x02\x48\x06\x48\x65\x69\x67\x68\x74\x02\x1F\x03\x54\x6F\x70\x02\x73\x05\x57\x69\x64\x74\x68\x02\x5E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE7\xA1\xAE\xE5\xAE\x9A\x07\x4F\x6E\x43\x6C\x69\x63\x6B\x07\x0F\x43\x6F\x6E\x66\x69\x72\x6D\x42\x74\x6E\x43\x6C\x69\x63\x6B\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x03\x00\x00\x07\x54\x42\x75\x74\x74\x6F\x6E\x09\x43\x61\x6E\x63\x65\x6C\x42\x74\x6E\x04\x4C\x65\x66\x74\x03\x18\x01\x06\x48\x65\x69\x67\x68\x74\x02\x1F\x03\x54\x6F\x70\x02\x73\x05\x57\x69\x64\x74\x68\x02\x5E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE5\x8F\x96\xE6\xB6\x88\x07\x4F\x6E\x43\x6C\x69\x63\x6B\x07\x0E\x43\x61\x6E\x63\x65\x6C\x42\x74\x6E\x43\x6C\x69\x63\x6B\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x04\x00\x00\x00")
30 |
--------------------------------------------------------------------------------
/Lazarus/SettingFormImpl.go:
--------------------------------------------------------------------------------
1 | // 由res2go自动生成。
2 | // 在这里写你的事件。
3 |
4 | package main
5 |
6 | import (
7 | "github.com/ying32/govcl/vcl"
8 | "github.com/ying32/govcl/vcl/types"
9 | )
10 |
11 | //::private::
12 | type TSettingFormFields struct {
13 | }
14 |
15 | func (f *TSettingForm) OnConfirmBtnClick(sender vcl.IObject) {
16 | var isAutoRunFlag = true
17 | var isSysProxyFlag = true
18 | if SettingForm.AutoStartChk.Checked() {
19 | isAutoRunFlag = setAutoRun()
20 | } else {
21 | isAutoRunFlag = unSetAutoRun()
22 | }
23 | addr := SettingForm.PortEdit.Text()
24 | if SettingForm.SysProxyChk.Checked() {
25 | isSysProxyFlag = setSysProxy(addr)
26 | } else {
27 | isSysProxyFlag = unsetSysProxy(addr)
28 | }
29 | /*cfg, _ := goconfig.LoadConfigFile(mainConfigName)
30 | cfg.SetValue("common", "autoRun", strconv.FormatBool(SettingForm.AutoStartChk.Checked()))
31 | cfg.SetValue("common", "sysProxy", strconv.FormatBool(SettingForm.SysProxyChk.Checked()))
32 | cfg.SetValue("common", "sysProxyAddr", addr)
33 | _ = goconfig.SaveConfigFile(cfg, mainConfigName)*/
34 | if isAutoRunFlag && isSysProxyFlag {
35 | vcl.MessageDlg("设置成功", types.MtInformation, types.MbOK)
36 | SettingForm.Close()
37 | } else {
38 | vcl.MessageDlg("设置失败,请尝试以管理员身份运行", types.MtError, types.MbOK)
39 | }
40 | }
41 |
42 | func (f *TSettingForm) OnCancelBtnClick(sender vcl.IObject) {
43 | SettingForm.Close()
44 | }
45 |
--------------------------------------------------------------------------------
/Lazarus/backup/project1.lpi:
--------------------------------------------------------------------------------
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 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
--------------------------------------------------------------------------------
/Lazarus/backup/project1.lpr:
--------------------------------------------------------------------------------
1 | program project1;
2 |
3 | {$mode objfpc}{$H+}
4 |
5 | uses
6 | {$IFDEF UNIX}{$IFDEF UseCThreads}
7 | cthreads,
8 | {$ENDIF}{$ENDIF}
9 | Interfaces, // this includes the LCL widgetset
10 | Forms, Unit1, Unit2, Unit3, unit4
11 | { you can add units after this };
12 |
13 | {$R *.res}
14 |
15 | begin
16 | RequireDerivedFormResource:=True;
17 | Application.Scaled:=True;
18 | Application.Initialize;
19 | Application.CreateForm(TMainForm, MainForm);
20 | Application.CreateForm(TNewProxyServerForm, NewProxyServerForm);
21 | Application.CreateForm(TAddMappingForm, AddMappingForm);
22 | Application.Run;
23 | end.
24 |
25 |
--------------------------------------------------------------------------------
/Lazarus/backup/project1.lps:
--------------------------------------------------------------------------------
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 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
105 |
106 |
107 |
108 |
109 |
110 |
111 |
112 |
113 |
114 |
115 |
116 |
117 |
118 |
119 |
120 |
121 |
122 |
123 |
124 |
125 |
126 |
127 |
128 |
129 |
130 |
131 |
132 |
133 |
134 |
135 |
136 |
137 |
138 |
139 |
140 |
141 |
142 |
143 |
144 |
145 |
146 |
147 |
148 |
149 |
150 |
151 |
152 |
153 |
154 |
155 |
156 |
157 |
158 |
159 |
160 |
161 |
162 |
163 |
164 |
165 |
166 |
167 |
168 |
169 |
170 |
171 |
172 |
173 |
174 |
175 |
176 |
177 |
178 |
179 |
180 |
181 |
182 |
183 |
184 |
185 |
186 |
187 |
--------------------------------------------------------------------------------
/Lazarus/backup/unit1.pas:
--------------------------------------------------------------------------------
1 | unit Unit1;
2 |
3 | {$mode objfpc}{$H+}
4 |
5 | interface
6 |
7 | uses
8 | Classes, SysUtils, Forms, Controls, Graphics, Dialogs, ComCtrls, Menus,
9 | ActnList, ExtCtrls, StdCtrls;
10 |
11 | type
12 |
13 | { TMainForm }
14 |
15 | TMainForm = class(TForm)
16 | GroupBox1: TGroupBox;
17 | GroupBox2: TGroupBox;
18 | GroupBox3: TGroupBox;
19 | ImageList1: TImageList;
20 | ListView1: TListView;
21 | Memo1: TMemo;
22 | Memo2: TMemo;
23 | AddServer: TMenuItem;
24 | ShowMainWindow: TMenuItem;
25 | ExitMainWindow: TMenuItem;
26 | TrayPopupMenu: TPopupMenu;
27 | SetActivityServer: TMenuItem;
28 | PingServer: TMenuItem;
29 | PopupMenu1: TPopupMenu;
30 | ToolBar1: TToolBar;
31 | ToolButton1: TToolButton;
32 | ToolButton2: TToolButton;
33 | SettingsBtn: TToolButton;
34 | ToolButton4: TToolButton;
35 | TrayIcon1: TTrayIcon;
36 | UpdateBtn: TToolButton;
37 | ToolButton6: TToolButton;
38 | HelpBtn: TToolButton;
39 | ToolButton8: TToolButton;
40 | procedure AddServerClick(Sender: TObject);
41 | procedure ExitMainWindowClick(Sender: TObject);
42 | procedure PingServerClick(Sender: TObject);
43 | procedure SetActivityServerClick(Sender: TObject);
44 | procedure SettingsBtnClick(Sender: TObject);
45 | procedure HelpBtnClick(Sender: TObject);
46 | procedure ShowMainWindowClick(Sender: TObject);
47 | procedure UpdateBtnClick(Sender: TObject);
48 | private
49 |
50 | public
51 |
52 | end;
53 |
54 | var
55 | MainForm: TMainForm;
56 |
57 | implementation
58 |
59 | {$R *.lfm}
60 |
61 | { TMainForm }
62 |
63 | procedure TMainForm.SettingsBtnClick(Sender: TObject);
64 | begin
65 |
66 | end;
67 |
68 | procedure TMainForm.HelpBtnClick(Sender: TObject);
69 | begin
70 |
71 | end;
72 |
73 | procedure TMainForm.ShowMainWindowClick(Sender: TObject);
74 | begin
75 |
76 | end;
77 |
78 | procedure TMainForm.UpdateBtnClick(Sender: TObject);
79 | begin
80 |
81 | end;
82 |
83 | procedure TMainForm.AddServerClick(Sender: TObject);
84 | begin
85 |
86 | end;
87 |
88 | procedure TMainForm.ExitMainWindowClick(Sender: TObject);
89 | begin
90 |
91 | end;
92 |
93 | procedure TMainForm.PingServerClick(Sender: TObject);
94 | begin
95 |
96 | end;
97 |
98 | procedure TMainForm.SetActivityServerClick(Sender: TObject);
99 | begin
100 |
101 | end;
102 |
103 | end.
104 |
105 |
--------------------------------------------------------------------------------
/Lazarus/backup/unit2.lfm:
--------------------------------------------------------------------------------
1 | object NewProxyServerForm: TNewProxyServerForm
2 | Left = 508
3 | Height = 561
4 | Top = 183
5 | Width = 661
6 | Caption = '新增服务'
7 | ClientHeight = 561
8 | ClientWidth = 661
9 | DesignTimePPI = 120
10 | LCLVersion = '2.0.2.0'
11 | object GroupBox1: TGroupBox
12 | Left = 16
13 | Height = 184
14 | Top = 48
15 | Width = 640
16 | Caption = '服务器配置'
17 | ClientHeight = 159
18 | ClientWidth = 636
19 | TabOrder = 0
20 | object Label1: TLabel
21 | Left = 16
22 | Height = 20
23 | Top = 16
24 | Width = 30
25 | Caption = '地址'
26 | ParentColor = False
27 | end
28 | object IpInput: TEdit
29 | Left = 72
30 | Height = 28
31 | Top = 8
32 | Width = 200
33 | TabOrder = 0
34 | end
35 | object Label2: TLabel
36 | Left = 296
37 | Height = 20
38 | Top = 16
39 | Width = 30
40 | Caption = '端口'
41 | ParentColor = False
42 | end
43 | object PortInput: TEdit
44 | Left = 352
45 | Height = 28
46 | Top = 8
47 | Width = 100
48 | TabOrder = 1
49 | end
50 | object Label3: TLabel
51 | Left = 12
52 | Height = 20
53 | Top = 56
54 | Width = 34
55 | Caption = ' 协议'
56 | ParentColor = False
57 | end
58 | object ServerProtocolComboBox: TComboBox
59 | Left = 72
60 | Height = 28
61 | Top = 48
62 | Width = 125
63 | ItemHeight = 20
64 | ItemIndex = 0
65 | Items.Strings = (
66 | 'tcp'
67 | 'tls'
68 | 'kcp'
69 | 'ssh'
70 | 'ws'
71 | 'wss'
72 | )
73 | OnChange = ServerProtocolComboBoxChange
74 | Style = csDropDownList
75 | TabOrder = 2
76 | Text = 'tcp'
77 | end
78 | end
79 | object GroupBox2: TGroupBox
80 | Left = 16
81 | Height = 120
82 | Top = 232
83 | Width = 640
84 | Caption = '本地配置'
85 | ClientHeight = 95
86 | ClientWidth = 636
87 | TabOrder = 1
88 | object Label12: TLabel
89 | Left = 12
90 | Height = 20
91 | Top = 8
92 | Width = 30
93 | Caption = '地址'
94 | ParentColor = False
95 | end
96 | object LocalIp: TEdit
97 | Left = 72
98 | Height = 28
99 | Top = 0
100 | Width = 200
101 | TabOrder = 0
102 | Text = '127.0.0.1'
103 | end
104 | object Label13: TLabel
105 | Left = 320
106 | Height = 20
107 | Top = 8
108 | Width = 30
109 | Caption = '端口'
110 | ParentColor = False
111 | end
112 | object LocalPort: TEdit
113 | Left = 368
114 | Height = 28
115 | Top = 0
116 | Width = 100
117 | TabOrder = 1
118 | Text = '1080'
119 | end
120 | object Label14: TLabel
121 | Left = 12
122 | Height = 20
123 | Top = 48
124 | Width = 30
125 | Caption = '协议'
126 | ParentColor = False
127 | end
128 | object LocalProtocolComboBox: TComboBox
129 | Left = 72
130 | Height = 28
131 | Top = 40
132 | Width = 125
133 | ItemHeight = 20
134 | ItemIndex = 1
135 | Items.Strings = (
136 | 'tls'
137 | 'tcp'
138 | 'kcp'
139 | )
140 | OnChange = LocalProtocolComboBoxChange
141 | Style = csDropDownList
142 | TabOrder = 2
143 | Text = 'tcp'
144 | end
145 | end
146 | object GroupBox3: TGroupBox
147 | Left = 16
148 | Height = 88
149 | Top = 352
150 | Width = 640
151 | Caption = '其他配置'
152 | ClientHeight = 63
153 | ClientWidth = 636
154 | TabOrder = 2
155 | object Label10: TLabel
156 | Left = 12
157 | Height = 20
158 | Top = 17
159 | Width = 32
160 | Caption = 'DNS'
161 | ParentColor = False
162 | end
163 | object DnsInput: TEdit
164 | Left = 64
165 | Height = 28
166 | Top = 9
167 | Width = 184
168 | TabOrder = 0
169 | Text = '8.8.8.8:53'
170 | end
171 | object Label11: TLabel
172 | Left = 272
173 | Height = 20
174 | Top = 17
175 | Width = 51
176 | Caption = 'TTL(秒)'
177 | ParentColor = False
178 | end
179 | object TTLInput: TEdit
180 | Left = 344
181 | Height = 28
182 | Top = 9
183 | Width = 100
184 | TabOrder = 1
185 | Text = '600'
186 | end
187 | end
188 | object GroupBox4: TGroupBox
189 | Left = 16
190 | Height = 264
191 | Top = 232
192 | Width = 640
193 | Caption = '穿透映射'
194 | ClientHeight = 239
195 | ClientWidth = 636
196 | TabOrder = 3
197 | Visible = False
198 | object ListView1: TListView
199 | Left = 0
200 | Height = 232
201 | Top = 0
202 | Width = 632
203 | Columns = <
204 | item
205 | Caption = '类型'
206 | Width = 100
207 | end
208 | item
209 | Caption = '远程端口'
210 | Width = 100
211 | end
212 | item
213 | Caption = '本地端口'
214 | Width = 100
215 | end>
216 | PopupMenu = PopupMenu1
217 | RowSelect = True
218 | TabOrder = 0
219 | ViewStyle = vsReport
220 | end
221 | end
222 | object ConfirmBtn: TButton
223 | Left = 176
224 | Height = 31
225 | Top = 520
226 | Width = 94
227 | Caption = '确定'
228 | OnClick = ConfirmBtnClick
229 | TabOrder = 4
230 | end
231 | object CancelBtn: TButton
232 | Left = 368
233 | Height = 31
234 | Top = 520
235 | Width = 94
236 | Caption = '取消'
237 | OnClick = CancelBtnClick
238 | TabOrder = 5
239 | end
240 | object Label15: TLabel
241 | Left = 16
242 | Height = 20
243 | Top = 16
244 | Width = 60
245 | Caption = '代理类型'
246 | ParentColor = False
247 | end
248 | object ProxyTypeComboBox: TComboBox
249 | Left = 88
250 | Height = 28
251 | Top = 8
252 | Width = 125
253 | ItemHeight = 20
254 | ItemIndex = 1
255 | Items.Strings = (
256 | 'HTTP'
257 | 'SPS'
258 | 'TCP'
259 | 'UDP'
260 | 'SOCKS'
261 | '穿透'
262 | )
263 | OnChange = ProxyTypeComboBoxChange
264 | Style = csDropDownList
265 | TabOrder = 6
266 | Text = 'SPS'
267 | end
268 | object PageControl1: TPageControl
269 | Left = 24
270 | Height = 56
271 | Top = 160
272 | Width = 600
273 | ActivePage = KcpPage
274 | ShowTabs = False
275 | TabIndex = 2
276 | TabOrder = 7
277 | Visible = False
278 | object TlsPage: TTabSheet
279 | Caption = 'TlsPage'
280 | ClientHeight = 48
281 | ClientWidth = 592
282 | object CrtLabel: TLabel
283 | Left = 8
284 | Height = 20
285 | Top = 16
286 | Width = 30
287 | Caption = '证书'
288 | ParentColor = False
289 | end
290 | object CrtInput: TEdit
291 | Left = 48
292 | Height = 28
293 | Top = 8
294 | Width = 192
295 | ReadOnly = True
296 | TabOrder = 0
297 | end
298 | object KeyLabel: TLabel
299 | Left = 304
300 | Height = 20
301 | Top = 16
302 | Width = 30
303 | Caption = '密钥'
304 | ParentColor = False
305 | end
306 | object KeyInput: TEdit
307 | Left = 336
308 | Height = 28
309 | Top = 8
310 | Width = 196
311 | ReadOnly = True
312 | TabOrder = 1
313 | end
314 | object SelectCrtBtn: TButton
315 | Left = 240
316 | Height = 28
317 | Top = 8
318 | Width = 24
319 | Action = SelectCrtAction
320 | OnClick = SelectCrtBtnClick
321 | TabOrder = 2
322 | end
323 | object SelectKeyBtn: TButton
324 | Left = 528
325 | Height = 28
326 | Top = 8
327 | Width = 24
328 | Action = SelectKeyAction
329 | TabOrder = 3
330 | end
331 | end
332 | object SSHPage: TTabSheet
333 | Caption = 'SSHPage'
334 | ClientHeight = 48
335 | ClientWidth = 592
336 | object SshUserNameLabel: TLabel
337 | Left = 0
338 | Height = 20
339 | Top = 16
340 | Width = 45
341 | Caption = '用户名'
342 | ParentColor = False
343 | end
344 | object SshUserNameInput: TEdit
345 | Left = 71
346 | Height = 28
347 | Top = 8
348 | Width = 100
349 | TabOrder = 0
350 | end
351 | object SshPwdLabel: TLabel
352 | Left = 223
353 | Height = 20
354 | Top = 16
355 | Width = 30
356 | Caption = '密码'
357 | ParentColor = False
358 | end
359 | object SshPwdInput: TEdit
360 | Left = 275
361 | Height = 28
362 | Top = 8
363 | Width = 100
364 | TabOrder = 1
365 | end
366 | object SshKeyLabel: TLabel
367 | Left = 431
368 | Height = 20
369 | Top = 16
370 | Width = 30
371 | Caption = '私钥'
372 | ParentColor = False
373 | end
374 | object SshKeyInput: TEdit
375 | Left = 464
376 | Height = 28
377 | Top = 8
378 | Width = 100
379 | ReadOnly = True
380 | TabOrder = 2
381 | end
382 | object SelectPrivateKeyBtn: TButton
383 | Left = 559
384 | Height = 28
385 | Top = 8
386 | Width = 24
387 | Action = SelectPrivateKeyAction
388 | TabOrder = 3
389 | end
390 | end
391 | object KcpPage: TTabSheet
392 | Caption = 'KcpPage'
393 | ClientHeight = 48
394 | ClientWidth = 592
395 | object KcpPwdLabel: TLabel
396 | Left = 8
397 | Height = 20
398 | Top = 16
399 | Width = 30
400 | Caption = '密钥'
401 | ParentColor = False
402 | end
403 | object KcpPwdInput: TEdit
404 | Left = 64
405 | Height = 28
406 | Top = 8
407 | Width = 100
408 | TabOrder = 0
409 | end
410 | end
411 | end
412 | object Label4: TLabel
413 | Left = 288
414 | Height = 20
415 | Top = 16
416 | Width = 30
417 | Caption = '名称'
418 | ParentColor = False
419 | end
420 | object ServerNameInput: TEdit
421 | Left = 360
422 | Height = 28
423 | Top = 8
424 | Width = 200
425 | TabOrder = 8
426 | end
427 | object PopupMenu1: TPopupMenu
428 | left = 496
429 | top = 520
430 | object AddMapping: TMenuItem
431 | Caption = '新增'
432 | OnClick = AddMappingClick
433 | end
434 | object ModifyMapping: TMenuItem
435 | Caption = '修改'
436 | OnClick = ModifyMappingClick
437 | end
438 | object DelMapping: TMenuItem
439 | Caption = '删除'
440 | OnClick = DelMappingClick
441 | end
442 | end
443 | object ActionList1: TActionList
444 | left = 624
445 | top = 520
446 | object SelectCrtAction: TAction
447 | Caption = '...'
448 | OnExecute = SelectCrtActionExecute
449 | end
450 | object SelectKeyAction: TAction
451 | Caption = '...'
452 | OnExecute = SelectKeyActionExecute
453 | end
454 | object SelectPrivateKeyAction: TAction
455 | Caption = '...'
456 | OnExecute = SelectPrivateKeyActionExecute
457 | end
458 | end
459 | object SelectCrtDialog: TOpenDialog
460 | left = 528
461 | top = 520
462 | end
463 | object SelectKeyDialog: TOpenDialog
464 | left = 560
465 | top = 520
466 | end
467 | object SelectPrivateKeyDialog: TOpenDialog
468 | left = 592
469 | top = 520
470 | end
471 | end
472 |
--------------------------------------------------------------------------------
/Lazarus/backup/unit2.pas:
--------------------------------------------------------------------------------
1 | unit Unit2;
2 |
3 | {$mode objfpc}{$H+}
4 |
5 | interface
6 |
7 | uses
8 | Classes, SysUtils, Forms, Controls, Graphics, Dialogs, StdCtrls, ComCtrls,
9 | Menus, ActnList, StdActns;
10 |
11 | type
12 |
13 | { TNewProxyServerForm }
14 |
15 | TNewProxyServerForm = class(TForm)
16 | CrtInput: TEdit;
17 | CrtLabel: TLabel;
18 | ServerNameInput: TEdit;
19 | KcpPwdInput: TEdit;
20 | KcpPwdLabel: TLabel;
21 | KeyInput: TEdit;
22 | KeyLabel: TLabel;
23 | Label15: TLabel;
24 | Label4: TLabel;
25 | PageControl1: TPageControl;
26 | ProxyTypeComboBox: TComboBox;
27 | SelectCrtAction: TAction;
28 | SelectCrtBtn: TButton;
29 | SelectKeyAction: TAction;
30 | SelectKeyBtn: TButton;
31 | SelectPrivateKeyAction: TAction;
32 | ActionList1: TActionList;
33 | ConfirmBtn: TButton;
34 | CancelBtn: TButton;
35 | GroupBox4: TGroupBox;
36 | ListView1: TListView;
37 | AddMapping: TMenuItem;
38 | ModifyMapping: TMenuItem;
39 | DelMapping: TMenuItem;
40 | SelectCrtDialog: TOpenDialog;
41 | SelectKeyDialog: TOpenDialog;
42 | SelectPrivateKeyBtn: TButton;
43 | SelectPrivateKeyDialog: TOpenDialog;
44 | PopupMenu1: TPopupMenu;
45 | LocalProtocolComboBox: TComboBox;
46 | DnsInput: TEdit;
47 | LocalPort: TEdit;
48 | Label13: TLabel;
49 | Label14: TLabel;
50 | LocalIp: TEdit;
51 | Label12: TLabel;
52 | SshKeyInput: TEdit;
53 | SshKeyLabel: TLabel;
54 | SshPwdInput: TEdit;
55 | SshPwdLabel: TLabel;
56 | SshUserNameInput: TEdit;
57 | SshUserNameLabel: TLabel;
58 | TlsPage: TTabSheet;
59 | SSHPage: TTabSheet;
60 | KcpPage: TTabSheet;
61 | TTLInput: TEdit;
62 | GroupBox2: TGroupBox;
63 | GroupBox3: TGroupBox;
64 | Label10: TLabel;
65 | Label11: TLabel;
66 | ServerProtocolComboBox: TComboBox;
67 | IpInput: TEdit;
68 | PortInput: TEdit;
69 | GroupBox1: TGroupBox;
70 | Label1: TLabel;
71 | Label2: TLabel;
72 | Label3: TLabel;
73 | procedure AddMappingClick(Sender: TObject);
74 | procedure DelMappingClick(Sender: TObject);
75 | procedure LocalProtocolComboBoxChange(Sender: TObject);
76 | procedure ModifyMappingClick(Sender: TObject);
77 | procedure ProxyTypeComboBoxChange(Sender: TObject);
78 | procedure SelectCrtActionExecute(Sender: TObject);
79 | procedure SelectCrtBtnClick(Sender: TObject);
80 | procedure CancelBtnClick(Sender: TObject);
81 | procedure ConfirmBtnClick(Sender: TObject);
82 | procedure SelectKeyActionExecute(Sender: TObject);
83 | procedure SelectPrivateKeyActionExecute(Sender: TObject);
84 | procedure ServerProtocolComboBoxChange(Sender: TObject);
85 | private
86 |
87 | public
88 |
89 | end;
90 |
91 | var
92 | NewProxyServerForm: TNewProxyServerForm;
93 |
94 | implementation
95 |
96 | {$R *.lfm}
97 |
98 | { TNewProxyServerForm }
99 |
100 | procedure TNewProxyServerForm.ConfirmBtnClick(Sender: TObject);
101 | begin
102 |
103 | end;
104 |
105 | procedure TNewProxyServerForm.SelectKeyActionExecute(Sender: TObject);
106 | begin
107 |
108 | end;
109 |
110 | procedure TNewProxyServerForm.SelectPrivateKeyActionExecute(Sender: TObject);
111 | begin
112 |
113 | end;
114 |
115 | procedure TNewProxyServerForm.ServerProtocolComboBoxChange(Sender: TObject);
116 | begin
117 |
118 | end;
119 |
120 | procedure TNewProxyServerForm.CancelBtnClick(Sender: TObject);
121 | begin
122 |
123 | end;
124 |
125 | procedure TNewProxyServerForm.SelectCrtBtnClick(Sender: TObject);
126 | begin
127 |
128 | end;
129 |
130 | procedure TNewProxyServerForm.SelectCrtActionExecute(Sender: TObject);
131 | begin
132 |
133 | end;
134 |
135 | procedure TNewProxyServerForm.ProxyTypeComboBoxChange(Sender: TObject);
136 | begin
137 |
138 | end;
139 |
140 | procedure TNewProxyServerForm.LocalProtocolComboBoxChange(Sender: TObject);
141 | begin
142 |
143 | end;
144 |
145 | procedure TNewProxyServerForm.ModifyMappingClick(Sender: TObject);
146 | begin
147 |
148 | end;
149 |
150 | procedure TNewProxyServerForm.AddMappingClick(Sender: TObject);
151 | begin
152 |
153 | end;
154 |
155 | procedure TNewProxyServerForm.DelMappingClick(Sender: TObject);
156 | begin
157 |
158 | end;
159 |
160 | end.
161 |
162 |
--------------------------------------------------------------------------------
/Lazarus/backup/unit3.lfm:
--------------------------------------------------------------------------------
1 | object AddMappingForm: TAddMappingForm
2 | Left = 403
3 | Height = 218
4 | Top = 504
5 | Width = 368
6 | Caption = '新增穿透映射'
7 | ClientHeight = 218
8 | ClientWidth = 368
9 | DesignTimePPI = 120
10 | LCLVersion = '2.0.2.0'
11 | object Label1: TLabel
12 | Left = 80
13 | Height = 20
14 | Top = 32
15 | Width = 30
16 | Caption = '类型'
17 | ParentColor = False
18 | end
19 | object TypeComboBox: TComboBox
20 | Left = 160
21 | Height = 28
22 | Top = 24
23 | Width = 125
24 | ItemHeight = 20
25 | ItemIndex = 0
26 | Items.Strings = (
27 | 'tcp'
28 | 'udp'
29 | )
30 | OnChange = TypeComboBoxChange
31 | Style = csDropDownList
32 | TabOrder = 0
33 | Text = 'tcp'
34 | end
35 | object Label2: TLabel
36 | Left = 64
37 | Height = 20
38 | Top = 72
39 | Width = 60
40 | Caption = '本地端口'
41 | ParentColor = False
42 | end
43 | object LocalPort: TEdit
44 | Left = 160
45 | Height = 28
46 | Top = 64
47 | Width = 125
48 | TabOrder = 1
49 | end
50 | object Label3: TLabel
51 | Left = 64
52 | Height = 20
53 | Top = 120
54 | Width = 60
55 | Caption = '远程端口'
56 | ParentColor = False
57 | end
58 | object RemotePort: TEdit
59 | Left = 160
60 | Height = 28
61 | Top = 112
62 | Width = 125
63 | TabOrder = 2
64 | end
65 | object ConfirmBtn: TButton
66 | Left = 56
67 | Height = 31
68 | Top = 168
69 | Width = 94
70 | Caption = '确定'
71 | OnClick = ConfirmBtnClick
72 | TabOrder = 3
73 | end
74 | object CancelBtn: TButton
75 | Left = 191
76 | Height = 31
77 | Top = 168
78 | Width = 94
79 | Caption = '取消'
80 | OnClick = CancelBtnClick
81 | TabOrder = 4
82 | end
83 | end
84 |
--------------------------------------------------------------------------------
/Lazarus/backup/unit3.pas:
--------------------------------------------------------------------------------
1 | unit Unit3;
2 |
3 | {$mode objfpc}{$H+}
4 |
5 | interface
6 |
7 | uses
8 | Classes, SysUtils, Forms, Controls, Graphics, Dialogs, StdCtrls;
9 |
10 | type
11 |
12 | { TAddMappingForm }
13 |
14 | TAddMappingForm = class(TForm)
15 | ConfirmBtn: TButton;
16 | CancelBtn: TButton;
17 | TypeComboBox: TComboBox;
18 | RemotePort: TEdit;
19 | Label3: TLabel;
20 | LocalPort: TEdit;
21 | Label1: TLabel;
22 | Label2: TLabel;
23 | procedure CancelBtnClick(Sender: TObject);
24 | procedure TypeComboBoxChange(Sender: TObject);
25 | procedure ConfirmBtnClick(Sender: TObject);
26 | private
27 |
28 | public
29 |
30 | end;
31 |
32 | var
33 | AddMappingForm: TAddMappingForm;
34 |
35 | implementation
36 |
37 | {$R *.lfm}
38 |
39 | { TAddMappingForm }
40 |
41 | procedure TAddMappingForm.ConfirmBtnClick(Sender: TObject);
42 | begin
43 |
44 | end;
45 |
46 | procedure TAddMappingForm.CancelBtnClick(Sender: TObject);
47 | begin
48 |
49 | end;
50 |
51 | procedure TAddMappingForm.TypeComboBoxChange(Sender: TObject);
52 | begin
53 |
54 | end;
55 |
56 | end.
57 |
58 |
--------------------------------------------------------------------------------
/Lazarus/defaultRes_windows.syso:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yangjinhe/goproxy-gui/b39c69d72aafc54d28a6930c6f7c1b5d56169e8e/Lazarus/defaultRes_windows.syso
--------------------------------------------------------------------------------
/Lazarus/icon/cloud_computing_128px_1217935_easyicon.net.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yangjinhe/goproxy-gui/b39c69d72aafc54d28a6930c6f7c1b5d56169e8e/Lazarus/icon/cloud_computing_128px_1217935_easyicon.net.ico
--------------------------------------------------------------------------------
/Lazarus/icon/help_128px_1117612_easyicon.net.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yangjinhe/goproxy-gui/b39c69d72aafc54d28a6930c6f7c1b5d56169e8e/Lazarus/icon/help_128px_1117612_easyicon.net.ico
--------------------------------------------------------------------------------
/Lazarus/icon/main.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yangjinhe/goproxy-gui/b39c69d72aafc54d28a6930c6f7c1b5d56169e8e/Lazarus/icon/main.ico
--------------------------------------------------------------------------------
/Lazarus/icon/rocket_128px_1231680_easyicon.net.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yangjinhe/goproxy-gui/b39c69d72aafc54d28a6930c6f7c1b5d56169e8e/Lazarus/icon/rocket_128px_1231680_easyicon.net.ico
--------------------------------------------------------------------------------
/Lazarus/icon/rocket_625px_1231680_easyicon.net.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yangjinhe/goproxy-gui/b39c69d72aafc54d28a6930c6f7c1b5d56169e8e/Lazarus/icon/rocket_625px_1231680_easyicon.net.png
--------------------------------------------------------------------------------
/Lazarus/icon/server_128px_1217869_easyicon.net.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yangjinhe/goproxy-gui/b39c69d72aafc54d28a6930c6f7c1b5d56169e8e/Lazarus/icon/server_128px_1217869_easyicon.net.ico
--------------------------------------------------------------------------------
/Lazarus/icon/settings_128px_1217844_easyicon.net.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yangjinhe/goproxy-gui/b39c69d72aafc54d28a6930c6f7c1b5d56169e8e/Lazarus/icon/settings_128px_1217844_easyicon.net.ico
--------------------------------------------------------------------------------
/Lazarus/lib/x86_64-win64/project1.compiled:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/Lazarus/lib/x86_64-win64/project1.o:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yangjinhe/goproxy-gui/b39c69d72aafc54d28a6930c6f7c1b5d56169e8e/Lazarus/lib/x86_64-win64/project1.o
--------------------------------------------------------------------------------
/Lazarus/lib/x86_64-win64/project1.obj:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yangjinhe/goproxy-gui/b39c69d72aafc54d28a6930c6f7c1b5d56169e8e/Lazarus/lib/x86_64-win64/project1.obj
--------------------------------------------------------------------------------
/Lazarus/lib/x86_64-win64/project1.res:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yangjinhe/goproxy-gui/b39c69d72aafc54d28a6930c6f7c1b5d56169e8e/Lazarus/lib/x86_64-win64/project1.res
--------------------------------------------------------------------------------
/Lazarus/lib/x86_64-win64/unit1.o:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yangjinhe/goproxy-gui/b39c69d72aafc54d28a6930c6f7c1b5d56169e8e/Lazarus/lib/x86_64-win64/unit1.o
--------------------------------------------------------------------------------
/Lazarus/lib/x86_64-win64/unit1.ppu:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yangjinhe/goproxy-gui/b39c69d72aafc54d28a6930c6f7c1b5d56169e8e/Lazarus/lib/x86_64-win64/unit1.ppu
--------------------------------------------------------------------------------
/Lazarus/lib/x86_64-win64/unit2.lfm:
--------------------------------------------------------------------------------
1 | object NewProxyServerForm: TNewProxyServerForm
2 | Left = 575
3 | Height = 561
4 | Top = 227
5 | Width = 661
6 | Caption = '新增服务'
7 | ClientHeight = 561
8 | ClientWidth = 661
9 | DesignTimePPI = 120
10 | LCLVersion = '2.0.2.0'
11 | object GroupBox1: TGroupBox
12 | Left = 16
13 | Height = 184
14 | Top = 48
15 | Width = 640
16 | Caption = '服务器配置'
17 | ClientHeight = 159
18 | ClientWidth = 636
19 | TabOrder = 0
20 | object Label1: TLabel
21 | Left = 16
22 | Height = 20
23 | Top = 16
24 | Width = 30
25 | Caption = '地址'
26 | ParentColor = False
27 | end
28 | object IpInput: TEdit
29 | Left = 72
30 | Height = 28
31 | Top = 8
32 | Width = 200
33 | TabOrder = 0
34 | end
35 | object Label2: TLabel
36 | Left = 296
37 | Height = 20
38 | Top = 16
39 | Width = 30
40 | Caption = '端口'
41 | ParentColor = False
42 | end
43 | object PortInput: TEdit
44 | Left = 352
45 | Height = 28
46 | Top = 8
47 | Width = 100
48 | TabOrder = 1
49 | end
50 | object Label3: TLabel
51 | Left = 12
52 | Height = 20
53 | Top = 56
54 | Width = 34
55 | Caption = ' 协议'
56 | ParentColor = False
57 | end
58 | object ServerProtocolComboBox: TComboBox
59 | Left = 72
60 | Height = 28
61 | Top = 48
62 | Width = 125
63 | ItemHeight = 20
64 | ItemIndex = 0
65 | Items.Strings = (
66 | 'tcp'
67 | 'tls'
68 | 'kcp'
69 | 'ssh'
70 | 'ws'
71 | 'wss'
72 | )
73 | OnChange = ServerProtocolComboBoxChange
74 | Style = csDropDownList
75 | TabOrder = 2
76 | Text = 'tcp'
77 | end
78 | end
79 | object GroupBox2: TGroupBox
80 | Left = 16
81 | Height = 120
82 | Top = 232
83 | Width = 640
84 | Caption = '本地配置'
85 | ClientHeight = 95
86 | ClientWidth = 636
87 | TabOrder = 1
88 | object Label12: TLabel
89 | Left = 12
90 | Height = 20
91 | Top = 8
92 | Width = 30
93 | Caption = '地址'
94 | ParentColor = False
95 | end
96 | object LocalIp: TEdit
97 | Left = 72
98 | Height = 28
99 | Top = 0
100 | Width = 200
101 | TabOrder = 0
102 | Text = '127.0.0.1'
103 | end
104 | object Label13: TLabel
105 | Left = 320
106 | Height = 20
107 | Top = 8
108 | Width = 30
109 | Caption = '端口'
110 | ParentColor = False
111 | end
112 | object LocalPort: TEdit
113 | Left = 368
114 | Height = 28
115 | Top = 0
116 | Width = 100
117 | TabOrder = 1
118 | Text = '1080'
119 | end
120 | object Label14: TLabel
121 | Left = 12
122 | Height = 20
123 | Top = 48
124 | Width = 30
125 | Caption = '协议'
126 | ParentColor = False
127 | end
128 | object LocalProtocolComboBox: TComboBox
129 | Left = 72
130 | Height = 28
131 | Top = 40
132 | Width = 125
133 | ItemHeight = 20
134 | ItemIndex = 1
135 | Items.Strings = (
136 | 'tls'
137 | 'tcp'
138 | 'kcp'
139 | )
140 | OnChange = LocalProtocolComboBoxChange
141 | Style = csDropDownList
142 | TabOrder = 2
143 | Text = 'tcp'
144 | end
145 | end
146 | object GroupBox3: TGroupBox
147 | Left = 16
148 | Height = 88
149 | Top = 352
150 | Width = 640
151 | Caption = '其他配置'
152 | ClientHeight = 63
153 | ClientWidth = 636
154 | TabOrder = 2
155 | object Label10: TLabel
156 | Left = 12
157 | Height = 20
158 | Top = 17
159 | Width = 32
160 | Caption = 'DNS'
161 | ParentColor = False
162 | end
163 | object DnsInput: TEdit
164 | Left = 64
165 | Height = 28
166 | Top = 9
167 | Width = 184
168 | TabOrder = 0
169 | Text = '8.8.8.8:53'
170 | end
171 | object Label11: TLabel
172 | Left = 272
173 | Height = 20
174 | Top = 17
175 | Width = 51
176 | Caption = 'TTL(秒)'
177 | ParentColor = False
178 | end
179 | object TTLInput: TEdit
180 | Left = 344
181 | Height = 28
182 | Top = 9
183 | Width = 100
184 | TabOrder = 1
185 | Text = '600'
186 | end
187 | end
188 | object GroupBox4: TGroupBox
189 | Left = 16
190 | Height = 264
191 | Top = 232
192 | Width = 640
193 | Caption = '穿透映射'
194 | ClientHeight = 239
195 | ClientWidth = 636
196 | TabOrder = 3
197 | Visible = False
198 | object ListView1: TListView
199 | Left = 0
200 | Height = 232
201 | Top = 0
202 | Width = 632
203 | Columns = <
204 | item
205 | Caption = '类型'
206 | Width = 100
207 | end
208 | item
209 | Caption = '远程端口'
210 | Width = 100
211 | end
212 | item
213 | Caption = '本地端口'
214 | Width = 100
215 | end>
216 | PopupMenu = PopupMenu1
217 | RowSelect = True
218 | TabOrder = 0
219 | ViewStyle = vsReport
220 | end
221 | end
222 | object ConfirmBtn: TButton
223 | Left = 176
224 | Height = 31
225 | Top = 520
226 | Width = 94
227 | Caption = '确定'
228 | OnClick = ConfirmBtnClick
229 | TabOrder = 4
230 | end
231 | object CancelBtn: TButton
232 | Left = 368
233 | Height = 31
234 | Top = 520
235 | Width = 94
236 | Caption = '取消'
237 | OnClick = CancelBtnClick
238 | TabOrder = 5
239 | end
240 | object Label15: TLabel
241 | Left = 16
242 | Height = 20
243 | Top = 16
244 | Width = 60
245 | Caption = '代理类型'
246 | ParentColor = False
247 | end
248 | object ProxyTypeComboBox: TComboBox
249 | Left = 88
250 | Height = 28
251 | Top = 8
252 | Width = 125
253 | ItemHeight = 20
254 | ItemIndex = 1
255 | Items.Strings = (
256 | 'HTTP'
257 | 'SPS'
258 | 'TCP'
259 | 'UDP'
260 | 'SOCKS'
261 | '穿透'
262 | )
263 | OnChange = ProxyTypeComboBoxChange
264 | Style = csDropDownList
265 | TabOrder = 6
266 | Text = 'SPS'
267 | end
268 | object PageControl1: TPageControl
269 | Left = 24
270 | Height = 56
271 | Top = 160
272 | Width = 600
273 | ActivePage = KcpPage
274 | ShowTabs = False
275 | TabIndex = 2
276 | TabOrder = 7
277 | Visible = False
278 | object TlsPage: TTabSheet
279 | Caption = 'TlsPage'
280 | ClientHeight = 48
281 | ClientWidth = 592
282 | object CrtLabel: TLabel
283 | Left = 8
284 | Height = 20
285 | Top = 16
286 | Width = 30
287 | Caption = '证书'
288 | ParentColor = False
289 | end
290 | object CrtInput: TEdit
291 | Left = 48
292 | Height = 28
293 | Top = 8
294 | Width = 192
295 | ReadOnly = True
296 | TabOrder = 0
297 | end
298 | object KeyLabel: TLabel
299 | Left = 304
300 | Height = 20
301 | Top = 16
302 | Width = 30
303 | Caption = '密钥'
304 | ParentColor = False
305 | end
306 | object KeyInput: TEdit
307 | Left = 336
308 | Height = 28
309 | Top = 8
310 | Width = 196
311 | ReadOnly = True
312 | TabOrder = 1
313 | end
314 | object SelectCrtBtn: TButton
315 | Left = 240
316 | Height = 28
317 | Top = 8
318 | Width = 24
319 | Action = SelectCrtAction
320 | OnClick = SelectCrtBtnClick
321 | TabOrder = 2
322 | end
323 | object SelectKeyBtn: TButton
324 | Left = 528
325 | Height = 28
326 | Top = 8
327 | Width = 24
328 | Action = SelectKeyAction
329 | TabOrder = 3
330 | end
331 | end
332 | object SSHPage: TTabSheet
333 | Caption = 'SSHPage'
334 | ClientHeight = 48
335 | ClientWidth = 592
336 | object SshUserNameLabel: TLabel
337 | Left = 0
338 | Height = 20
339 | Top = 16
340 | Width = 45
341 | Caption = '用户名'
342 | ParentColor = False
343 | end
344 | object SshUserNameInput: TEdit
345 | Left = 71
346 | Height = 28
347 | Top = 8
348 | Width = 100
349 | TabOrder = 0
350 | end
351 | object SshPwdLabel: TLabel
352 | Left = 223
353 | Height = 20
354 | Top = 16
355 | Width = 30
356 | Caption = '密码'
357 | ParentColor = False
358 | end
359 | object SshPwdInput: TEdit
360 | Left = 275
361 | Height = 28
362 | Top = 8
363 | Width = 100
364 | TabOrder = 1
365 | end
366 | object SshKeyLabel: TLabel
367 | Left = 431
368 | Height = 20
369 | Top = 16
370 | Width = 30
371 | Caption = '私钥'
372 | ParentColor = False
373 | end
374 | object SshKeyInput: TEdit
375 | Left = 464
376 | Height = 28
377 | Top = 8
378 | Width = 100
379 | ReadOnly = True
380 | TabOrder = 2
381 | end
382 | object SelectPrivateKeyBtn: TButton
383 | Left = 559
384 | Height = 28
385 | Top = 8
386 | Width = 24
387 | Action = SelectPrivateKeyAction
388 | TabOrder = 3
389 | end
390 | end
391 | object KcpPage: TTabSheet
392 | Caption = 'KcpPage'
393 | ClientHeight = 48
394 | ClientWidth = 592
395 | object KcpPwdLabel: TLabel
396 | Left = 8
397 | Height = 20
398 | Top = 16
399 | Width = 30
400 | Caption = '密钥'
401 | ParentColor = False
402 | end
403 | object KcpPwdInput: TEdit
404 | Left = 64
405 | Height = 28
406 | Top = 8
407 | Width = 100
408 | TabOrder = 0
409 | end
410 | end
411 | end
412 | object Label4: TLabel
413 | Left = 288
414 | Height = 20
415 | Top = 16
416 | Width = 30
417 | Caption = '名称'
418 | ParentColor = False
419 | end
420 | object ServerNameInput: TEdit
421 | Left = 360
422 | Height = 28
423 | Top = 8
424 | Width = 200
425 | TabOrder = 8
426 | end
427 | object PopupMenu1: TPopupMenu
428 | left = 496
429 | top = 520
430 | object AddMapping: TMenuItem
431 | Caption = '新增'
432 | OnClick = AddMappingClick
433 | end
434 | object ModifyMapping: TMenuItem
435 | Caption = '修改'
436 | OnClick = ModifyMappingClick
437 | end
438 | object DelMapping: TMenuItem
439 | Caption = '删除'
440 | OnClick = DelMappingClick
441 | end
442 | end
443 | object ActionList1: TActionList
444 | left = 624
445 | top = 520
446 | object SelectCrtAction: TAction
447 | Caption = '...'
448 | OnExecute = SelectCrtActionExecute
449 | end
450 | object SelectKeyAction: TAction
451 | Caption = '...'
452 | OnExecute = SelectKeyActionExecute
453 | end
454 | object SelectPrivateKeyAction: TAction
455 | Caption = '...'
456 | OnExecute = SelectPrivateKeyActionExecute
457 | end
458 | end
459 | object SelectCrtDialog: TOpenDialog
460 | left = 528
461 | top = 520
462 | end
463 | object SelectKeyDialog: TOpenDialog
464 | left = 560
465 | top = 520
466 | end
467 | object SelectPrivateKeyDialog: TOpenDialog
468 | left = 592
469 | top = 520
470 | end
471 | end
472 |
--------------------------------------------------------------------------------
/Lazarus/lib/x86_64-win64/unit2.o:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yangjinhe/goproxy-gui/b39c69d72aafc54d28a6930c6f7c1b5d56169e8e/Lazarus/lib/x86_64-win64/unit2.o
--------------------------------------------------------------------------------
/Lazarus/lib/x86_64-win64/unit2.ppu:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yangjinhe/goproxy-gui/b39c69d72aafc54d28a6930c6f7c1b5d56169e8e/Lazarus/lib/x86_64-win64/unit2.ppu
--------------------------------------------------------------------------------
/Lazarus/lib/x86_64-win64/unit3.lfm:
--------------------------------------------------------------------------------
1 | object AddMappingForm: TAddMappingForm
2 | Left = 750
3 | Height = 218
4 | Top = 373
5 | Width = 368
6 | Caption = '新增穿透映射'
7 | ClientHeight = 218
8 | ClientWidth = 368
9 | DesignTimePPI = 120
10 | LCLVersion = '2.0.2.0'
11 | object Label1: TLabel
12 | Left = 80
13 | Height = 20
14 | Top = 32
15 | Width = 30
16 | Caption = '类型'
17 | ParentColor = False
18 | end
19 | object TypeComboBox: TComboBox
20 | Left = 160
21 | Height = 28
22 | Top = 24
23 | Width = 125
24 | ItemHeight = 20
25 | ItemIndex = 0
26 | Items.Strings = (
27 | 'tcp'
28 | 'udp'
29 | )
30 | OnChange = TypeComboBoxChange
31 | Style = csDropDownList
32 | TabOrder = 0
33 | Text = 'tcp'
34 | end
35 | object Label2: TLabel
36 | Left = 64
37 | Height = 20
38 | Top = 72
39 | Width = 60
40 | Caption = '本地端口'
41 | ParentColor = False
42 | end
43 | object LocalPort: TEdit
44 | Left = 160
45 | Height = 28
46 | Top = 64
47 | Width = 125
48 | TabOrder = 1
49 | end
50 | object Label3: TLabel
51 | Left = 64
52 | Height = 20
53 | Top = 120
54 | Width = 60
55 | Caption = '远程端口'
56 | ParentColor = False
57 | end
58 | object RemotePort: TEdit
59 | Left = 160
60 | Height = 28
61 | Top = 112
62 | Width = 125
63 | TabOrder = 2
64 | end
65 | object ConfirmBtn: TButton
66 | Left = 56
67 | Height = 31
68 | Top = 168
69 | Width = 94
70 | Caption = '确定'
71 | OnClick = ConfirmBtnClick
72 | TabOrder = 3
73 | end
74 | object CancelBtn: TButton
75 | Left = 191
76 | Height = 31
77 | Top = 168
78 | Width = 94
79 | Caption = '取消'
80 | OnClick = CancelBtnClick
81 | TabOrder = 4
82 | end
83 | end
84 |
--------------------------------------------------------------------------------
/Lazarus/lib/x86_64-win64/unit3.o:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yangjinhe/goproxy-gui/b39c69d72aafc54d28a6930c6f7c1b5d56169e8e/Lazarus/lib/x86_64-win64/unit3.o
--------------------------------------------------------------------------------
/Lazarus/lib/x86_64-win64/unit3.ppu:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yangjinhe/goproxy-gui/b39c69d72aafc54d28a6930c6f7c1b5d56169e8e/Lazarus/lib/x86_64-win64/unit3.ppu
--------------------------------------------------------------------------------
/Lazarus/main.go:
--------------------------------------------------------------------------------
1 | // 由res2go自动生成。
2 | package main
3 |
4 | import (
5 | "github.com/ying32/govcl/vcl"
6 | )
7 |
8 | func main() {
9 | vcl.Application.Initialize()
10 | vcl.Application.CreateForm(mainFormBytes, &MainForm)
11 | vcl.Application.CreateForm(newProxyServerFormBytes, &NewProxyServerForm)
12 | vcl.Application.CreateForm(addMappingFormBytes, &AddMappingForm)
13 | initDb()
14 | initListView()
15 | vcl.Application.Run()
16 | }
17 |
--------------------------------------------------------------------------------
/Lazarus/project1.lpi:
--------------------------------------------------------------------------------
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 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
--------------------------------------------------------------------------------
/Lazarus/project1.lpr:
--------------------------------------------------------------------------------
1 | program project1;
2 |
3 | {$mode objfpc}{$H+}
4 |
5 | uses
6 | {$IFDEF UNIX}{$IFDEF UseCThreads}
7 | cthreads,
8 | {$ENDIF}{$ENDIF}
9 | Interfaces, // this includes the LCL widgetset
10 | Forms, Unit1, Unit2, Unit3
11 | { you can add units after this };
12 |
13 | {$R *.res}
14 |
15 | begin
16 | RequireDerivedFormResource:=True;
17 | Application.Scaled:=True;
18 | Application.Initialize;
19 | Application.CreateForm(TMainForm, MainForm);
20 | Application.CreateForm(TNewProxyServerForm, NewProxyServerForm);
21 | Application.CreateForm(TAddMappingForm, AddMappingForm);
22 | Application.Run;
23 | end.
24 |
25 |
--------------------------------------------------------------------------------
/Lazarus/project1.lps:
--------------------------------------------------------------------------------
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 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
105 |
106 |
107 |
108 |
109 |
110 |
111 |
112 |
113 |
114 |
115 |
116 |
117 |
118 |
119 |
120 |
121 |
122 |
123 |
124 |
125 |
126 |
127 |
128 |
129 |
130 |
131 |
132 |
133 |
134 |
135 |
136 |
137 |
138 |
139 |
140 |
141 |
142 |
143 |
144 |
145 |
146 |
147 |
148 |
149 |
150 |
151 |
152 |
153 |
154 |
155 |
156 |
157 |
158 |
159 |
160 |
161 |
162 |
163 |
164 |
165 |
166 |
167 |
168 |
169 |
170 |
171 |
172 |
173 |
174 |
175 |
176 |
177 |
178 |
179 |
180 |
181 |
182 |
183 |
184 |
185 |
186 |
--------------------------------------------------------------------------------
/Lazarus/project1.res:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yangjinhe/goproxy-gui/b39c69d72aafc54d28a6930c6f7c1b5d56169e8e/Lazarus/project1.res
--------------------------------------------------------------------------------
/Lazarus/unit1.pas:
--------------------------------------------------------------------------------
1 | unit Unit1;
2 |
3 | {$mode objfpc}{$H+}
4 |
5 | interface
6 |
7 | uses
8 | Classes, SysUtils, Forms, Controls, Graphics, Dialogs, ComCtrls, Menus,
9 | ActnList, ExtCtrls, StdCtrls;
10 |
11 | type
12 |
13 | { TMainForm }
14 |
15 | TMainForm = class(TForm)
16 | GroupBox1: TGroupBox;
17 | GroupBox2: TGroupBox;
18 | GroupBox3: TGroupBox;
19 | ImageList1: TImageList;
20 | ListView1: TListView;
21 | Memo1: TMemo;
22 | Memo2: TMemo;
23 | AddServer: TMenuItem;
24 | ShowMainWindow: TMenuItem;
25 | ExitMainWindow: TMenuItem;
26 | TrayPopupMenu: TPopupMenu;
27 | SetActivityServer: TMenuItem;
28 | PingServer: TMenuItem;
29 | PopupMenu1: TPopupMenu;
30 | ToolBar1: TToolBar;
31 | ToolButton1: TToolButton;
32 | ToolButton2: TToolButton;
33 | SettingsBtn: TToolButton;
34 | ToolButton4: TToolButton;
35 | TrayIcon1: TTrayIcon;
36 | UpdateBtn: TToolButton;
37 | ToolButton6: TToolButton;
38 | HelpBtn: TToolButton;
39 | ToolButton8: TToolButton;
40 | procedure AddServerClick(Sender: TObject);
41 | procedure ExitMainWindowClick(Sender: TObject);
42 | procedure PingServerClick(Sender: TObject);
43 | procedure SetActivityServerClick(Sender: TObject);
44 | procedure SettingsBtnClick(Sender: TObject);
45 | procedure HelpBtnClick(Sender: TObject);
46 | procedure ShowMainWindowClick(Sender: TObject);
47 | procedure UpdateBtnClick(Sender: TObject);
48 | private
49 |
50 | public
51 |
52 | end;
53 |
54 | var
55 | MainForm: TMainForm;
56 |
57 | implementation
58 |
59 | {$R *.lfm}
60 |
61 | { TMainForm }
62 |
63 | procedure TMainForm.SettingsBtnClick(Sender: TObject);
64 | begin
65 |
66 | end;
67 |
68 | procedure TMainForm.HelpBtnClick(Sender: TObject);
69 | begin
70 |
71 | end;
72 |
73 | procedure TMainForm.ShowMainWindowClick(Sender: TObject);
74 | begin
75 |
76 | end;
77 |
78 | procedure TMainForm.UpdateBtnClick(Sender: TObject);
79 | begin
80 |
81 | end;
82 |
83 | procedure TMainForm.AddServerClick(Sender: TObject);
84 | begin
85 |
86 | end;
87 |
88 | procedure TMainForm.ExitMainWindowClick(Sender: TObject);
89 | begin
90 |
91 | end;
92 |
93 | procedure TMainForm.PingServerClick(Sender: TObject);
94 | begin
95 |
96 | end;
97 |
98 | procedure TMainForm.SetActivityServerClick(Sender: TObject);
99 | begin
100 |
101 | end;
102 |
103 | end.
104 |
105 |
--------------------------------------------------------------------------------
/Lazarus/unit2.lfm:
--------------------------------------------------------------------------------
1 | object NewProxyServerForm: TNewProxyServerForm
2 | Left = 575
3 | Height = 561
4 | Top = 227
5 | Width = 661
6 | Caption = '新增服务'
7 | ClientHeight = 561
8 | ClientWidth = 661
9 | DesignTimePPI = 120
10 | LCLVersion = '2.0.2.0'
11 | object GroupBox1: TGroupBox
12 | Left = 16
13 | Height = 184
14 | Top = 48
15 | Width = 640
16 | Caption = '服务器配置'
17 | ClientHeight = 159
18 | ClientWidth = 636
19 | TabOrder = 0
20 | object Label1: TLabel
21 | Left = 16
22 | Height = 20
23 | Top = 16
24 | Width = 30
25 | Caption = '地址'
26 | ParentColor = False
27 | end
28 | object IpInput: TEdit
29 | Left = 72
30 | Height = 28
31 | Top = 8
32 | Width = 200
33 | TabOrder = 0
34 | end
35 | object Label2: TLabel
36 | Left = 296
37 | Height = 20
38 | Top = 16
39 | Width = 30
40 | Caption = '端口'
41 | ParentColor = False
42 | end
43 | object PortInput: TEdit
44 | Left = 352
45 | Height = 28
46 | Top = 8
47 | Width = 100
48 | TabOrder = 1
49 | end
50 | object Label3: TLabel
51 | Left = 12
52 | Height = 20
53 | Top = 56
54 | Width = 34
55 | Caption = ' 协议'
56 | ParentColor = False
57 | end
58 | object ServerProtocolComboBox: TComboBox
59 | Left = 72
60 | Height = 28
61 | Top = 48
62 | Width = 125
63 | ItemHeight = 20
64 | ItemIndex = 0
65 | Items.Strings = (
66 | 'tcp'
67 | 'tls'
68 | 'kcp'
69 | 'ssh'
70 | 'ws'
71 | 'wss'
72 | )
73 | OnChange = ServerProtocolComboBoxChange
74 | Style = csDropDownList
75 | TabOrder = 2
76 | Text = 'tcp'
77 | end
78 | end
79 | object GroupBox2: TGroupBox
80 | Left = 16
81 | Height = 120
82 | Top = 232
83 | Width = 640
84 | Caption = '本地配置'
85 | ClientHeight = 95
86 | ClientWidth = 636
87 | TabOrder = 1
88 | object Label12: TLabel
89 | Left = 12
90 | Height = 20
91 | Top = 8
92 | Width = 30
93 | Caption = '地址'
94 | ParentColor = False
95 | end
96 | object LocalIp: TEdit
97 | Left = 72
98 | Height = 28
99 | Top = 0
100 | Width = 200
101 | TabOrder = 0
102 | Text = '127.0.0.1'
103 | end
104 | object Label13: TLabel
105 | Left = 320
106 | Height = 20
107 | Top = 8
108 | Width = 30
109 | Caption = '端口'
110 | ParentColor = False
111 | end
112 | object LocalPort: TEdit
113 | Left = 368
114 | Height = 28
115 | Top = 0
116 | Width = 100
117 | TabOrder = 1
118 | Text = '1080'
119 | end
120 | object Label14: TLabel
121 | Left = 12
122 | Height = 20
123 | Top = 48
124 | Width = 30
125 | Caption = '协议'
126 | ParentColor = False
127 | end
128 | object LocalProtocolComboBox: TComboBox
129 | Left = 72
130 | Height = 28
131 | Top = 40
132 | Width = 125
133 | ItemHeight = 20
134 | ItemIndex = 1
135 | Items.Strings = (
136 | 'tls'
137 | 'tcp'
138 | 'kcp'
139 | )
140 | OnChange = LocalProtocolComboBoxChange
141 | Style = csDropDownList
142 | TabOrder = 2
143 | Text = 'tcp'
144 | end
145 | end
146 | object GroupBox3: TGroupBox
147 | Left = 16
148 | Height = 88
149 | Top = 352
150 | Width = 640
151 | Caption = '其他配置'
152 | ClientHeight = 63
153 | ClientWidth = 636
154 | TabOrder = 2
155 | object Label10: TLabel
156 | Left = 12
157 | Height = 20
158 | Top = 17
159 | Width = 32
160 | Caption = 'DNS'
161 | ParentColor = False
162 | end
163 | object DnsInput: TEdit
164 | Left = 64
165 | Height = 28
166 | Top = 9
167 | Width = 184
168 | TabOrder = 0
169 | Text = '8.8.8.8:53'
170 | end
171 | object Label11: TLabel
172 | Left = 272
173 | Height = 20
174 | Top = 17
175 | Width = 51
176 | Caption = 'TTL(秒)'
177 | ParentColor = False
178 | end
179 | object TTLInput: TEdit
180 | Left = 344
181 | Height = 28
182 | Top = 9
183 | Width = 100
184 | TabOrder = 1
185 | Text = '600'
186 | end
187 | end
188 | object GroupBox4: TGroupBox
189 | Left = 16
190 | Height = 264
191 | Top = 232
192 | Width = 640
193 | Caption = '穿透映射'
194 | ClientHeight = 239
195 | ClientWidth = 636
196 | TabOrder = 3
197 | Visible = False
198 | object ListView1: TListView
199 | Left = 0
200 | Height = 232
201 | Top = 0
202 | Width = 632
203 | Columns = <
204 | item
205 | Caption = '类型'
206 | Width = 100
207 | end
208 | item
209 | Caption = '远程端口'
210 | Width = 100
211 | end
212 | item
213 | Caption = '本地端口'
214 | Width = 100
215 | end>
216 | PopupMenu = PopupMenu1
217 | RowSelect = True
218 | TabOrder = 0
219 | ViewStyle = vsReport
220 | end
221 | end
222 | object ConfirmBtn: TButton
223 | Left = 176
224 | Height = 31
225 | Top = 520
226 | Width = 94
227 | Caption = '确定'
228 | OnClick = ConfirmBtnClick
229 | TabOrder = 4
230 | end
231 | object CancelBtn: TButton
232 | Left = 368
233 | Height = 31
234 | Top = 520
235 | Width = 94
236 | Caption = '取消'
237 | OnClick = CancelBtnClick
238 | TabOrder = 5
239 | end
240 | object Label15: TLabel
241 | Left = 16
242 | Height = 20
243 | Top = 16
244 | Width = 60
245 | Caption = '代理类型'
246 | ParentColor = False
247 | end
248 | object ProxyTypeComboBox: TComboBox
249 | Left = 88
250 | Height = 28
251 | Top = 8
252 | Width = 125
253 | ItemHeight = 20
254 | ItemIndex = 1
255 | Items.Strings = (
256 | 'HTTP'
257 | 'SPS'
258 | 'TCP'
259 | 'UDP'
260 | 'SOCKS'
261 | '穿透'
262 | )
263 | OnChange = ProxyTypeComboBoxChange
264 | Style = csDropDownList
265 | TabOrder = 6
266 | Text = 'SPS'
267 | end
268 | object PageControl1: TPageControl
269 | Left = 24
270 | Height = 56
271 | Top = 160
272 | Width = 600
273 | ActivePage = KcpPage
274 | ShowTabs = False
275 | TabIndex = 2
276 | TabOrder = 7
277 | Visible = False
278 | object TlsPage: TTabSheet
279 | Caption = 'TlsPage'
280 | ClientHeight = 48
281 | ClientWidth = 592
282 | object CrtLabel: TLabel
283 | Left = 8
284 | Height = 20
285 | Top = 16
286 | Width = 30
287 | Caption = '证书'
288 | ParentColor = False
289 | end
290 | object CrtInput: TEdit
291 | Left = 48
292 | Height = 28
293 | Top = 8
294 | Width = 192
295 | ReadOnly = True
296 | TabOrder = 0
297 | end
298 | object KeyLabel: TLabel
299 | Left = 304
300 | Height = 20
301 | Top = 16
302 | Width = 30
303 | Caption = '密钥'
304 | ParentColor = False
305 | end
306 | object KeyInput: TEdit
307 | Left = 336
308 | Height = 28
309 | Top = 8
310 | Width = 196
311 | ReadOnly = True
312 | TabOrder = 1
313 | end
314 | object SelectCrtBtn: TButton
315 | Left = 240
316 | Height = 28
317 | Top = 8
318 | Width = 24
319 | Action = SelectCrtAction
320 | OnClick = SelectCrtBtnClick
321 | TabOrder = 2
322 | end
323 | object SelectKeyBtn: TButton
324 | Left = 528
325 | Height = 28
326 | Top = 8
327 | Width = 24
328 | Action = SelectKeyAction
329 | TabOrder = 3
330 | end
331 | end
332 | object SSHPage: TTabSheet
333 | Caption = 'SSHPage'
334 | ClientHeight = 48
335 | ClientWidth = 592
336 | object SshUserNameLabel: TLabel
337 | Left = 0
338 | Height = 20
339 | Top = 16
340 | Width = 45
341 | Caption = '用户名'
342 | ParentColor = False
343 | end
344 | object SshUserNameInput: TEdit
345 | Left = 71
346 | Height = 28
347 | Top = 8
348 | Width = 100
349 | TabOrder = 0
350 | end
351 | object SshPwdLabel: TLabel
352 | Left = 223
353 | Height = 20
354 | Top = 16
355 | Width = 30
356 | Caption = '密码'
357 | ParentColor = False
358 | end
359 | object SshPwdInput: TEdit
360 | Left = 275
361 | Height = 28
362 | Top = 8
363 | Width = 100
364 | TabOrder = 1
365 | end
366 | object SshKeyLabel: TLabel
367 | Left = 431
368 | Height = 20
369 | Top = 16
370 | Width = 30
371 | Caption = '私钥'
372 | ParentColor = False
373 | end
374 | object SshKeyInput: TEdit
375 | Left = 464
376 | Height = 28
377 | Top = 8
378 | Width = 100
379 | ReadOnly = True
380 | TabOrder = 2
381 | end
382 | object SelectPrivateKeyBtn: TButton
383 | Left = 559
384 | Height = 28
385 | Top = 8
386 | Width = 24
387 | Action = SelectPrivateKeyAction
388 | TabOrder = 3
389 | end
390 | end
391 | object KcpPage: TTabSheet
392 | Caption = 'KcpPage'
393 | ClientHeight = 48
394 | ClientWidth = 592
395 | object KcpPwdLabel: TLabel
396 | Left = 8
397 | Height = 20
398 | Top = 16
399 | Width = 30
400 | Caption = '密钥'
401 | ParentColor = False
402 | end
403 | object KcpPwdInput: TEdit
404 | Left = 64
405 | Height = 28
406 | Top = 8
407 | Width = 100
408 | TabOrder = 0
409 | end
410 | end
411 | end
412 | object Label4: TLabel
413 | Left = 288
414 | Height = 20
415 | Top = 16
416 | Width = 30
417 | Caption = '名称'
418 | ParentColor = False
419 | end
420 | object ServerNameInput: TEdit
421 | Left = 360
422 | Height = 28
423 | Top = 8
424 | Width = 200
425 | TabOrder = 8
426 | end
427 | object PopupMenu1: TPopupMenu
428 | left = 496
429 | top = 520
430 | object AddMapping: TMenuItem
431 | Caption = '新增'
432 | OnClick = AddMappingClick
433 | end
434 | object ModifyMapping: TMenuItem
435 | Caption = '修改'
436 | OnClick = ModifyMappingClick
437 | end
438 | object DelMapping: TMenuItem
439 | Caption = '删除'
440 | OnClick = DelMappingClick
441 | end
442 | end
443 | object ActionList1: TActionList
444 | left = 624
445 | top = 520
446 | object SelectCrtAction: TAction
447 | Caption = '...'
448 | OnExecute = SelectCrtActionExecute
449 | end
450 | object SelectKeyAction: TAction
451 | Caption = '...'
452 | OnExecute = SelectKeyActionExecute
453 | end
454 | object SelectPrivateKeyAction: TAction
455 | Caption = '...'
456 | OnExecute = SelectPrivateKeyActionExecute
457 | end
458 | end
459 | object SelectCrtDialog: TOpenDialog
460 | left = 528
461 | top = 520
462 | end
463 | object SelectKeyDialog: TOpenDialog
464 | left = 560
465 | top = 520
466 | end
467 | object SelectPrivateKeyDialog: TOpenDialog
468 | left = 592
469 | top = 520
470 | end
471 | end
472 |
--------------------------------------------------------------------------------
/Lazarus/unit2.pas:
--------------------------------------------------------------------------------
1 | unit Unit2;
2 |
3 | {$mode objfpc}{$H+}
4 |
5 | interface
6 |
7 | uses
8 | Classes, SysUtils, Forms, Controls, Graphics, Dialogs, StdCtrls, ComCtrls,
9 | Menus, ActnList, StdActns;
10 |
11 | type
12 |
13 | { TNewProxyServerForm }
14 |
15 | TNewProxyServerForm = class(TForm)
16 | CrtInput: TEdit;
17 | CrtLabel: TLabel;
18 | ServerNameInput: TEdit;
19 | KcpPwdInput: TEdit;
20 | KcpPwdLabel: TLabel;
21 | KeyInput: TEdit;
22 | KeyLabel: TLabel;
23 | Label15: TLabel;
24 | Label4: TLabel;
25 | PageControl1: TPageControl;
26 | ProxyTypeComboBox: TComboBox;
27 | SelectCrtAction: TAction;
28 | SelectCrtBtn: TButton;
29 | SelectKeyAction: TAction;
30 | SelectKeyBtn: TButton;
31 | SelectPrivateKeyAction: TAction;
32 | ActionList1: TActionList;
33 | ConfirmBtn: TButton;
34 | CancelBtn: TButton;
35 | GroupBox4: TGroupBox;
36 | ListView1: TListView;
37 | AddMapping: TMenuItem;
38 | ModifyMapping: TMenuItem;
39 | DelMapping: TMenuItem;
40 | SelectCrtDialog: TOpenDialog;
41 | SelectKeyDialog: TOpenDialog;
42 | SelectPrivateKeyBtn: TButton;
43 | SelectPrivateKeyDialog: TOpenDialog;
44 | PopupMenu1: TPopupMenu;
45 | LocalProtocolComboBox: TComboBox;
46 | DnsInput: TEdit;
47 | LocalPort: TEdit;
48 | Label13: TLabel;
49 | Label14: TLabel;
50 | LocalIp: TEdit;
51 | Label12: TLabel;
52 | SshKeyInput: TEdit;
53 | SshKeyLabel: TLabel;
54 | SshPwdInput: TEdit;
55 | SshPwdLabel: TLabel;
56 | SshUserNameInput: TEdit;
57 | SshUserNameLabel: TLabel;
58 | TlsPage: TTabSheet;
59 | SSHPage: TTabSheet;
60 | KcpPage: TTabSheet;
61 | TTLInput: TEdit;
62 | GroupBox2: TGroupBox;
63 | GroupBox3: TGroupBox;
64 | Label10: TLabel;
65 | Label11: TLabel;
66 | ServerProtocolComboBox: TComboBox;
67 | IpInput: TEdit;
68 | PortInput: TEdit;
69 | GroupBox1: TGroupBox;
70 | Label1: TLabel;
71 | Label2: TLabel;
72 | Label3: TLabel;
73 | procedure AddMappingClick(Sender: TObject);
74 | procedure DelMappingClick(Sender: TObject);
75 | procedure LocalProtocolComboBoxChange(Sender: TObject);
76 | procedure ModifyMappingClick(Sender: TObject);
77 | procedure ProxyTypeComboBoxChange(Sender: TObject);
78 | procedure SelectCrtActionExecute(Sender: TObject);
79 | procedure SelectCrtBtnClick(Sender: TObject);
80 | procedure CancelBtnClick(Sender: TObject);
81 | procedure ConfirmBtnClick(Sender: TObject);
82 | procedure SelectKeyActionExecute(Sender: TObject);
83 | procedure SelectPrivateKeyActionExecute(Sender: TObject);
84 | procedure ServerProtocolComboBoxChange(Sender: TObject);
85 | private
86 |
87 | public
88 |
89 | end;
90 |
91 | var
92 | NewProxyServerForm: TNewProxyServerForm;
93 |
94 | implementation
95 |
96 | {$R *.lfm}
97 |
98 | { TNewProxyServerForm }
99 |
100 | procedure TNewProxyServerForm.ConfirmBtnClick(Sender: TObject);
101 | begin
102 |
103 | end;
104 |
105 | procedure TNewProxyServerForm.SelectKeyActionExecute(Sender: TObject);
106 | begin
107 |
108 | end;
109 |
110 | procedure TNewProxyServerForm.SelectPrivateKeyActionExecute(Sender: TObject);
111 | begin
112 |
113 | end;
114 |
115 | procedure TNewProxyServerForm.ServerProtocolComboBoxChange(Sender: TObject);
116 | begin
117 |
118 | end;
119 |
120 | procedure TNewProxyServerForm.CancelBtnClick(Sender: TObject);
121 | begin
122 |
123 | end;
124 |
125 | procedure TNewProxyServerForm.SelectCrtBtnClick(Sender: TObject);
126 | begin
127 |
128 | end;
129 |
130 | procedure TNewProxyServerForm.SelectCrtActionExecute(Sender: TObject);
131 | begin
132 |
133 | end;
134 |
135 | procedure TNewProxyServerForm.ProxyTypeComboBoxChange(Sender: TObject);
136 | begin
137 |
138 | end;
139 |
140 | procedure TNewProxyServerForm.LocalProtocolComboBoxChange(Sender: TObject);
141 | begin
142 |
143 | end;
144 |
145 | procedure TNewProxyServerForm.ModifyMappingClick(Sender: TObject);
146 | begin
147 |
148 | end;
149 |
150 | procedure TNewProxyServerForm.AddMappingClick(Sender: TObject);
151 | begin
152 |
153 | end;
154 |
155 | procedure TNewProxyServerForm.DelMappingClick(Sender: TObject);
156 | begin
157 |
158 | end;
159 |
160 | end.
161 |
162 |
--------------------------------------------------------------------------------
/Lazarus/unit3.lfm:
--------------------------------------------------------------------------------
1 | object AddMappingForm: TAddMappingForm
2 | Left = 750
3 | Height = 218
4 | Top = 373
5 | Width = 368
6 | Caption = '新增穿透映射'
7 | ClientHeight = 218
8 | ClientWidth = 368
9 | DesignTimePPI = 120
10 | LCLVersion = '2.0.2.0'
11 | object Label1: TLabel
12 | Left = 80
13 | Height = 20
14 | Top = 32
15 | Width = 30
16 | Caption = '类型'
17 | ParentColor = False
18 | end
19 | object TypeComboBox: TComboBox
20 | Left = 160
21 | Height = 28
22 | Top = 24
23 | Width = 125
24 | ItemHeight = 20
25 | ItemIndex = 0
26 | Items.Strings = (
27 | 'tcp'
28 | 'udp'
29 | )
30 | OnChange = TypeComboBoxChange
31 | Style = csDropDownList
32 | TabOrder = 0
33 | Text = 'tcp'
34 | end
35 | object Label2: TLabel
36 | Left = 64
37 | Height = 20
38 | Top = 72
39 | Width = 60
40 | Caption = '本地端口'
41 | ParentColor = False
42 | end
43 | object LocalPort: TEdit
44 | Left = 160
45 | Height = 28
46 | Top = 64
47 | Width = 125
48 | TabOrder = 1
49 | end
50 | object Label3: TLabel
51 | Left = 64
52 | Height = 20
53 | Top = 120
54 | Width = 60
55 | Caption = '远程端口'
56 | ParentColor = False
57 | end
58 | object RemotePort: TEdit
59 | Left = 160
60 | Height = 28
61 | Top = 112
62 | Width = 125
63 | TabOrder = 2
64 | end
65 | object ConfirmBtn: TButton
66 | Left = 56
67 | Height = 31
68 | Top = 168
69 | Width = 94
70 | Caption = '确定'
71 | OnClick = ConfirmBtnClick
72 | TabOrder = 3
73 | end
74 | object CancelBtn: TButton
75 | Left = 191
76 | Height = 31
77 | Top = 168
78 | Width = 94
79 | Caption = '取消'
80 | OnClick = CancelBtnClick
81 | TabOrder = 4
82 | end
83 | end
84 |
--------------------------------------------------------------------------------
/Lazarus/unit3.pas:
--------------------------------------------------------------------------------
1 | unit Unit3;
2 |
3 | {$mode objfpc}{$H+}
4 |
5 | interface
6 |
7 | uses
8 | Classes, SysUtils, Forms, Controls, Graphics, Dialogs, StdCtrls;
9 |
10 | type
11 |
12 | { TAddMappingForm }
13 |
14 | TAddMappingForm = class(TForm)
15 | ConfirmBtn: TButton;
16 | CancelBtn: TButton;
17 | TypeComboBox: TComboBox;
18 | RemotePort: TEdit;
19 | Label3: TLabel;
20 | LocalPort: TEdit;
21 | Label1: TLabel;
22 | Label2: TLabel;
23 | procedure CancelBtnClick(Sender: TObject);
24 | procedure TypeComboBoxChange(Sender: TObject);
25 | procedure ConfirmBtnClick(Sender: TObject);
26 | private
27 |
28 | public
29 |
30 | end;
31 |
32 | var
33 | AddMappingForm: TAddMappingForm;
34 |
35 | implementation
36 |
37 | {$R *.lfm}
38 |
39 | { TAddMappingForm }
40 |
41 | procedure TAddMappingForm.ConfirmBtnClick(Sender: TObject);
42 | begin
43 |
44 | end;
45 |
46 | procedure TAddMappingForm.CancelBtnClick(Sender: TObject);
47 | begin
48 |
49 | end;
50 |
51 | procedure TAddMappingForm.TypeComboBoxChange(Sender: TObject);
52 | begin
53 |
54 | end;
55 |
56 | end.
57 |
58 |
--------------------------------------------------------------------------------
/Lazarus/util.go:
--------------------------------------------------------------------------------
1 | package main
2 |
3 | import (
4 | "database/sql"
5 | "fmt"
6 | "github.com/ProtonMail/go-autostart"
7 | "github.com/getlantern/sysproxy"
8 | _ "github.com/mattn/go-sqlite3"
9 | "log"
10 | "os"
11 | "path/filepath"
12 | "strings"
13 | )
14 |
15 | var mainDbFileName = "goproxy.db"
16 |
17 | var proxyInfoSql = `CREATE TABLE "proxy_info" (
18 | "id" INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
19 | "name" TEXT(128),
20 | "proxyType" TEXT(10),
21 | "remoteIp" TEXT(20),
22 | "remotePort" TEXT(6),
23 | "remoteProtocol" TEXT(4),
24 | "localIp" TEXT(20),
25 | "localPort" TEXT(6),
26 | "localProtocol" TEXT(4),
27 | "crtLocation" TEXT(128),
28 | "keyLocation" TEXT(128),
29 | "sshUserName" TEXT(128),
30 | "sshPwd" TEXT(128),
31 | "sshPrivateKey" TEXT(128),
32 | "kcpPwd" TEXT(128),
33 | "dns" TEXT(20),
34 | "dnsTtl" TEXT(20)
35 | );`
36 | var proxyInfoIdxSql = `CREATE UNIQUE INDEX "idx_proxy_info_id"
37 | ON "proxy_info" (
38 | "id"
39 | );`
40 |
41 | var tunnelMappingSql = `CREATE TABLE "tunnel_mapping" (
42 | "id" INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
43 | "info_id" INTEGER,
44 | "type" TEXT(10),
45 | "localPort" TEXT(128),
46 | "remotePort" TEXT(128)
47 | );`
48 | var tunnelMappingIdxSql = `CREATE UNIQUE INDEX "idx_mapping_id"
49 | ON "tunnel_mapping" (
50 | "id"
51 | );`
52 |
53 | var insertProxyInfoSql = `insert into "proxy_info" ("name", "proxyType",
54 | "remoteIp", "remotePort", "remoteProtocol", "localIp", "localPort", "localProtocol",
55 | "crtLocation", "keyLocation", "sshUserName", "sshPwd", "sshPrivateKey", "kcpPwd",
56 | "dns", "dnsTtl") values (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)`
57 |
58 | var insertTunnelMappingSql = `insert into "tunnel_mapping" ("info_id", "protocol_type", "localPort", "remotePort") values (?, ?, ?, ?)`
59 |
60 | func initDb() {
61 |
62 | b, _ := PathExists(mainDbFileName)
63 | if !b {
64 | db, err := sql.Open("sqlite3", mainDbFileName)
65 | checkErr(err)
66 | _, err = db.Exec(proxyInfoSql)
67 | checkErr(err)
68 | _, err = db.Exec(proxyInfoIdxSql)
69 | checkErr(err)
70 | _, err = db.Exec(tunnelMappingSql)
71 | checkErr(err)
72 | _, err = db.Exec(tunnelMappingIdxSql)
73 | checkErr(err)
74 | }
75 | }
76 |
77 | type ProxyInfo struct {
78 | id int64
79 | name string
80 | proxyType string
81 | remoteIp string
82 | remotePort string
83 | remoteProtocol string
84 | localIp string
85 | localPort string
86 | localProtocol string
87 | crtLocation string
88 | keyLocation string
89 | sshUserName string
90 | sshPwd string
91 | sshPrivateKey string
92 | kcpPwd string
93 | dns string
94 | dnsTtl string
95 | }
96 |
97 | type TunnelMapping struct {
98 | id int64
99 | infoId int64
100 | protocolType string
101 | localPort string
102 | remotePort string
103 | }
104 |
105 | func initListView() {
106 | MainForm.ListView1.SetRowSelect(true)
107 | b, err := PathExists(mainDbFileName)
108 | if err != nil {
109 | panic("错误")
110 | }
111 | if !b {
112 | initDb()
113 | } else {
114 | db, err := sql.Open("sqlite3", mainDbFileName)
115 | checkErr(err)
116 | result, _ := db.Query("select * from proxy_info")
117 | MainForm.ListView1.Items().BeginUpdate()
118 | for result.Next() {
119 | p := new(ProxyInfo)
120 | err = result.Scan(&p.id, &p.name, &p.proxyType, &p.remoteIp, &p.remotePort,
121 | &p.remoteProtocol, &p.localIp, &p.localPort, &p.localProtocol, &p.crtLocation,
122 | &p.keyLocation, &p.sshUserName, &p.sshPwd, &p.sshPrivateKey, &p.kcpPwd, &p.dns, &p.dnsTtl)
123 | checkErr(err)
124 | listItem := MainForm.ListView1.Items().Add()
125 | listItem.SetCaption(string(p.id))
126 | listItem.SubItems().Add(p.name)
127 | listItem.SubItems().Add(p.remoteIp)
128 | listItem.SubItems().Add(p.remotePort)
129 | listItem.SubItems().Add(p.remoteProtocol)
130 | listItem.SubItems().Add(p.localProtocol)
131 | listItem.SubItems().Add(p.localPort)
132 | listItem.SubItems().Add("未启动")
133 | }
134 | MainForm.ListView1.Items().EndUpdate()
135 | }
136 | }
137 |
138 | func addNewProxyInfo(proxyInfo ProxyInfo) (id int64) {
139 | db, err := sql.Open("sqlite3", mainDbFileName)
140 | checkErr(err)
141 | stmt, err := db.Prepare(insertProxyInfoSql)
142 | checkErr(err)
143 | result, err := stmt.Exec(proxyInfo.name, proxyInfo.proxyType, proxyInfo.remoteIp, proxyInfo.remotePort, proxyInfo.remoteProtocol,
144 | proxyInfo.localIp, proxyInfo.localPort, proxyInfo.localProtocol, proxyInfo.crtLocation, proxyInfo.keyLocation,
145 | proxyInfo.sshUserName, proxyInfo.sshPwd, proxyInfo.sshPrivateKey, proxyInfo.kcpPwd, proxyInfo.dns,
146 | proxyInfo.dnsTtl)
147 | checkErr(err)
148 | id, _ = result.LastInsertId()
149 | return id
150 | }
151 |
152 | func addNewTunnelMapping(tunnelMapping TunnelMapping) (id int64) {
153 | db, err := sql.Open("sqlite3", mainDbFileName)
154 | checkErr(err)
155 | stmt, err := db.Prepare(insertTunnelMappingSql)
156 | checkErr(err)
157 | result, err := stmt.Exec(tunnelMapping.infoId, tunnelMapping.protocolType, tunnelMapping.localPort, tunnelMapping.remotePort)
158 | checkErr(err)
159 | id, _ = result.LastInsertId()
160 | return id
161 | }
162 |
163 | func PathExists(path string) (bool, error) {
164 | _, err := os.Stat(path)
165 | if err == nil {
166 | return true, nil
167 | }
168 | if os.IsNotExist(err) {
169 | return false, nil
170 | }
171 | return false, err
172 | }
173 |
174 | func setAutoRun() bool {
175 | dir, err := filepath.Abs(filepath.Dir(os.Args[0]))
176 | if err != nil {
177 | log.Fatal(err)
178 | return false
179 | }
180 | fmt.Println(dir)
181 | split := strings.Split(os.Args[0], string(os.PathSeparator))
182 | exeName := ""
183 | if len(split) > 0 {
184 | fmt.Println(split[len(split)-1])
185 | exeName = split[len(split)-1]
186 | } else {
187 | exeName = os.Args[0]
188 | }
189 | fmt.Println(exeName)
190 |
191 | var exec = dir + string(os.PathSeparator) + exeName
192 | app := &autostart.App{
193 | Name: "goproxy-gui",
194 | DisplayName: "goproxy的图形界面",
195 | Exec: []string{exec},
196 | }
197 |
198 | if app.IsEnabled() {
199 | log.Println("App is already enabled, removing it...")
200 | } else {
201 | log.Println("Enabling app...")
202 |
203 | if err := app.Enable(); err != nil {
204 | log.Fatal(err)
205 | return false
206 | }
207 | }
208 | return true
209 | }
210 |
211 | func unSetAutoRun() bool {
212 | dir, err := filepath.Abs(filepath.Dir(os.Args[0]))
213 | if err != nil {
214 | log.Fatal(err)
215 | return false
216 | }
217 | fmt.Println(dir)
218 | split := strings.Split(os.Args[0], string(os.PathSeparator))
219 | exeName := ""
220 | if len(split) > 0 {
221 | fmt.Println(split[len(split)-1])
222 | exeName = split[len(split)-1]
223 | } else {
224 | exeName = os.Args[0]
225 | }
226 | fmt.Println(exeName)
227 |
228 | var exec = dir + string(os.PathSeparator) + exeName
229 | app := &autostart.App{
230 | Name: "goproxy-gui",
231 | DisplayName: "goproxy的图形界面",
232 | Exec: []string{exec},
233 | }
234 |
235 | if app.IsEnabled() {
236 | log.Println("App is already enabled, removing it...")
237 |
238 | if err := app.Disable(); err != nil {
239 | log.Fatal(err)
240 | return false
241 | }
242 | }
243 | return true
244 | }
245 |
246 | func setSysProxy(addr string) bool {
247 | helperFullPath := "sysproxy-cmd"
248 | iconFullPath, _ := filepath.Abs("./icon.png")
249 | log.Println("Using icon at %v", iconFullPath)
250 | err := sysproxy.EnsureHelperToolPresent(helperFullPath, "Input your password and save the world!", iconFullPath)
251 | if err != nil {
252 | fmt.Printf("Error EnsureHelperToolPresent: %s\n", err)
253 | return false
254 | }
255 | _, err1 := sysproxy.On(addr)
256 | if err1 != nil {
257 | fmt.Printf("Error set proxy: %s\n", err)
258 | return false
259 | }
260 | return true
261 | }
262 |
263 | func unsetSysProxy(addr string) bool {
264 | helperFullPath := "sysproxy-cmd"
265 | iconFullPath, _ := filepath.Abs("./icon.png")
266 | //log.Println("Using icon at %v", iconFullPath)
267 | err := sysproxy.EnsureHelperToolPresent(helperFullPath, "Input your password and save the world!", iconFullPath)
268 | if err != nil {
269 | fmt.Printf("Error EnsureHelperToolPresent: %s\n", err)
270 | return false
271 | }
272 | off, err1 := sysproxy.On(addr)
273 | if err1 != nil {
274 | fmt.Printf("Error set proxy: %s\n", err1)
275 | return false
276 | }
277 | err2 := off()
278 | if err2 != nil {
279 | fmt.Printf("Error unset proxy: %s\n", err2)
280 | return false
281 | }
282 | return true
283 | }
284 |
285 | func checkErr(err error) {
286 | if err != nil {
287 | panic(err)
288 | }
289 | }
290 |
--------------------------------------------------------------------------------
/MainFormImpl.go:
--------------------------------------------------------------------------------
1 | // 由res2go自动生成。
2 | // 在这里写你的事件。
3 |
4 | package main
5 |
6 | import (
7 | "github.com/ying32/govcl/vcl"
8 | )
9 |
10 | //::private::
11 | type TMainFormFields struct {
12 | }
13 |
14 |
15 | func (f *TMainForm) OnSettingsBtnClick(sender vcl.IObject) {
16 | SettingForm.ShowModal()
17 | }
18 |
19 |
20 | func (f *TMainForm) OnUpdateBtnClick(sender vcl.IObject) {
21 |
22 | }
23 |
24 |
25 | func (f *TMainForm) OnHelpBtnClick(sender vcl.IObject) {
26 |
27 | }
28 |
29 |
30 | func (f *TMainForm) OnAddServerClick(sender vcl.IObject) {
31 | NewProxyServerForm.ShowModal()
32 | }
33 |
34 |
35 | func (f *TMainForm) OnSetActivityServerClick(sender vcl.IObject) {
36 |
37 | }
38 |
39 |
40 | func (f *TMainForm) OnPingServerClick(sender vcl.IObject) {
41 |
42 | }
43 |
44 |
45 | func (f *TMainForm) OnShowMainWindowClick(sender vcl.IObject) {
46 |
47 | }
48 |
49 |
50 | func (f *TMainForm) OnExitMainWindowClick(sender vcl.IObject) {
51 |
52 | }
53 |
54 |
--------------------------------------------------------------------------------
/NewProxyServerForm.go:
--------------------------------------------------------------------------------
1 | // 由res2go自动生成,不要编辑。
2 | package main
3 |
4 | import (
5 | "github.com/ying32/govcl/vcl"
6 | )
7 |
8 | type TNewProxyServerForm struct {
9 | *vcl.TForm
10 | GroupBox1 *vcl.TGroupBox
11 | Label1 *vcl.TLabel
12 | IpInput *vcl.TEdit
13 | Label2 *vcl.TLabel
14 | PortInput *vcl.TEdit
15 | Label3 *vcl.TLabel
16 | ServerProtocolComboBox *vcl.TComboBox
17 | GroupBox2 *vcl.TGroupBox
18 | Label12 *vcl.TLabel
19 | LocalIp *vcl.TEdit
20 | Label13 *vcl.TLabel
21 | LocalPort *vcl.TEdit
22 | Label14 *vcl.TLabel
23 | LocalProtocolComboBox *vcl.TComboBox
24 | GroupBox3 *vcl.TGroupBox
25 | Label10 *vcl.TLabel
26 | DnsInput *vcl.TEdit
27 | Label11 *vcl.TLabel
28 | TTLInput *vcl.TEdit
29 | GroupBox4 *vcl.TGroupBox
30 | ListView1 *vcl.TListView
31 | ConfirmBtn *vcl.TButton
32 | CancelBtn *vcl.TButton
33 | Label15 *vcl.TLabel
34 | ProxyTypeComboBox *vcl.TComboBox
35 | PageControl1 *vcl.TPageControl
36 | TlsPage *vcl.TTabSheet
37 | CrtLabel *vcl.TLabel
38 | CrtInput *vcl.TEdit
39 | KeyLabel *vcl.TLabel
40 | KeyInput *vcl.TEdit
41 | SelectCrtBtn *vcl.TButton
42 | SelectKeyBtn *vcl.TButton
43 | SSHPage *vcl.TTabSheet
44 | SshUserNameLabel *vcl.TLabel
45 | SshUserNameInput *vcl.TEdit
46 | SshPwdLabel *vcl.TLabel
47 | SshPwdInput *vcl.TEdit
48 | SshKeyLabel *vcl.TLabel
49 | SshKeyInput *vcl.TEdit
50 | SelectPrivateKeyBtn *vcl.TButton
51 | KcpPage *vcl.TTabSheet
52 | KcpPwdLabel *vcl.TLabel
53 | KcpPwdInput *vcl.TEdit
54 | Label4 *vcl.TLabel
55 | ServerNameInput *vcl.TEdit
56 | PopupMenu1 *vcl.TPopupMenu
57 | AddMapping *vcl.TMenuItem
58 | ModifyMapping *vcl.TMenuItem
59 | DelMapping *vcl.TMenuItem
60 | ActionList1 *vcl.TActionList
61 | SelectCrtAction *vcl.TAction
62 | SelectKeyAction *vcl.TAction
63 | SelectPrivateKeyAction *vcl.TAction
64 | SelectCrtDialog *vcl.TOpenDialog
65 | SelectKeyDialog *vcl.TOpenDialog
66 | SelectPrivateKeyDialog *vcl.TOpenDialog
67 |
68 | //::private::
69 | TNewProxyServerFormFields
70 | }
71 |
72 | var NewProxyServerForm *TNewProxyServerForm
73 |
74 |
75 |
76 |
77 | // 以字节形式加载
78 | // vcl.Application.CreateForm(newProxyServerFormBytes, &NewProxyServerForm)
79 |
80 | var newProxyServerFormBytes = []byte("\x54\x50\x46\x30\x13\x54\x4E\x65\x77\x50\x72\x6F\x78\x79\x53\x65\x72\x76\x65\x72\x46\x6F\x72\x6D\x12\x4E\x65\x77\x50\x72\x6F\x78\x79\x53\x65\x72\x76\x65\x72\x46\x6F\x72\x6D\x04\x4C\x65\x66\x74\x03\xFC\x01\x06\x48\x65\x69\x67\x68\x74\x03\x31\x02\x03\x54\x6F\x70\x03\xB7\x00\x05\x57\x69\x64\x74\x68\x03\x95\x02\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x0C\xE6\x96\xB0\xE5\xA2\x9E\xE6\x9C\x8D\xE5\x8A\xA1\x0C\x43\x6C\x69\x65\x6E\x74\x48\x65\x69\x67\x68\x74\x03\x31\x02\x0B\x43\x6C\x69\x65\x6E\x74\x57\x69\x64\x74\x68\x03\x95\x02\x0D\x44\x65\x73\x69\x67\x6E\x54\x69\x6D\x65\x50\x50\x49\x02\x78\x0A\x4C\x43\x4C\x56\x65\x72\x73\x69\x6F\x6E\x06\x07\x32\x2E\x30\x2E\x32\x2E\x30\x00\x09\x54\x47\x72\x6F\x75\x70\x42\x6F\x78\x09\x47\x72\x6F\x75\x70\x42\x6F\x78\x31\x04\x4C\x65\x66\x74\x02\x10\x06\x48\x65\x69\x67\x68\x74\x03\xB8\x00\x03\x54\x6F\x70\x02\x30\x05\x57\x69\x64\x74\x68\x03\x80\x02\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x0F\xE6\x9C\x8D\xE5\x8A\xA1\xE5\x99\xA8\xE9\x85\x8D\xE7\xBD\xAE\x0C\x43\x6C\x69\x65\x6E\x74\x48\x65\x69\x67\x68\x74\x03\x9F\x00\x0B\x43\x6C\x69\x65\x6E\x74\x57\x69\x64\x74\x68\x03\x7C\x02\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x00\x00\x06\x54\x4C\x61\x62\x65\x6C\x06\x4C\x61\x62\x65\x6C\x31\x04\x4C\x65\x66\x74\x02\x10\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x10\x05\x57\x69\x64\x74\x68\x02\x1E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE5\x9C\xB0\xE5\x9D\x80\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x05\x54\x45\x64\x69\x74\x07\x49\x70\x49\x6E\x70\x75\x74\x04\x4C\x65\x66\x74\x02\x48\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x08\x05\x57\x69\x64\x74\x68\x03\xC8\x00\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x00\x00\x00\x06\x54\x4C\x61\x62\x65\x6C\x06\x4C\x61\x62\x65\x6C\x32\x04\x4C\x65\x66\x74\x03\x28\x01\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x10\x05\x57\x69\x64\x74\x68\x02\x1E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE7\xAB\xAF\xE5\x8F\xA3\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x05\x54\x45\x64\x69\x74\x09\x50\x6F\x72\x74\x49\x6E\x70\x75\x74\x04\x4C\x65\x66\x74\x03\x60\x01\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x08\x05\x57\x69\x64\x74\x68\x02\x64\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x01\x00\x00\x06\x54\x4C\x61\x62\x65\x6C\x06\x4C\x61\x62\x65\x6C\x33\x04\x4C\x65\x66\x74\x02\x0C\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x38\x05\x57\x69\x64\x74\x68\x02\x22\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x07\x20\xE5\x8D\x8F\xE8\xAE\xAE\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x09\x54\x43\x6F\x6D\x62\x6F\x42\x6F\x78\x16\x53\x65\x72\x76\x65\x72\x50\x72\x6F\x74\x6F\x63\x6F\x6C\x43\x6F\x6D\x62\x6F\x42\x6F\x78\x04\x4C\x65\x66\x74\x02\x48\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x30\x05\x57\x69\x64\x74\x68\x02\x7D\x0A\x49\x74\x65\x6D\x48\x65\x69\x67\x68\x74\x02\x14\x09\x49\x74\x65\x6D\x49\x6E\x64\x65\x78\x02\x00\x0D\x49\x74\x65\x6D\x73\x2E\x53\x74\x72\x69\x6E\x67\x73\x01\x06\x03\x74\x63\x70\x06\x03\x74\x6C\x73\x06\x03\x6B\x63\x70\x06\x03\x73\x73\x68\x06\x02\x77\x73\x06\x03\x77\x73\x73\x00\x08\x4F\x6E\x43\x68\x61\x6E\x67\x65\x07\x1C\x53\x65\x72\x76\x65\x72\x50\x72\x6F\x74\x6F\x63\x6F\x6C\x43\x6F\x6D\x62\x6F\x42\x6F\x78\x43\x68\x61\x6E\x67\x65\x05\x53\x74\x79\x6C\x65\x07\x0E\x63\x73\x44\x72\x6F\x70\x44\x6F\x77\x6E\x4C\x69\x73\x74\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x02\x04\x54\x65\x78\x74\x06\x03\x74\x63\x70\x00\x00\x00\x09\x54\x47\x72\x6F\x75\x70\x42\x6F\x78\x09\x47\x72\x6F\x75\x70\x42\x6F\x78\x32\x04\x4C\x65\x66\x74\x02\x10\x06\x48\x65\x69\x67\x68\x74\x02\x78\x03\x54\x6F\x70\x03\xE8\x00\x05\x57\x69\x64\x74\x68\x03\x80\x02\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x0C\xE6\x9C\xAC\xE5\x9C\xB0\xE9\x85\x8D\xE7\xBD\xAE\x0C\x43\x6C\x69\x65\x6E\x74\x48\x65\x69\x67\x68\x74\x02\x5F\x0B\x43\x6C\x69\x65\x6E\x74\x57\x69\x64\x74\x68\x03\x7C\x02\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x01\x00\x06\x54\x4C\x61\x62\x65\x6C\x07\x4C\x61\x62\x65\x6C\x31\x32\x04\x4C\x65\x66\x74\x02\x0C\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x08\x05\x57\x69\x64\x74\x68\x02\x1E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE5\x9C\xB0\xE5\x9D\x80\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x05\x54\x45\x64\x69\x74\x07\x4C\x6F\x63\x61\x6C\x49\x70\x04\x4C\x65\x66\x74\x02\x48\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x00\x05\x57\x69\x64\x74\x68\x03\xC8\x00\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x00\x04\x54\x65\x78\x74\x06\x09\x31\x32\x37\x2E\x30\x2E\x30\x2E\x31\x00\x00\x06\x54\x4C\x61\x62\x65\x6C\x07\x4C\x61\x62\x65\x6C\x31\x33\x04\x4C\x65\x66\x74\x03\x40\x01\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x08\x05\x57\x69\x64\x74\x68\x02\x1E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE7\xAB\xAF\xE5\x8F\xA3\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x05\x54\x45\x64\x69\x74\x09\x4C\x6F\x63\x61\x6C\x50\x6F\x72\x74\x04\x4C\x65\x66\x74\x03\x70\x01\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x00\x05\x57\x69\x64\x74\x68\x02\x64\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x01\x04\x54\x65\x78\x74\x06\x04\x31\x30\x38\x30\x00\x00\x06\x54\x4C\x61\x62\x65\x6C\x07\x4C\x61\x62\x65\x6C\x31\x34\x04\x4C\x65\x66\x74\x02\x0C\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x30\x05\x57\x69\x64\x74\x68\x02\x1E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE5\x8D\x8F\xE8\xAE\xAE\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x09\x54\x43\x6F\x6D\x62\x6F\x42\x6F\x78\x15\x4C\x6F\x63\x61\x6C\x50\x72\x6F\x74\x6F\x63\x6F\x6C\x43\x6F\x6D\x62\x6F\x42\x6F\x78\x04\x4C\x65\x66\x74\x02\x48\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x28\x05\x57\x69\x64\x74\x68\x02\x7D\x0A\x49\x74\x65\x6D\x48\x65\x69\x67\x68\x74\x02\x14\x09\x49\x74\x65\x6D\x49\x6E\x64\x65\x78\x02\x01\x0D\x49\x74\x65\x6D\x73\x2E\x53\x74\x72\x69\x6E\x67\x73\x01\x06\x03\x74\x6C\x73\x06\x03\x74\x63\x70\x06\x03\x6B\x63\x70\x00\x08\x4F\x6E\x43\x68\x61\x6E\x67\x65\x07\x1B\x4C\x6F\x63\x61\x6C\x50\x72\x6F\x74\x6F\x63\x6F\x6C\x43\x6F\x6D\x62\x6F\x42\x6F\x78\x43\x68\x61\x6E\x67\x65\x05\x53\x74\x79\x6C\x65\x07\x0E\x63\x73\x44\x72\x6F\x70\x44\x6F\x77\x6E\x4C\x69\x73\x74\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x02\x04\x54\x65\x78\x74\x06\x03\x74\x63\x70\x00\x00\x00\x09\x54\x47\x72\x6F\x75\x70\x42\x6F\x78\x09\x47\x72\x6F\x75\x70\x42\x6F\x78\x33\x04\x4C\x65\x66\x74\x02\x10\x06\x48\x65\x69\x67\x68\x74\x02\x58\x03\x54\x6F\x70\x03\x60\x01\x05\x57\x69\x64\x74\x68\x03\x80\x02\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x0C\xE5\x85\xB6\xE4\xBB\x96\xE9\x85\x8D\xE7\xBD\xAE\x0C\x43\x6C\x69\x65\x6E\x74\x48\x65\x69\x67\x68\x74\x02\x3F\x0B\x43\x6C\x69\x65\x6E\x74\x57\x69\x64\x74\x68\x03\x7C\x02\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x02\x00\x06\x54\x4C\x61\x62\x65\x6C\x07\x4C\x61\x62\x65\x6C\x31\x30\x04\x4C\x65\x66\x74\x02\x0C\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x11\x05\x57\x69\x64\x74\x68\x02\x20\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x03\x44\x4E\x53\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x05\x54\x45\x64\x69\x74\x08\x44\x6E\x73\x49\x6E\x70\x75\x74\x04\x4C\x65\x66\x74\x02\x40\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x09\x05\x57\x69\x64\x74\x68\x03\xB8\x00\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x00\x04\x54\x65\x78\x74\x06\x0A\x38\x2E\x38\x2E\x38\x2E\x38\x3A\x35\x33\x00\x00\x06\x54\x4C\x61\x62\x65\x6C\x07\x4C\x61\x62\x65\x6C\x31\x31\x04\x4C\x65\x66\x74\x03\x10\x01\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x11\x05\x57\x69\x64\x74\x68\x02\x33\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x08\x54\x54\x4C\x28\xE7\xA7\x92\x29\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x05\x54\x45\x64\x69\x74\x08\x54\x54\x4C\x49\x6E\x70\x75\x74\x04\x4C\x65\x66\x74\x03\x58\x01\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x09\x05\x57\x69\x64\x74\x68\x02\x64\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x01\x04\x54\x65\x78\x74\x06\x03\x36\x30\x30\x00\x00\x00\x09\x54\x47\x72\x6F\x75\x70\x42\x6F\x78\x09\x47\x72\x6F\x75\x70\x42\x6F\x78\x34\x04\x4C\x65\x66\x74\x02\x10\x06\x48\x65\x69\x67\x68\x74\x03\x08\x01\x03\x54\x6F\x70\x03\xE8\x00\x05\x57\x69\x64\x74\x68\x03\x80\x02\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x0C\xE7\xA9\xBF\xE9\x80\x8F\xE6\x98\xA0\xE5\xB0\x84\x0C\x43\x6C\x69\x65\x6E\x74\x48\x65\x69\x67\x68\x74\x03\xEF\x00\x0B\x43\x6C\x69\x65\x6E\x74\x57\x69\x64\x74\x68\x03\x7C\x02\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x03\x07\x56\x69\x73\x69\x62\x6C\x65\x08\x00\x09\x54\x4C\x69\x73\x74\x56\x69\x65\x77\x09\x4C\x69\x73\x74\x56\x69\x65\x77\x31\x04\x4C\x65\x66\x74\x02\x00\x06\x48\x65\x69\x67\x68\x74\x03\xE8\x00\x03\x54\x6F\x70\x02\x00\x05\x57\x69\x64\x74\x68\x03\x78\x02\x07\x43\x6F\x6C\x75\x6D\x6E\x73\x0E\x01\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE7\xB1\xBB\xE5\x9E\x8B\x05\x57\x69\x64\x74\x68\x02\x64\x00\x01\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x0C\xE8\xBF\x9C\xE7\xA8\x8B\xE7\xAB\xAF\xE5\x8F\xA3\x05\x57\x69\x64\x74\x68\x02\x64\x00\x01\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x0C\xE6\x9C\xAC\xE5\x9C\xB0\xE7\xAB\xAF\xE5\x8F\xA3\x05\x57\x69\x64\x74\x68\x02\x64\x00\x00\x09\x50\x6F\x70\x75\x70\x4D\x65\x6E\x75\x07\x0A\x50\x6F\x70\x75\x70\x4D\x65\x6E\x75\x31\x09\x52\x6F\x77\x53\x65\x6C\x65\x63\x74\x09\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x00\x09\x56\x69\x65\x77\x53\x74\x79\x6C\x65\x07\x08\x76\x73\x52\x65\x70\x6F\x72\x74\x00\x00\x00\x07\x54\x42\x75\x74\x74\x6F\x6E\x0A\x43\x6F\x6E\x66\x69\x72\x6D\x42\x74\x6E\x04\x4C\x65\x66\x74\x03\xB0\x00\x06\x48\x65\x69\x67\x68\x74\x02\x1F\x03\x54\x6F\x70\x03\x08\x02\x05\x57\x69\x64\x74\x68\x02\x5E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE7\xA1\xAE\xE5\xAE\x9A\x07\x4F\x6E\x43\x6C\x69\x63\x6B\x07\x0F\x43\x6F\x6E\x66\x69\x72\x6D\x42\x74\x6E\x43\x6C\x69\x63\x6B\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x04\x00\x00\x07\x54\x42\x75\x74\x74\x6F\x6E\x09\x43\x61\x6E\x63\x65\x6C\x42\x74\x6E\x04\x4C\x65\x66\x74\x03\x70\x01\x06\x48\x65\x69\x67\x68\x74\x02\x1F\x03\x54\x6F\x70\x03\x08\x02\x05\x57\x69\x64\x74\x68\x02\x5E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE5\x8F\x96\xE6\xB6\x88\x07\x4F\x6E\x43\x6C\x69\x63\x6B\x07\x0E\x43\x61\x6E\x63\x65\x6C\x42\x74\x6E\x43\x6C\x69\x63\x6B\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x05\x00\x00\x06\x54\x4C\x61\x62\x65\x6C\x07\x4C\x61\x62\x65\x6C\x31\x35\x04\x4C\x65\x66\x74\x02\x10\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x10\x05\x57\x69\x64\x74\x68\x02\x3C\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x0C\xE4\xBB\xA3\xE7\x90\x86\xE7\xB1\xBB\xE5\x9E\x8B\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x09\x54\x43\x6F\x6D\x62\x6F\x42\x6F\x78\x11\x50\x72\x6F\x78\x79\x54\x79\x70\x65\x43\x6F\x6D\x62\x6F\x42\x6F\x78\x04\x4C\x65\x66\x74\x02\x58\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x08\x05\x57\x69\x64\x74\x68\x02\x7D\x0A\x49\x74\x65\x6D\x48\x65\x69\x67\x68\x74\x02\x14\x09\x49\x74\x65\x6D\x49\x6E\x64\x65\x78\x02\x01\x0D\x49\x74\x65\x6D\x73\x2E\x53\x74\x72\x69\x6E\x67\x73\x01\x06\x04\x48\x54\x54\x50\x06\x03\x53\x50\x53\x06\x03\x54\x43\x50\x06\x03\x55\x44\x50\x06\x05\x53\x4F\x43\x4B\x53\x06\x06\xE7\xA9\xBF\xE9\x80\x8F\x00\x08\x4F\x6E\x43\x68\x61\x6E\x67\x65\x07\x17\x50\x72\x6F\x78\x79\x54\x79\x70\x65\x43\x6F\x6D\x62\x6F\x42\x6F\x78\x43\x68\x61\x6E\x67\x65\x05\x53\x74\x79\x6C\x65\x07\x0E\x63\x73\x44\x72\x6F\x70\x44\x6F\x77\x6E\x4C\x69\x73\x74\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x06\x04\x54\x65\x78\x74\x06\x03\x53\x50\x53\x00\x00\x0C\x54\x50\x61\x67\x65\x43\x6F\x6E\x74\x72\x6F\x6C\x0C\x50\x61\x67\x65\x43\x6F\x6E\x74\x72\x6F\x6C\x31\x04\x4C\x65\x66\x74\x02\x18\x06\x48\x65\x69\x67\x68\x74\x02\x38\x03\x54\x6F\x70\x03\xA0\x00\x05\x57\x69\x64\x74\x68\x03\x58\x02\x0A\x41\x63\x74\x69\x76\x65\x50\x61\x67\x65\x07\x07\x4B\x63\x70\x50\x61\x67\x65\x08\x53\x68\x6F\x77\x54\x61\x62\x73\x08\x08\x54\x61\x62\x49\x6E\x64\x65\x78\x02\x02\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x07\x07\x56\x69\x73\x69\x62\x6C\x65\x08\x00\x09\x54\x54\x61\x62\x53\x68\x65\x65\x74\x07\x54\x6C\x73\x50\x61\x67\x65\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x07\x54\x6C\x73\x50\x61\x67\x65\x0C\x43\x6C\x69\x65\x6E\x74\x48\x65\x69\x67\x68\x74\x02\x30\x0B\x43\x6C\x69\x65\x6E\x74\x57\x69\x64\x74\x68\x03\x50\x02\x00\x06\x54\x4C\x61\x62\x65\x6C\x08\x43\x72\x74\x4C\x61\x62\x65\x6C\x04\x4C\x65\x66\x74\x02\x08\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x10\x05\x57\x69\x64\x74\x68\x02\x1E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE8\xAF\x81\xE4\xB9\xA6\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x05\x54\x45\x64\x69\x74\x08\x43\x72\x74\x49\x6E\x70\x75\x74\x04\x4C\x65\x66\x74\x02\x30\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x08\x05\x57\x69\x64\x74\x68\x03\xC0\x00\x08\x52\x65\x61\x64\x4F\x6E\x6C\x79\x09\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x00\x00\x00\x06\x54\x4C\x61\x62\x65\x6C\x08\x4B\x65\x79\x4C\x61\x62\x65\x6C\x04\x4C\x65\x66\x74\x03\x30\x01\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x10\x05\x57\x69\x64\x74\x68\x02\x1E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE5\xAF\x86\xE9\x92\xA5\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x05\x54\x45\x64\x69\x74\x08\x4B\x65\x79\x49\x6E\x70\x75\x74\x04\x4C\x65\x66\x74\x03\x50\x01\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x08\x05\x57\x69\x64\x74\x68\x03\xC4\x00\x08\x52\x65\x61\x64\x4F\x6E\x6C\x79\x09\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x01\x00\x00\x07\x54\x42\x75\x74\x74\x6F\x6E\x0C\x53\x65\x6C\x65\x63\x74\x43\x72\x74\x42\x74\x6E\x04\x4C\x65\x66\x74\x03\xF0\x00\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x08\x05\x57\x69\x64\x74\x68\x02\x18\x06\x41\x63\x74\x69\x6F\x6E\x07\x0F\x53\x65\x6C\x65\x63\x74\x43\x72\x74\x41\x63\x74\x69\x6F\x6E\x07\x4F\x6E\x43\x6C\x69\x63\x6B\x07\x11\x53\x65\x6C\x65\x63\x74\x43\x72\x74\x42\x74\x6E\x43\x6C\x69\x63\x6B\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x02\x00\x00\x07\x54\x42\x75\x74\x74\x6F\x6E\x0C\x53\x65\x6C\x65\x63\x74\x4B\x65\x79\x42\x74\x6E\x04\x4C\x65\x66\x74\x03\x10\x02\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x08\x05\x57\x69\x64\x74\x68\x02\x18\x06\x41\x63\x74\x69\x6F\x6E\x07\x0F\x53\x65\x6C\x65\x63\x74\x4B\x65\x79\x41\x63\x74\x69\x6F\x6E\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x03\x00\x00\x00\x09\x54\x54\x61\x62\x53\x68\x65\x65\x74\x07\x53\x53\x48\x50\x61\x67\x65\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x07\x53\x53\x48\x50\x61\x67\x65\x0C\x43\x6C\x69\x65\x6E\x74\x48\x65\x69\x67\x68\x74\x02\x30\x0B\x43\x6C\x69\x65\x6E\x74\x57\x69\x64\x74\x68\x03\x50\x02\x00\x06\x54\x4C\x61\x62\x65\x6C\x10\x53\x73\x68\x55\x73\x65\x72\x4E\x61\x6D\x65\x4C\x61\x62\x65\x6C\x04\x4C\x65\x66\x74\x02\x00\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x10\x05\x57\x69\x64\x74\x68\x02\x2D\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x09\xE7\x94\xA8\xE6\x88\xB7\xE5\x90\x8D\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x05\x54\x45\x64\x69\x74\x10\x53\x73\x68\x55\x73\x65\x72\x4E\x61\x6D\x65\x49\x6E\x70\x75\x74\x04\x4C\x65\x66\x74\x02\x47\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x08\x05\x57\x69\x64\x74\x68\x02\x64\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x00\x00\x00\x06\x54\x4C\x61\x62\x65\x6C\x0B\x53\x73\x68\x50\x77\x64\x4C\x61\x62\x65\x6C\x04\x4C\x65\x66\x74\x03\xDF\x00\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x10\x05\x57\x69\x64\x74\x68\x02\x1E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE5\xAF\x86\xE7\xA0\x81\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x05\x54\x45\x64\x69\x74\x0B\x53\x73\x68\x50\x77\x64\x49\x6E\x70\x75\x74\x04\x4C\x65\x66\x74\x03\x13\x01\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x08\x05\x57\x69\x64\x74\x68\x02\x64\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x01\x00\x00\x06\x54\x4C\x61\x62\x65\x6C\x0B\x53\x73\x68\x4B\x65\x79\x4C\x61\x62\x65\x6C\x04\x4C\x65\x66\x74\x03\xAF\x01\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x10\x05\x57\x69\x64\x74\x68\x02\x1E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE7\xA7\x81\xE9\x92\xA5\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x05\x54\x45\x64\x69\x74\x0B\x53\x73\x68\x4B\x65\x79\x49\x6E\x70\x75\x74\x04\x4C\x65\x66\x74\x03\xD0\x01\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x08\x05\x57\x69\x64\x74\x68\x02\x64\x08\x52\x65\x61\x64\x4F\x6E\x6C\x79\x09\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x02\x00\x00\x07\x54\x42\x75\x74\x74\x6F\x6E\x13\x53\x65\x6C\x65\x63\x74\x50\x72\x69\x76\x61\x74\x65\x4B\x65\x79\x42\x74\x6E\x04\x4C\x65\x66\x74\x03\x2F\x02\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x08\x05\x57\x69\x64\x74\x68\x02\x18\x06\x41\x63\x74\x69\x6F\x6E\x07\x16\x53\x65\x6C\x65\x63\x74\x50\x72\x69\x76\x61\x74\x65\x4B\x65\x79\x41\x63\x74\x69\x6F\x6E\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x03\x00\x00\x00\x09\x54\x54\x61\x62\x53\x68\x65\x65\x74\x07\x4B\x63\x70\x50\x61\x67\x65\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x07\x4B\x63\x70\x50\x61\x67\x65\x0C\x43\x6C\x69\x65\x6E\x74\x48\x65\x69\x67\x68\x74\x02\x30\x0B\x43\x6C\x69\x65\x6E\x74\x57\x69\x64\x74\x68\x03\x50\x02\x00\x06\x54\x4C\x61\x62\x65\x6C\x0B\x4B\x63\x70\x50\x77\x64\x4C\x61\x62\x65\x6C\x04\x4C\x65\x66\x74\x02\x08\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x10\x05\x57\x69\x64\x74\x68\x02\x1E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE5\xAF\x86\xE9\x92\xA5\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x05\x54\x45\x64\x69\x74\x0B\x4B\x63\x70\x50\x77\x64\x49\x6E\x70\x75\x74\x04\x4C\x65\x66\x74\x02\x40\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x08\x05\x57\x69\x64\x74\x68\x02\x64\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x00\x00\x00\x00\x00\x06\x54\x4C\x61\x62\x65\x6C\x06\x4C\x61\x62\x65\x6C\x34\x04\x4C\x65\x66\x74\x03\x20\x01\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x10\x05\x57\x69\x64\x74\x68\x02\x1E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE5\x90\x8D\xE7\xA7\xB0\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x05\x54\x45\x64\x69\x74\x0F\x53\x65\x72\x76\x65\x72\x4E\x61\x6D\x65\x49\x6E\x70\x75\x74\x04\x4C\x65\x66\x74\x03\x68\x01\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x08\x05\x57\x69\x64\x74\x68\x03\xC8\x00\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x08\x00\x00\x0A\x54\x50\x6F\x70\x75\x70\x4D\x65\x6E\x75\x0A\x50\x6F\x70\x75\x70\x4D\x65\x6E\x75\x31\x04\x6C\x65\x66\x74\x03\xF0\x01\x03\x74\x6F\x70\x03\x08\x02\x00\x09\x54\x4D\x65\x6E\x75\x49\x74\x65\x6D\x0A\x41\x64\x64\x4D\x61\x70\x70\x69\x6E\x67\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE6\x96\xB0\xE5\xA2\x9E\x07\x4F\x6E\x43\x6C\x69\x63\x6B\x07\x0F\x41\x64\x64\x4D\x61\x70\x70\x69\x6E\x67\x43\x6C\x69\x63\x6B\x00\x00\x09\x54\x4D\x65\x6E\x75\x49\x74\x65\x6D\x0D\x4D\x6F\x64\x69\x66\x79\x4D\x61\x70\x70\x69\x6E\x67\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE4\xBF\xAE\xE6\x94\xB9\x07\x4F\x6E\x43\x6C\x69\x63\x6B\x07\x12\x4D\x6F\x64\x69\x66\x79\x4D\x61\x70\x70\x69\x6E\x67\x43\x6C\x69\x63\x6B\x00\x00\x09\x54\x4D\x65\x6E\x75\x49\x74\x65\x6D\x0A\x44\x65\x6C\x4D\x61\x70\x70\x69\x6E\x67\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE5\x88\xA0\xE9\x99\xA4\x07\x4F\x6E\x43\x6C\x69\x63\x6B\x07\x0F\x44\x65\x6C\x4D\x61\x70\x70\x69\x6E\x67\x43\x6C\x69\x63\x6B\x00\x00\x00\x0B\x54\x41\x63\x74\x69\x6F\x6E\x4C\x69\x73\x74\x0B\x41\x63\x74\x69\x6F\x6E\x4C\x69\x73\x74\x31\x04\x6C\x65\x66\x74\x03\x70\x02\x03\x74\x6F\x70\x03\x08\x02\x00\x07\x54\x41\x63\x74\x69\x6F\x6E\x0F\x53\x65\x6C\x65\x63\x74\x43\x72\x74\x41\x63\x74\x69\x6F\x6E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x03\x2E\x2E\x2E\x09\x4F\x6E\x45\x78\x65\x63\x75\x74\x65\x07\x16\x53\x65\x6C\x65\x63\x74\x43\x72\x74\x41\x63\x74\x69\x6F\x6E\x45\x78\x65\x63\x75\x74\x65\x00\x00\x07\x54\x41\x63\x74\x69\x6F\x6E\x0F\x53\x65\x6C\x65\x63\x74\x4B\x65\x79\x41\x63\x74\x69\x6F\x6E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x03\x2E\x2E\x2E\x09\x4F\x6E\x45\x78\x65\x63\x75\x74\x65\x07\x16\x53\x65\x6C\x65\x63\x74\x4B\x65\x79\x41\x63\x74\x69\x6F\x6E\x45\x78\x65\x63\x75\x74\x65\x00\x00\x07\x54\x41\x63\x74\x69\x6F\x6E\x16\x53\x65\x6C\x65\x63\x74\x50\x72\x69\x76\x61\x74\x65\x4B\x65\x79\x41\x63\x74\x69\x6F\x6E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x03\x2E\x2E\x2E\x09\x4F\x6E\x45\x78\x65\x63\x75\x74\x65\x07\x1D\x53\x65\x6C\x65\x63\x74\x50\x72\x69\x76\x61\x74\x65\x4B\x65\x79\x41\x63\x74\x69\x6F\x6E\x45\x78\x65\x63\x75\x74\x65\x00\x00\x00\x0B\x54\x4F\x70\x65\x6E\x44\x69\x61\x6C\x6F\x67\x0F\x53\x65\x6C\x65\x63\x74\x43\x72\x74\x44\x69\x61\x6C\x6F\x67\x04\x6C\x65\x66\x74\x03\x10\x02\x03\x74\x6F\x70\x03\x08\x02\x00\x00\x0B\x54\x4F\x70\x65\x6E\x44\x69\x61\x6C\x6F\x67\x0F\x53\x65\x6C\x65\x63\x74\x4B\x65\x79\x44\x69\x61\x6C\x6F\x67\x04\x6C\x65\x66\x74\x03\x30\x02\x03\x74\x6F\x70\x03\x08\x02\x00\x00\x0B\x54\x4F\x70\x65\x6E\x44\x69\x61\x6C\x6F\x67\x16\x53\x65\x6C\x65\x63\x74\x50\x72\x69\x76\x61\x74\x65\x4B\x65\x79\x44\x69\x61\x6C\x6F\x67\x04\x6C\x65\x66\x74\x03\x50\x02\x03\x74\x6F\x70\x03\x08\x02\x00\x00\x00")
81 |
--------------------------------------------------------------------------------
/NewProxyServerFormImpl.go:
--------------------------------------------------------------------------------
1 | // 由res2go自动生成。
2 | // 在这里写你的事件。
3 |
4 | package main
5 |
6 | import (
7 | "github.com/ying32/govcl/vcl"
8 | )
9 |
10 | //::private::
11 | type TNewProxyServerFormFields struct {
12 | }
13 |
14 |
15 | func (f *TNewProxyServerForm) OnServerProtocolComboBoxChange(sender vcl.IObject) {
16 | text := NewProxyServerForm.ServerProtocolComboBox.Text()
17 | switch text {
18 | case "tls":
19 | NewProxyServerForm.PageControl1.SetVisible(true)
20 | NewProxyServerForm.PageControl1.SetActivePageIndex(0)
21 | break;
22 | case "ssh":
23 | NewProxyServerForm.PageControl1.SetVisible(true)
24 | NewProxyServerForm.PageControl1.SetActivePageIndex(1)
25 | break;
26 | case "kcp":
27 | NewProxyServerForm.PageControl1.SetVisible(true)
28 | NewProxyServerForm.PageControl1.SetActivePageIndex(2)
29 | break;
30 | default:
31 | NewProxyServerForm.PageControl1.SetVisible(false)
32 | }
33 | }
34 |
35 |
36 | func (f *TNewProxyServerForm) OnLocalProtocolComboBoxChange(sender vcl.IObject) {
37 |
38 | }
39 |
40 | func (f *TNewProxyServerForm) OnConfirmBtnClick(sender vcl.IObject) {
41 | proxyType := NewProxyServerForm.ProxyTypeComboBox.Text()
42 | serverName := NewProxyServerForm.ServerNameInput.Text()
43 | remoteIp := NewProxyServerForm.IpInput.Text()
44 | remotePort := NewProxyServerForm.PortInput.Text()
45 | remoteProtocol := NewProxyServerForm.ServerProtocolComboBox.Text()
46 |
47 | crtLocation := NewProxyServerForm.CrtInput.Text()
48 | keyLocation := NewProxyServerForm.KeyInput.Text()
49 |
50 | sshPrivateKey := NewProxyServerForm.SshKeyInput.Text()
51 | sshUserName := NewProxyServerForm.SshUserNameInput.Text()
52 | sshPwd := NewProxyServerForm.SshPwdInput.Text()
53 |
54 | kcpPwd := NewProxyServerForm.KcpPwdInput.Text()
55 |
56 | localProtocol := NewProxyServerForm.LocalProtocolComboBox.Text()
57 | localIp := NewProxyServerForm.LocalIp.Text()
58 | localPort := NewProxyServerForm.LocalPort.Text()
59 |
60 | dns := NewProxyServerForm.DnsInput.Text()
61 | dnsTtl := NewProxyServerForm.TTLInput.Text()
62 |
63 | p := ProxyInfo{0,
64 | serverName,
65 | proxyType, remoteIp,remotePort, remoteProtocol,
66 | localIp, localPort, localProtocol, crtLocation, keyLocation,
67 | sshUserName, sshPwd, sshPrivateKey, kcpPwd, dns, dnsTtl, 0}
68 | addNewProxyInfo(p)
69 | }
70 |
71 |
72 | func (f *TNewProxyServerForm) OnCancelBtnClick(sender vcl.IObject) {
73 |
74 | }
75 |
76 |
77 | func (f *TNewProxyServerForm) OnProxyTypeComboBoxChange(sender vcl.IObject) {
78 | text := NewProxyServerForm.ProxyTypeComboBox.Text()
79 | if text == "穿透" {
80 | NewProxyServerForm.GroupBox2.SetVisible(false)
81 | NewProxyServerForm.GroupBox3.SetVisible(false)
82 | NewProxyServerForm.GroupBox4.SetVisible(true)
83 | } else {
84 | NewProxyServerForm.GroupBox2.SetVisible(true)
85 | NewProxyServerForm.GroupBox3.SetVisible(true)
86 | NewProxyServerForm.GroupBox4.SetVisible(false)
87 | }
88 | }
89 |
90 | func (f *TNewProxyServerForm) OnAddMappingClick(sender vcl.IObject) {
91 | AddMappingForm.ShowModal()
92 | }
93 |
94 |
95 | func (f *TNewProxyServerForm) OnModifyMappingClick(sender vcl.IObject) {
96 |
97 | }
98 |
99 |
100 | func (f *TNewProxyServerForm) OnDelMappingClick(sender vcl.IObject) {
101 |
102 | }
103 |
104 |
105 | func (f *TNewProxyServerForm) OnSelectCrtActionExecute(sender vcl.IObject) {
106 | NewProxyServerForm.SelectCrtDialog.SetFilter("证书文件(*.CRT;*.CER)|*.CRT;*.CER|全部文件(*.*)|*.*")
107 | NewProxyServerForm.SelectCrtDialog.SetDefaultExt("*.CRT")
108 | if NewProxyServerForm.SelectCrtDialog.Execute() {
109 | strFileName := NewProxyServerForm.SelectCrtDialog.FileName()
110 | if strFileName != "" {
111 | NewProxyServerForm.CrtInput.SetText(strFileName)
112 | }
113 | }
114 | }
115 |
116 |
117 | func (f *TNewProxyServerForm) OnSelectKeyActionExecute(sender vcl.IObject) {
118 | NewProxyServerForm.SelectKeyDialog.SetFilter("密钥文件(*.KEY)|*.KEY|全部文件(*.*)|*.*")
119 | NewProxyServerForm.SelectKeyDialog.SetDefaultExt("*.KEY")
120 | if NewProxyServerForm.SelectKeyDialog.Execute() {
121 | strFileName := NewProxyServerForm.SelectKeyDialog.FileName()
122 | if strFileName != "" {
123 | NewProxyServerForm.KeyInput.SetText(strFileName)
124 | }
125 | }
126 | }
127 |
128 |
129 | func (f *TNewProxyServerForm) OnSelectPrivateKeyActionExecute(sender vcl.IObject) {
130 | NewProxyServerForm.SelectKeyDialog.SetFilter("密钥文件(*.PEM)|*.PEM|全部文件(*.*)|*.*")
131 | NewProxyServerForm.SelectKeyDialog.SetDefaultExt("*.PEM")
132 | if NewProxyServerForm.SelectKeyDialog.Execute() {
133 | strFileName := NewProxyServerForm.SelectKeyDialog.FileName()
134 | if strFileName != "" {
135 | NewProxyServerForm.SshKeyInput.SetText(strFileName)
136 | }
137 | }
138 | }
139 |
140 |
141 | func (f *TNewProxyServerForm) OnSelectCrtBtnClick(sender vcl.IObject) {
142 |
143 | }
144 |
145 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # goproxy-gui
2 | goproxy 一个简单的gui
3 |
4 | goproxy:
5 | https://github.com/snail007/goproxy
6 |
7 | 使用了govcl:
8 | https://github.com/ying32/govcl
9 |
10 | 目前仅仅实现了sps http socks代理的客户端。
11 |
12 | 界面
13 |
14 | 
15 |
16 | 
17 |
18 | 
19 |
20 | 
--------------------------------------------------------------------------------
/SettingForm.go:
--------------------------------------------------------------------------------
1 | // 由res2go自动生成,不要编辑。
2 | package main
3 |
4 | import (
5 | "github.com/ying32/govcl/vcl"
6 | )
7 |
8 | type TSettingForm struct {
9 | *vcl.TForm
10 | AutoStartChk *vcl.TCheckBox
11 | SysProxyChk *vcl.TCheckBox
12 | PortEdit *vcl.TEdit
13 | PortLabel *vcl.TLabel
14 | ConfirmBtn *vcl.TButton
15 | CancelBtn *vcl.TButton
16 |
17 | //::private::
18 | TSettingFormFields
19 | }
20 |
21 | var SettingForm *TSettingForm
22 |
23 |
24 |
25 |
26 | // 以字节形式加载
27 | // vcl.Application.CreateForm(settingFormBytes, &SettingForm)
28 |
29 | var settingFormBytes = []byte("\x54\x50\x46\x30\x0C\x54\x53\x65\x74\x74\x69\x6E\x67\x46\x6F\x72\x6D\x0B\x53\x65\x74\x74\x69\x6E\x67\x46\x6F\x72\x6D\x04\x4C\x65\x66\x74\x03\x48\x02\x06\x48\x65\x69\x67\x68\x74\x03\xA4\x00\x03\x54\x6F\x70\x03\xDC\x01\x05\x57\x69\x64\x74\x68\x03\xE5\x01\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x0C\xE7\xB3\xBB\xE7\xBB\x9F\xE8\xAE\xBE\xE7\xBD\xAE\x0C\x43\x6C\x69\x65\x6E\x74\x48\x65\x69\x67\x68\x74\x03\xA4\x00\x0B\x43\x6C\x69\x65\x6E\x74\x57\x69\x64\x74\x68\x03\xE5\x01\x0D\x44\x65\x73\x69\x67\x6E\x54\x69\x6D\x65\x50\x50\x49\x02\x78\x0A\x4C\x43\x4C\x56\x65\x72\x73\x69\x6F\x6E\x06\x07\x31\x2E\x38\x2E\x34\x2E\x30\x00\x09\x54\x43\x68\x65\x63\x6B\x42\x6F\x78\x0C\x41\x75\x74\x6F\x53\x74\x61\x72\x74\x43\x68\x6B\x04\x4C\x65\x66\x74\x02\x37\x06\x48\x65\x69\x67\x68\x74\x02\x18\x03\x54\x6F\x70\x02\x10\x05\x57\x69\x64\x74\x68\x02\x54\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x0C\xE8\x87\xAA\xE5\x8A\xA8\xE5\x90\xAF\xE5\x8A\xA8\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x00\x00\x00\x09\x54\x43\x68\x65\x63\x6B\x42\x6F\x78\x0B\x53\x79\x73\x50\x72\x6F\x78\x79\x43\x68\x6B\x04\x4C\x65\x66\x74\x02\x37\x06\x48\x65\x69\x67\x68\x74\x02\x18\x03\x54\x6F\x70\x02\x40\x05\x57\x69\x64\x74\x68\x02\x54\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x0C\xE7\xB3\xBB\xE7\xBB\x9F\xE4\xBB\xA3\xE7\x90\x86\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x01\x00\x00\x05\x54\x45\x64\x69\x74\x08\x50\x6F\x72\x74\x45\x64\x69\x74\x04\x4C\x65\x66\x74\x03\xD0\x00\x06\x48\x65\x69\x67\x68\x74\x02\x1C\x03\x54\x6F\x70\x02\x3C\x05\x57\x69\x64\x74\x68\x03\x98\x00\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x02\x04\x54\x65\x78\x74\x06\x0E\x31\x32\x37\x2E\x30\x2E\x30\x2E\x31\x3A\x38\x30\x38\x30\x00\x00\x06\x54\x4C\x61\x62\x65\x6C\x09\x50\x6F\x72\x74\x4C\x61\x62\x65\x6C\x04\x4C\x65\x66\x74\x03\xA8\x00\x06\x48\x65\x69\x67\x68\x74\x02\x14\x03\x54\x6F\x70\x02\x42\x05\x57\x69\x64\x74\x68\x02\x1E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE7\xAB\xAF\xE5\x8F\xA3\x0B\x50\x61\x72\x65\x6E\x74\x43\x6F\x6C\x6F\x72\x08\x00\x00\x07\x54\x42\x75\x74\x74\x6F\x6E\x0A\x43\x6F\x6E\x66\x69\x72\x6D\x42\x74\x6E\x04\x4C\x65\x66\x74\x02\x48\x06\x48\x65\x69\x67\x68\x74\x02\x1F\x03\x54\x6F\x70\x02\x73\x05\x57\x69\x64\x74\x68\x02\x5E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE7\xA1\xAE\xE5\xAE\x9A\x07\x4F\x6E\x43\x6C\x69\x63\x6B\x07\x0F\x43\x6F\x6E\x66\x69\x72\x6D\x42\x74\x6E\x43\x6C\x69\x63\x6B\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x03\x00\x00\x07\x54\x42\x75\x74\x74\x6F\x6E\x09\x43\x61\x6E\x63\x65\x6C\x42\x74\x6E\x04\x4C\x65\x66\x74\x03\x18\x01\x06\x48\x65\x69\x67\x68\x74\x02\x1F\x03\x54\x6F\x70\x02\x73\x05\x57\x69\x64\x74\x68\x02\x5E\x07\x43\x61\x70\x74\x69\x6F\x6E\x06\x06\xE5\x8F\x96\xE6\xB6\x88\x07\x4F\x6E\x43\x6C\x69\x63\x6B\x07\x0E\x43\x61\x6E\x63\x65\x6C\x42\x74\x6E\x43\x6C\x69\x63\x6B\x08\x54\x61\x62\x4F\x72\x64\x65\x72\x02\x04\x00\x00\x00")
30 |
--------------------------------------------------------------------------------
/SettingFormImpl.go:
--------------------------------------------------------------------------------
1 | // 由res2go自动生成。
2 | // 在这里写你的事件。
3 |
4 | package main
5 |
6 | import (
7 | "github.com/ying32/govcl/vcl"
8 | "github.com/ying32/govcl/vcl/types"
9 | )
10 |
11 | //::private::
12 | type TSettingFormFields struct {
13 | }
14 |
15 | func (f *TSettingForm) OnConfirmBtnClick(sender vcl.IObject) {
16 | var isAutoRunFlag = true
17 | var isSysProxyFlag = true
18 | if SettingForm.AutoStartChk.Checked() {
19 | isAutoRunFlag = setAutoRun()
20 | } else {
21 | isAutoRunFlag = unSetAutoRun()
22 | }
23 | addr := SettingForm.PortEdit.Text()
24 | if SettingForm.SysProxyChk.Checked() {
25 | isSysProxyFlag = setSysProxy(addr)
26 | } else {
27 | isSysProxyFlag = unsetSysProxy(addr)
28 | }
29 | /*cfg, _ := goconfig.LoadConfigFile(mainConfigName)
30 | cfg.SetValue("common", "autoRun", strconv.FormatBool(SettingForm.AutoStartChk.Checked()))
31 | cfg.SetValue("common", "sysProxy", strconv.FormatBool(SettingForm.SysProxyChk.Checked()))
32 | cfg.SetValue("common", "sysProxyAddr", addr)
33 | _ = goconfig.SaveConfigFile(cfg, mainConfigName)*/
34 | if isAutoRunFlag && isSysProxyFlag {
35 | vcl.MessageDlg("设置成功", types.MtInformation, types.MbOK)
36 | SettingForm.Close()
37 | } else {
38 | vcl.MessageDlg("设置失败,请尝试以管理员身份运行", types.MtError, types.MbOK)
39 | }
40 | }
41 |
42 | func (f *TSettingForm) OnCancelBtnClick(sender vcl.IObject) {
43 | SettingForm.Close()
44 | }
45 |
--------------------------------------------------------------------------------
/_v_images/20181205123101138_30945.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yangjinhe/goproxy-gui/b39c69d72aafc54d28a6930c6f7c1b5d56169e8e/_v_images/20181205123101138_30945.png
--------------------------------------------------------------------------------
/_v_images/20181205123142504_31841.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yangjinhe/goproxy-gui/b39c69d72aafc54d28a6930c6f7c1b5d56169e8e/_v_images/20181205123142504_31841.png
--------------------------------------------------------------------------------
/_v_images/20181205123154027_31227.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yangjinhe/goproxy-gui/b39c69d72aafc54d28a6930c6f7c1b5d56169e8e/_v_images/20181205123154027_31227.png
--------------------------------------------------------------------------------
/_v_images/20181205123203611_16017.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yangjinhe/goproxy-gui/b39c69d72aafc54d28a6930c6f7c1b5d56169e8e/_v_images/20181205123203611_16017.png
--------------------------------------------------------------------------------
/goproxy.db:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yangjinhe/goproxy-gui/b39c69d72aafc54d28a6930c6f7c1b5d56169e8e/goproxy.db
--------------------------------------------------------------------------------
/govcl.syso:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yangjinhe/goproxy-gui/b39c69d72aafc54d28a6930c6f7c1b5d56169e8e/govcl.syso
--------------------------------------------------------------------------------
/main.go:
--------------------------------------------------------------------------------
1 | // 由res2go自动生成。
2 | package main
3 |
4 | import (
5 | "github.com/ying32/govcl/vcl"
6 | )
7 |
8 | func main() {
9 | vcl.Application.Initialize()
10 | vcl.Application.CreateForm(mainFormBytes, &MainForm)
11 | vcl.Application.CreateForm(newProxyServerFormBytes, &NewProxyServerForm)
12 | vcl.Application.CreateForm(addMappingFormBytes, &AddMappingForm)
13 | vcl.Application.CreateForm(settingFormBytes, &SettingForm)
14 | initDb()
15 | initListView()
16 | vcl.Application.Run()
17 | }
18 |
--------------------------------------------------------------------------------
/syso/build.bat:
--------------------------------------------------------------------------------
1 | windres.exe -o ..\govcl.syso govcl.rc
--------------------------------------------------------------------------------
/syso/govcl.rc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yangjinhe/goproxy-gui/b39c69d72aafc54d28a6930c6f7c1b5d56169e8e/syso/govcl.rc
--------------------------------------------------------------------------------
/syso/main.manifest:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | True/PM
6 |
7 |
8 |
9 |
10 |
17 |
18 |
19 |
20 |
21 |
22 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
--------------------------------------------------------------------------------
/util.go:
--------------------------------------------------------------------------------
1 | package main
2 |
3 | import (
4 | "database/sql"
5 | "fmt"
6 | "github.com/ProtonMail/go-autostart"
7 | "github.com/getlantern/sysproxy"
8 | _ "github.com/mattn/go-sqlite3"
9 | "log"
10 | "os"
11 | "path/filepath"
12 | "strings"
13 | )
14 |
15 | var mainDbFileName = "goproxy.db"
16 |
17 | var proxyInfoSql = `CREATE TABLE "proxy_info" (
18 | "id" INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
19 | "name" TEXT(128),
20 | "proxyType" TEXT(10),
21 | "remoteIp" TEXT(20),
22 | "remotePort" TEXT(6),
23 | "remoteProtocol" TEXT(4),
24 | "localIp" TEXT(20),
25 | "localPort" TEXT(6),
26 | "localProtocol" TEXT(4),
27 | "crtLocation" TEXT(128),
28 | "keyLocation" TEXT(128),
29 | "sshUserName" TEXT(128),
30 | "sshPwd" TEXT(128),
31 | "sshPrivateKey" TEXT(128),
32 | "kcpPwd" TEXT(128),
33 | "dns" TEXT(20),
34 | "dnsTtl" TEXT(20)
35 | );`
36 | var proxyInfoIdxSql = `CREATE UNIQUE INDEX "idx_proxy_info_id"
37 | ON "proxy_info" (
38 | "id"
39 | );`
40 |
41 | var tunnelMappingSql = `CREATE TABLE "tunnel_mapping" (
42 | "id" INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
43 | "info_id" INTEGER,
44 | "type" TEXT(10),
45 | "localPort" TEXT(128),
46 | "remotePort" TEXT(128)
47 | );`
48 | var tunnelMappingIdxSql = `CREATE UNIQUE INDEX "idx_mapping_id"
49 | ON "tunnel_mapping" (
50 | "id"
51 | );`
52 |
53 | var insertProxyInfoSql = `insert into "proxy_info" ("name", "proxyType",
54 | "remoteIp", "remotePort", "remoteProtocol", "localIp", "localPort", "localProtocol",
55 | "crtLocation", "keyLocation", "sshUserName", "sshPwd", "sshPrivateKey", "kcpPwd",
56 | "dns", "dnsTtl") values (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)`
57 |
58 | var insertTunnelMappingSql = `insert into "tunnel_mapping" ("info_id", "protocol_type", "localPort", "remotePort") values (?, ?, ?, ?)`
59 |
60 | func initDb() {
61 |
62 | b, _ := PathExists(mainDbFileName)
63 | if !b {
64 | db, err := sql.Open("sqlite3", mainDbFileName)
65 | checkErr(err)
66 | _, err = db.Exec(proxyInfoSql)
67 | checkErr(err)
68 | _, err = db.Exec(proxyInfoIdxSql)
69 | checkErr(err)
70 | _, err = db.Exec(tunnelMappingSql)
71 | checkErr(err)
72 | _, err = db.Exec(tunnelMappingIdxSql)
73 | checkErr(err)
74 | }
75 | }
76 |
77 | type ProxyInfo struct {
78 | id int64
79 | name string
80 | proxyType string
81 | remoteIp string
82 | remotePort string
83 | remoteProtocol string
84 | localIp string
85 | localPort string
86 | localProtocol string
87 | crtLocation string
88 | keyLocation string
89 | sshUserName string
90 | sshPwd string
91 | sshPrivateKey string
92 | kcpPwd string
93 | dns string
94 | dnsTtl string
95 | state int64
96 | }
97 |
98 | type TunnelMapping struct {
99 | id int64
100 | infoId int64
101 | protocolType string
102 | localPort string
103 | remotePort string
104 | }
105 |
106 | func initListView() {
107 | MainForm.ListView1.SetRowSelect(true)
108 | b, err := PathExists(mainDbFileName)
109 | if err != nil {
110 | panic("错误")
111 | }
112 | if !b {
113 | initDb()
114 | } else {
115 | db, err := sql.Open("sqlite3", mainDbFileName)
116 | checkErr(err)
117 | result, _ := db.Query("select * from proxy_info")
118 | MainForm.ListView1.Items().BeginUpdate()
119 | for result.Next() {
120 | p := new(ProxyInfo)
121 | err = result.Scan(&p.id, &p.name, &p.proxyType, &p.remoteIp, &p.remotePort,
122 | &p.remoteProtocol, &p.localIp, &p.localPort, &p.localProtocol, &p.crtLocation,
123 | &p.keyLocation, &p.sshUserName, &p.sshPwd, &p.sshPrivateKey, &p.kcpPwd, &p.dns, &p.dnsTtl, &p.state)
124 | checkErr(err)
125 | listItem := MainForm.ListView1.Items().Add()
126 | listItem.SetCaption(string(p.id))
127 | listItem.SubItems().Add(p.name)
128 | listItem.SubItems().Add(p.remoteIp)
129 | listItem.SubItems().Add(p.remotePort)
130 | listItem.SubItems().Add(p.remoteProtocol)
131 | listItem.SubItems().Add(p.localProtocol)
132 | listItem.SubItems().Add(p.localPort)
133 | listItem.SubItems().Add("未启动")
134 | }
135 | MainForm.ListView1.Items().EndUpdate()
136 | }
137 | }
138 |
139 | func addNewProxyInfo(proxyInfo ProxyInfo) (id int64) {
140 | db, err := sql.Open("sqlite3", mainDbFileName)
141 | checkErr(err)
142 | stmt, err := db.Prepare(insertProxyInfoSql)
143 | checkErr(err)
144 | result, err := stmt.Exec(proxyInfo.name, proxyInfo.proxyType, proxyInfo.remoteIp, proxyInfo.remotePort, proxyInfo.remoteProtocol,
145 | proxyInfo.localIp, proxyInfo.localPort, proxyInfo.localProtocol, proxyInfo.crtLocation, proxyInfo.keyLocation,
146 | proxyInfo.sshUserName, proxyInfo.sshPwd, proxyInfo.sshPrivateKey, proxyInfo.kcpPwd, proxyInfo.dns,
147 | proxyInfo.dnsTtl)
148 | checkErr(err)
149 | id, _ = result.LastInsertId()
150 | return id
151 | }
152 |
153 | func addNewTunnelMapping(tunnelMapping TunnelMapping) (id int64) {
154 | db, err := sql.Open("sqlite3", mainDbFileName)
155 | checkErr(err)
156 | stmt, err := db.Prepare(insertTunnelMappingSql)
157 | checkErr(err)
158 | result, err := stmt.Exec(tunnelMapping.infoId, tunnelMapping.protocolType, tunnelMapping.localPort, tunnelMapping.remotePort)
159 | checkErr(err)
160 | id, _ = result.LastInsertId()
161 | return id
162 | }
163 |
164 | func PathExists(path string) (bool, error) {
165 | _, err := os.Stat(path)
166 | if err == nil {
167 | return true, nil
168 | }
169 | if os.IsNotExist(err) {
170 | return false, nil
171 | }
172 | return false, err
173 | }
174 |
175 | func setAutoRun() bool {
176 | dir, err := filepath.Abs(filepath.Dir(os.Args[0]))
177 | if err != nil {
178 | log.Fatal(err)
179 | return false
180 | }
181 | fmt.Println(dir)
182 | split := strings.Split(os.Args[0], string(os.PathSeparator))
183 | exeName := ""
184 | if len(split) > 0 {
185 | fmt.Println(split[len(split)-1])
186 | exeName = split[len(split)-1]
187 | } else {
188 | exeName = os.Args[0]
189 | }
190 | fmt.Println(exeName)
191 |
192 | var exec = dir + string(os.PathSeparator) + exeName
193 | app := &autostart.App{
194 | Name: "goproxy-gui",
195 | DisplayName: "goproxy的图形界面",
196 | Exec: []string{exec},
197 | }
198 |
199 | if app.IsEnabled() {
200 | log.Println("App is already enabled, removing it...")
201 | } else {
202 | log.Println("Enabling app...")
203 |
204 | if err := app.Enable(); err != nil {
205 | log.Fatal(err)
206 | return false
207 | }
208 | }
209 | return true
210 | }
211 |
212 | func unSetAutoRun() bool {
213 | dir, err := filepath.Abs(filepath.Dir(os.Args[0]))
214 | if err != nil {
215 | log.Fatal(err)
216 | return false
217 | }
218 | fmt.Println(dir)
219 | split := strings.Split(os.Args[0], string(os.PathSeparator))
220 | exeName := ""
221 | if len(split) > 0 {
222 | fmt.Println(split[len(split)-1])
223 | exeName = split[len(split)-1]
224 | } else {
225 | exeName = os.Args[0]
226 | }
227 | fmt.Println(exeName)
228 |
229 | var exec = dir + string(os.PathSeparator) + exeName
230 | app := &autostart.App{
231 | Name: "goproxy-gui",
232 | DisplayName: "goproxy的图形界面",
233 | Exec: []string{exec},
234 | }
235 |
236 | if app.IsEnabled() {
237 | log.Println("App is already enabled, removing it...")
238 |
239 | if err := app.Disable(); err != nil {
240 | log.Fatal(err)
241 | return false
242 | }
243 | }
244 | return true
245 | }
246 |
247 | func setSysProxy(addr string) bool {
248 | helperFullPath := "sysproxy-cmd"
249 | iconFullPath, _ := filepath.Abs("./icon.png")
250 | log.Println("Using icon at %v", iconFullPath)
251 | err := sysproxy.EnsureHelperToolPresent(helperFullPath, "Input your password and save the world!", iconFullPath)
252 | if err != nil {
253 | fmt.Printf("Error EnsureHelperToolPresent: %s\n", err)
254 | return false
255 | }
256 | _, err1 := sysproxy.On(addr)
257 | if err1 != nil {
258 | fmt.Printf("Error set proxy: %s\n", err)
259 | return false
260 | }
261 | return true
262 | }
263 |
264 | func unsetSysProxy(addr string) bool {
265 | helperFullPath := "sysproxy-cmd"
266 | iconFullPath, _ := filepath.Abs("./icon.png")
267 | //log.Println("Using icon at %v", iconFullPath)
268 | err := sysproxy.EnsureHelperToolPresent(helperFullPath, "Input your password and save the world!", iconFullPath)
269 | if err != nil {
270 | fmt.Printf("Error EnsureHelperToolPresent: %s\n", err)
271 | return false
272 | }
273 | off, err1 := sysproxy.On(addr)
274 | if err1 != nil {
275 | fmt.Printf("Error set proxy: %s\n", err1)
276 | return false
277 | }
278 | err2 := off()
279 | if err2 != nil {
280 | fmt.Printf("Error unset proxy: %s\n", err2)
281 | return false
282 | }
283 | return true
284 | }
285 |
286 | func checkErr(err error) {
287 | if err != nil {
288 | panic(err)
289 | }
290 | }
291 |
--------------------------------------------------------------------------------