Compare commits

...

No commits in common. "master" and "pristine-tar" have entirely different histories.

1858 changed files with 5 additions and 567758 deletions

View File

@ -1,10 +0,0 @@
Changes proposed in this pull request:
Your great patch is much appreciated. We are considering to apply your patch into the SoftEther VPN main tree.
SoftEther VPN Patch Acceptance Policy:
http://www.softether.org/5-download/src/9.patch
You have two options which are described on the above policy.
Could you please choose either option 1 or 2, and specify it clearly on the reply?

View File

@ -1 +0,0 @@
Please see: https://github.com/SoftEtherVPN/SoftEtherVPN/blob/master/AUTHORS.TXT

View File

@ -1,125 +0,0 @@
How to build SoftEther VPN for UNIX
===================================
Requirements
------------
You need to install the following software to build SoftEther VPN for UNIX.
- Linux, FreeBSD, Solaris or Mac OS X.
- GNU Compiler Collectipon (gcc) and binary utilities.
- GNU Make (gmake).
- GNU C Library (glibc).
- POSIX Threads (pthread).
- OpenSSL (crypto, ssl).
- libiconv.
- readline.
- ncurses.
For example, the following commands help you to install the above programs
on Fedora or CentOS Linux:
$ yum -y groupinstall "Development Tools"
$ yum -y install readline-devel ncurses-devel openssl-devel
How to Build
------------
To build the programs from the source code, run the following commands:
$ ./configure
$ make
If any error occurs, please check the above requirements.
How to Install SoftEther VPN Server, Bridge or Client
-----------------------------------------------------
To install the vpnserver, vpnbridge and vpnclient programs into the
/usr/bin directory, run the following as the root user:
# make install
After the installation will complete successfully:
- Execute 'vpnserver start' to run the SoftEther VPN Server background service.
- Execute 'vpnbridge start' to run the SoftEther VPN Bridge background service.
- Execute 'vpnclient start' to run the SoftEther VPN Client background service.
- Execute 'vpncmd' to run SoftEther VPN Command-Line Utility to configure
VPN Server, VPN Bridge or VPN Client.
- You can also use VPN Server/Client Manager GUI Tool on other Windows PC to
connect to VPN services remotely.
You can download the GUI Tools from https://www.softether-download.com/.
How to Run SoftEther VPN Server for Test
----------------------------------------
To start the SoftEther VPN Server background service, run the following:
$ bin/vpnserver/vpnserver start
To stop the service, run the following:
$ bin/vpnserver/vpnserver stop
To configure the running SoftEther VPN Server service,
you can use SoftEther VPN Command Line Management Utility as following:
$ bin/vpncmd/vpncmd
Or you can also use VPN Server Manager GUI Tool on other Windows PC to
connect to the VPN Server remotely. You can download the GUI Tool
from https://www.softether-download.com/.
How to Run SoftEther VPN Bridge for Test
----------------------------------------
To start the SoftEther VPN Bridge background service, run the following:
$ bin/vpnbridge/vpnbridge start
To stop the service, run the following:
$ bin/vpnbridge/vpnbridge stop
To configure the running SoftEther VPN Bridge service,
you can use SoftEther VPN Command Line Management Utility as following:
$ bin/vpncmd/vpncmd
Or you can also use VPN Server Manager GUI Tool on other Windows PC to
connect to the VPN Bridge remotely. You can download the GUI Tool
from https://www.softether-download.com/.
How to Run SoftEther VPN Client for Test
----------------------------------------
To start the SoftEther VPN Client background service, run the following:
$ bin/vpnclient/vpnclient start
To stop the service, run the following:
$ bin/vpnclient/vpnclient stop
To configure the running SoftEther VPN Client service,
you can use SoftEther VPN Command Line Management Utility as following:
$ bin/vpncmd/vpncmd
Or you can also use VPN Client Manager GUI Tool on other Windows PC to
connect to the VPN Client remotely. You can download the GUI Tool
from https://www.softether-download.com/.
************************************
Thank You Using SoftEther VPN !
By SoftEther VPN Open-Source Project
https://www.softether.org/

View File

@ -1,44 +0,0 @@
How to build SoftEther VPN for Windows
======================================
Requirements
------------
You need to install the following software to build SoftEther VPN for Windows.
- Microsoft Windows XP, Vista, 7, 8 or later.
- Microsoft Visual Studio 2008 with the latest SP (SP1 9.0.30729.4462 QFE).
Make sure that you installed the x64 compiler and build tools.
* Note:
Visual Studio 2008 SP1 is required to build SoftEther VPN on Windows.
Please make sure that VS2008 'SP1' is installed.
Visual Studio 2010, 2012 or 2013 is currently not supported.
Visual Studio 2008 Express Edition is not supported.
Standard Edition, Professional Edition, Team System or Team Suite is
required.
Full Build Instructions
-----------------------
The following steps will build all SoftEther VPN program files, and also build
the installer packages of SoftEther VPN. It is very easy.
1. Run the "BuildAll.cmd" batch file in the "src" directory.
2. Wait until the building process will complete.
3. The built files are stored on the "output" directory.
Partly Build, Debug or Development Instructions on Visual Studio 2008
---------------------------------------------------------------------
If you are a programmer, you can open the SoftEther VPN solution file
with Visual Studio 2008 to customize. Open "src\SEVPN.sln" and enjoy it.
************************************
Thank You Using SoftEther VPN !
By SoftEther VPN Open-Source Project
https://www.softether.org/

View File

@ -1,10 +0,0 @@
ChangeLog of SoftEther VPN
--------------------------
The ChangeLog of SoftEther VPN is on our web site:
https://www.softether.org/5-download/history
(In Japanese: https://ja.softether.org/5-download/history)
Enjoy it!

View File

@ -1,10 +0,0 @@
ChangeLog of SoftEther VPN
--------------------------
The ChangeLog of SoftEther VPN is on our web site:
https://www.softether.org/5-download/history
(In Japanese: https://ja.softether.org/5-download/history)
Enjoy it!

243
LICENSE
View File

@ -1,243 +0,0 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
Copyright (c) all contributors on SoftEther VPN project in GitHub.
Copyright (c) Daiyuu Nobori, SoftEther Project at University of Tsukuba,
and SoftEther Corporation.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
DISCLAIMER
==========
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
THIS SOFTWARE IS DEVELOPED IN JAPAN, AND DISTRIBUTED FROM JAPAN, UNDER
JAPANESE LAWS. YOU MUST AGREE IN ADVANCE TO USE, COPY, MODIFY, MERGE, PUBLISH,
DISTRIBUTE, SUBLICENSE, AND/OR SELL COPIES OF THIS SOFTWARE, THAT ANY
JURIDICAL DISPUTES WHICH ARE CONCERNED TO THIS SOFTWARE OR ITS CONTENTS,
AGAINST US (SOFTETHER PROJECT, SOFTETHER CORPORATION, DAIYUU NOBORI OR OTHER
SUPPLIERS), OR ANY JURIDICAL DISPUTES AGAINST US WHICH ARE CAUSED BY ANY KIND
OF USING, COPYING, MODIFYING, MERGING, PUBLISHING, DISTRIBUTING, SUBLICENSING,
AND/OR SELLING COPIES OF THIS SOFTWARE SHALL BE REGARDED AS BE CONSTRUED AND
CONTROLLED BY JAPANESE LAWS, AND YOU MUST FURTHER CONSENT TO EXCLUSIVE
JURISDICTION AND VENUE IN THE COURTS SITTING IN TOKYO, JAPAN. YOU MUST WAIVE
ALL DEFENSES OF LACK OF PERSONAL JURISDICTION AND FORUM NON CONVENIENS.
PROCESS MAY BE SERVED ON EITHER PARTY IN THE MANNER AUTHORIZED BY APPLICABLE
LAW OR COURT RULE.
USE ONLY IN JAPAN. DO NOT USE THIS SOFTWARE IN ANOTHER COUNTRY UNLESS YOU HAVE
A CONFIRMATION THAT THIS SOFTWARE DOES NOT VIOLATE ANY CRIMINAL LAWS OR CIVIL
RIGHTS IN THAT PARTICULAR COUNTRY. USING THIS SOFTWARE IN OTHER COUNTRIES IS
COMPLETELY AT YOUR OWN RISK. THE SOFTETHER VPN PROJECT HAS DEVELOPED AND
DISTRIBUTED THIS SOFTWARE TO COMPLY ONLY WITH THE JAPANESE LAWS AND EXISTING
CIVIL RIGHTS INCLUDING PATENTS WHICH ARE SUBJECTS APPLY IN JAPAN. OTHER
COUNTRIES' LAWS OR CIVIL RIGHTS ARE NONE OF OUR CONCERNS NOR RESPONSIBILITIES.
WE HAVE NEVER INVESTIGATED ANY CRIMINAL REGULATIONS, CIVIL LAWS OR
INTELLECTUAL PROPERTY RIGHTS INCLUDING PATENTS IN ANY OF OTHER 200+ COUNTRIES
AND TERRITORIES. BY NATURE, THERE ARE 200+ REGIONS IN THE WORLD, WITH
DIFFERENT LAWS. IT IS IMPOSSIBLE TO VERIFY EVERY COUNTRIES' LAWS, REGULATIONS
AND CIVIL RIGHTS TO MAKE THE SOFTWARE COMPLY WITH ALL COUNTRIES' LAWS BY THE
PROJECT. EVEN IF YOU WILL BE SUED BY A PRIVATE ENTITY OR BE DAMAGED BY A
PUBLIC SERVANT IN YOUR COUNTRY, THE DEVELOPERS OF THIS SOFTWARE WILL NEVER BE
LIABLE TO RECOVER OR COMPENSATE SUCH DAMAGES, CRIMINAL OR CIVIL
RESPONSIBILITIES. NOTE THAT THIS LINE IS NOT LICENSE RESTRICTION BUT JUST A
STATEMENT FOR WARNING AND DISCLAIMER.
READ AND UNDERSTAND THE 'src/WARNING.TXT' FILE BEFORE USING THIS SOFTWARE.
SOME SOFTWARE PROGRAMS FROM THIRD PARTIES ARE INCLUDED ON THIS SOFTWARE WITH
LICENSE CONDITIONS WHICH ARE DESCRIBED ON THE 'src/THIRD_PARTY.TXT' FILE.

View File

@ -1,243 +0,0 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
Copyright (c) all contributors on SoftEther VPN project in GitHub.
Copyright (c) Daiyuu Nobori, SoftEther Project at University of Tsukuba,
and SoftEther Corporation.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
DISCLAIMER
==========
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
THIS SOFTWARE IS DEVELOPED IN JAPAN, AND DISTRIBUTED FROM JAPAN, UNDER
JAPANESE LAWS. YOU MUST AGREE IN ADVANCE TO USE, COPY, MODIFY, MERGE, PUBLISH,
DISTRIBUTE, SUBLICENSE, AND/OR SELL COPIES OF THIS SOFTWARE, THAT ANY
JURIDICAL DISPUTES WHICH ARE CONCERNED TO THIS SOFTWARE OR ITS CONTENTS,
AGAINST US (SOFTETHER PROJECT, SOFTETHER CORPORATION, DAIYUU NOBORI OR OTHER
SUPPLIERS), OR ANY JURIDICAL DISPUTES AGAINST US WHICH ARE CAUSED BY ANY KIND
OF USING, COPYING, MODIFYING, MERGING, PUBLISHING, DISTRIBUTING, SUBLICENSING,
AND/OR SELLING COPIES OF THIS SOFTWARE SHALL BE REGARDED AS BE CONSTRUED AND
CONTROLLED BY JAPANESE LAWS, AND YOU MUST FURTHER CONSENT TO EXCLUSIVE
JURISDICTION AND VENUE IN THE COURTS SITTING IN TOKYO, JAPAN. YOU MUST WAIVE
ALL DEFENSES OF LACK OF PERSONAL JURISDICTION AND FORUM NON CONVENIENS.
PROCESS MAY BE SERVED ON EITHER PARTY IN THE MANNER AUTHORIZED BY APPLICABLE
LAW OR COURT RULE.
USE ONLY IN JAPAN. DO NOT USE THIS SOFTWARE IN ANOTHER COUNTRY UNLESS YOU HAVE
A CONFIRMATION THAT THIS SOFTWARE DOES NOT VIOLATE ANY CRIMINAL LAWS OR CIVIL
RIGHTS IN THAT PARTICULAR COUNTRY. USING THIS SOFTWARE IN OTHER COUNTRIES IS
COMPLETELY AT YOUR OWN RISK. THE SOFTETHER VPN PROJECT HAS DEVELOPED AND
DISTRIBUTED THIS SOFTWARE TO COMPLY ONLY WITH THE JAPANESE LAWS AND EXISTING
CIVIL RIGHTS INCLUDING PATENTS WHICH ARE SUBJECTS APPLY IN JAPAN. OTHER
COUNTRIES' LAWS OR CIVIL RIGHTS ARE NONE OF OUR CONCERNS NOR RESPONSIBILITIES.
WE HAVE NEVER INVESTIGATED ANY CRIMINAL REGULATIONS, CIVIL LAWS OR
INTELLECTUAL PROPERTY RIGHTS INCLUDING PATENTS IN ANY OF OTHER 200+ COUNTRIES
AND TERRITORIES. BY NATURE, THERE ARE 200+ REGIONS IN THE WORLD, WITH
DIFFERENT LAWS. IT IS IMPOSSIBLE TO VERIFY EVERY COUNTRIES' LAWS, REGULATIONS
AND CIVIL RIGHTS TO MAKE THE SOFTWARE COMPLY WITH ALL COUNTRIES' LAWS BY THE
PROJECT. EVEN IF YOU WILL BE SUED BY A PRIVATE ENTITY OR BE DAMAGED BY A
PUBLIC SERVANT IN YOUR COUNTRY, THE DEVELOPERS OF THIS SOFTWARE WILL NEVER BE
LIABLE TO RECOVER OR COMPENSATE SUCH DAMAGES, CRIMINAL OR CIVIL
RESPONSIBILITIES. NOTE THAT THIS LINE IS NOT LICENSE RESTRICTION BUT JUST A
STATEMENT FOR WARNING AND DISCLAIMER.
READ AND UNDERSTAND THE 'src/WARNING.TXT' FILE BEFORE USING THIS SOFTWARE.
SOME SOFTWARE PROGRAMS FROM THIRD PARTIES ARE INCLUDED ON THIS SOFTWARE WITH
LICENSE CONDITIONS WHICH ARE DESCRIBED ON THE 'src/THIRD_PARTY.TXT' FILE.

221
README
View File

@ -1,221 +0,0 @@
SoftEther VPN (Stable Edition Repository)
- An Open-Source Cross-platform Multi-protocol VPN Program
https://www.softether.org/
We use GitHub as the primary official SoftEther VPN repository:
https://github.com/SoftEtherVPN/SoftEtherVPN_Stable/
This branch is officially managed by Daiyuu Nobori, the owner of
SoftEther VPN Project. Pull requests should be sent to the
Developer Edition Master Repository on
https://github.com/SoftEtherVPN/SoftEtherVPN
Source code packages (.zip and .tar.gz) and binary files are also available:
https://www.softether-download.com/
We accept your patches by the acceptance policy:
https://www.softether.org/5-download/src/9.patch
Copyright (c) all contributors on SoftEther VPN project in GitHub.
Copyright (c) Daiyuu Nobori, SoftEther Project at University of Tsukuba,
and SoftEther Corporation.
All rights reserved.
The development of SoftEther VPN was supported by the MITOH Project,
a research and development project by Japanese Government,
subsidized by METI (Ministry of Economy, Trade and Industry of Japan),
administrated by IPA (Information Promotion Agency, Japan).
https://www.ipa.go.jp/english/humandev/
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at:
http://www.apache.org/licenses/LICENSE-2.0
SoftEther VPN ("SoftEther" means "Software Ethernet") is one of the
world's most powerful and easy-to-use multi-protocol VPN software.
SoftEther VPN runs on Windows, Linux, Mac, FreeBSD and Solaris.
SoftEther VPN supports most of widely-used VPN protocols
including SSL-VPN, OpenVPN, IPsec, L2TP, MS-SSTP, L2TPv3 and EtherIP
by the single SoftEther VPN Server program.
More details on https://www.softether.org/.
SOFTETHER VPN ADVANTAGES
------------------------
- Supporting all popular VPN protocols by the single VPN server:
SSL-VPN (HTTPS)
OpenVPN
IPsec
L2TP
MS-SSTP
L2TPv3
EtherIP
- Free and open-source software.
- Easy to establish both remote-access and site-to-site VPN.
- SSL-VPN Tunneling on HTTPS to pass through NATs and firewalls.
- Revolutionary VPN over ICMP and VPN over DNS features.
- Resistance to highly-restricted firewall.
- Ethernet-bridging (L2) and IP-routing (L3) over VPN.
- Embedded dynamic-DNS and NAT-traversal so that no static nor
fixed IP address is required.
- AES 256-bit and RSA 4096-bit encryptions.
- Sufficient security features such as logging and firewall inner
VPN tunnel.
- User authentication with RADIUS and NT domain controllers.
- User authentication with X.509 client certificate.
- Packet logging.
- 1Gbps-class high-speed throughput performance with low memory and
CPU usage.
- Windows, Linux, Mac, Android, iPhone, iPad and Windows Phone are
supported.
- The OpenVPN clone function supports legacy OpenVPN clients.
- IPv4 / IPv6 dual-stack.
- The VPN server runs on Windows, Linux, FreeBSD, Solaris and Mac OS X.
- Configure All settings on GUI.
- Multi-languages (English, Japanese and Simplified-Chinese).
- No memory leaks. High quality stable codes, intended for long-term runs.
We always verify that there are no memory or resource leaks before
releasing the build.
- More details at https://www.softether.org/.
GETTING STARTED
---------------
Visit the SoftEther VPN Project official web site at first:
https://www.softether.org/
If you are not a developer, it is recommended to download the binary
installers from:
https://www.softether-download.com/
To build from the source,
see "BUILD_UNIX.TXT" or "BUILD_WINDOWS.TXT" files.
HOW TO DOWNLOAD THE LATEST SOURCE CODE PACKAGE
----------------------------------------------
Go to https://www.softether-download.com/ and you can find the latest
source-code package file in both .ZIP and .TAR.GZ format.
This is the easiest way to obtain the source code of SoftEther VPN.
HOW TO GET THE LATEST SOURCE CODE TREE FOR DEVELOPERS
-----------------------------------------------------
If you are an open-source developer, visit our GitHub repository:
https://github.com/SoftEtherVPN/SoftEtherVPN_Stable/
You can download the up-to-date source-code tree of SoftEther VPN
from GitHub. You may make your own fork project from our project.
The download and build instruction is following:
$ git clone https://github.com/SoftEtherVPN/SoftEtherVPN_Stable.git
$ cd SoftEtherVPN
$ ./configure
$ make
$ make install
TO CIRCUMVENT YOUR GOVERNMENT'S FIREWALL RESTRICTION
----------------------------------------------------
Because SoftEther VPN is overly strong tool to build a VPN tunnel,
some censorship governments want to block your access to the source code
of SoftEther VPN, by abusing their censorship firewalls.
To circumvent your censor's unjust restriction,
SoftEther VPN Project distributes the up-to-date source-code
on all the following open-source repositories:
- GitHub
https://github.com/SoftEtherVPN/SoftEtherVPN_Stable/
To fetch the source code from GitHub:
$ git clone https://github.com/SoftEtherVPN/SoftEtherVPN_Stable.git
We hope that you can reach one of the above URLs at least!
SOURCE CODE CONTRIBUTION
------------------------
Your contribution to SoftEther VPN Project is much appreciated.
Please send patches to us through GitHub.
Read the SoftEther VPN Patch Acceptance Policy in advance:
https://www.softether.org/5-download/src/9.patch
DEAR SECURITY EXPERTS
---------------------
If you find a bug or a security vulnerability please kindly inform us
about the problem immediately so that we can fix the security problem
to protect a lot of users around the world as soon as possible.
Our e-mail address for security reports is:
softether-vpn-security [at] softether.org
Please note that the above e-mail address is not a technical support
inquiry address. If you need technical assistance, please visit
https://www.softether.org/ and ask your question on the users forum.
DISCLAIMER
----------
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
THIS SOFTWARE IS DEVELOPED IN JAPAN, AND DISTRIBUTED FROM JAPAN,
UNDER JAPANESE LAWS. YOU MUST AGREE IN ADVANCE TO USE, COPY, MODIFY,
MERGE, PUBLISH, DISTRIBUTE, SUBLICENSE, AND/OR SELL COPIES OF THIS
SOFTWARE, THAT ANY JURIDICAL DISPUTES WHICH ARE CONCERNED TO THIS
SOFTWARE OR ITS CONTENTS, AGAINST US (SOFTETHER PROJECT, SOFTETHER
CORPORATION, DAIYUU NOBORI OR OTHER SUPPLIERS), OR ANY JURIDICAL
DISPUTES AGAINST US WHICH ARE CAUSED BY ANY KIND OF USING, COPYING,
MODIFYING, MERGING, PUBLISHING, DISTRIBUTING, SUBLICENSING, AND/OR
SELLING COPIES OF THIS SOFTWARE SHALL BE REGARDED AS BE CONSTRUED AND
CONTROLLED BY JAPANESE LAWS, AND YOU MUST FURTHER CONSENT TO
EXCLUSIVE JURISDICTION AND VENUE IN THE COURTS SITTING IN TOKYO,
JAPAN. YOU MUST WAIVE ALL DEFENSES OF LACK OF PERSONAL JURISDICTION
AND FORUM NON CONVENIENS. PROCESS MAY BE SERVED ON EITHER PARTY IN
THE MANNER AUTHORIZED BY APPLICABLE LAW OR COURT RULE.
USE ONLY IN JAPAN. DO NOT USE THIS SOFTWARE IN ANOTHER COUNTRY UNLESS
YOU HAVE A CONFIRMATION THAT THIS SOFTWARE DOES NOT VIOLATE ANY
CRIMINAL LAWS OR CIVIL RIGHTS IN THAT PARTICULAR COUNTRY. USING THIS
SOFTWARE IN OTHER COUNTRIES IS COMPLETELY AT YOUR OWN RISK. THE
SOFTETHER VPN PROJECT HAS DEVELOPED AND DISTRIBUTED THIS SOFTWARE TO
COMPLY ONLY WITH THE JAPANESE LAWS AND EXISTING CIVIL RIGHTS INCLUDING
PATENTS WHICH ARE SUBJECTS APPLY IN JAPAN. OTHER COUNTRIES' LAWS OR
CIVIL RIGHTS ARE NONE OF OUR CONCERNS NOR RESPONSIBILITIES. WE HAVE
NEVER INVESTIGATED ANY CRIMINAL REGULATIONS, CIVIL LAWS OR
INTELLECTUAL PROPERTY RIGHTS INCLUDING PATENTS IN ANY OF OTHER 200+
COUNTRIES AND TERRITORIES. BY NATURE, THERE ARE 200+ REGIONS IN THE
WORLD, WITH DIFFERENT LAWS. IT IS IMPOSSIBLE TO VERIFY EVERY
COUNTRIES' LAWS, REGULATIONS AND CIVIL RIGHTS TO MAKE THE SOFTWARE
COMPLY WITH ALL COUNTRIES' LAWS BY THE PROJECT. EVEN IF YOU WILL BE
SUED BY A PRIVATE ENTITY OR BE DAMAGED BY A PUBLIC SERVANT IN YOUR
COUNTRY, THE DEVELOPERS OF THIS SOFTWARE WILL NEVER BE LIABLE TO
RECOVER OR COMPENSATE SUCH DAMAGES, CRIMINAL OR CIVIL
RESPONSIBILITIES. NOTE THAT THIS LINE IS NOT LICENSE RESTRICTION BUT
JUST A STATEMENT FOR WARNING AND DISCLAIMER.
READ AND UNDERSTAND THE 'WARNING.TXT' FILE BEFORE USING THIS SOFTWARE.
SOME SOFTWARE PROGRAMS FROM THIRD PARTIES ARE INCLUDED ON THIS SOFTWARE
WITH LICENSE CONDITIONS WHICH ARE DESCRIBED ON THE 'THIRD_PARTY.TXT' FILE.

View File

@ -1,221 +0,0 @@
SoftEther VPN (Stable Edition Repository)
- An Open-Source Cross-platform Multi-protocol VPN Program
https://www.softether.org/
We use GitHub as the primary official SoftEther VPN repository:
https://github.com/SoftEtherVPN/SoftEtherVPN_Stable/
This branch is officially managed by Daiyuu Nobori, the owner of
SoftEther VPN Project. Pull requests should be sent to the
Developer Edition Master Repository on
https://github.com/SoftEtherVPN/SoftEtherVPN
Source code packages (.zip and .tar.gz) and binary files are also available:
https://www.softether-download.com/
We accept your patches by the acceptance policy:
https://www.softether.org/5-download/src/9.patch
Copyright (c) all contributors on SoftEther VPN project in GitHub.
Copyright (c) Daiyuu Nobori, SoftEther Project at University of Tsukuba,
and SoftEther Corporation.
All rights reserved.
The development of SoftEther VPN was supported by the MITOH Project,
a research and development project by Japanese Government,
subsidized by METI (Ministry of Economy, Trade and Industry of Japan),
administrated by IPA (Information Promotion Agency, Japan).
https://www.ipa.go.jp/english/humandev/
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at:
http://www.apache.org/licenses/LICENSE-2.0
SoftEther VPN ("SoftEther" means "Software Ethernet") is one of the
world's most powerful and easy-to-use multi-protocol VPN software.
SoftEther VPN runs on Windows, Linux, Mac, FreeBSD and Solaris.
SoftEther VPN supports most of widely-used VPN protocols
including SSL-VPN, OpenVPN, IPsec, L2TP, MS-SSTP, L2TPv3 and EtherIP
by the single SoftEther VPN Server program.
More details on https://www.softether.org/.
SOFTETHER VPN ADVANTAGES
------------------------
- Supporting all popular VPN protocols by the single VPN server:
SSL-VPN (HTTPS)
OpenVPN
IPsec
L2TP
MS-SSTP
L2TPv3
EtherIP
- Free and open-source software.
- Easy to establish both remote-access and site-to-site VPN.
- SSL-VPN Tunneling on HTTPS to pass through NATs and firewalls.
- Revolutionary VPN over ICMP and VPN over DNS features.
- Resistance to highly-restricted firewall.
- Ethernet-bridging (L2) and IP-routing (L3) over VPN.
- Embedded dynamic-DNS and NAT-traversal so that no static nor
fixed IP address is required.
- AES 256-bit and RSA 4096-bit encryptions.
- Sufficient security features such as logging and firewall inner
VPN tunnel.
- User authentication with RADIUS and NT domain controllers.
- User authentication with X.509 client certificate.
- Packet logging.
- 1Gbps-class high-speed throughput performance with low memory and
CPU usage.
- Windows, Linux, Mac, Android, iPhone, iPad and Windows Phone are
supported.
- The OpenVPN clone function supports legacy OpenVPN clients.
- IPv4 / IPv6 dual-stack.
- The VPN server runs on Windows, Linux, FreeBSD, Solaris and Mac OS X.
- Configure All settings on GUI.
- Multi-languages (English, Japanese and Simplified-Chinese).
- No memory leaks. High quality stable codes, intended for long-term runs.
We always verify that there are no memory or resource leaks before
releasing the build.
- More details at https://www.softether.org/.
GETTING STARTED
---------------
Visit the SoftEther VPN Project official web site at first:
https://www.softether.org/
If you are not a developer, it is recommended to download the binary
installers from:
https://www.softether-download.com/
To build from the source,
see "BUILD_UNIX.TXT" or "BUILD_WINDOWS.TXT" files.
HOW TO DOWNLOAD THE LATEST SOURCE CODE PACKAGE
----------------------------------------------
Go to https://www.softether-download.com/ and you can find the latest
source-code package file in both .ZIP and .TAR.GZ format.
This is the easiest way to obtain the source code of SoftEther VPN.
HOW TO GET THE LATEST SOURCE CODE TREE FOR DEVELOPERS
-----------------------------------------------------
If you are an open-source developer, visit our GitHub repository:
https://github.com/SoftEtherVPN/SoftEtherVPN_Stable/
You can download the up-to-date source-code tree of SoftEther VPN
from GitHub. You may make your own fork project from our project.
The download and build instruction is following:
$ git clone https://github.com/SoftEtherVPN/SoftEtherVPN_Stable.git
$ cd SoftEtherVPN
$ ./configure
$ make
$ make install
TO CIRCUMVENT YOUR GOVERNMENT'S FIREWALL RESTRICTION
----------------------------------------------------
Because SoftEther VPN is overly strong tool to build a VPN tunnel,
some censorship governments want to block your access to the source code
of SoftEther VPN, by abusing their censorship firewalls.
To circumvent your censor's unjust restriction,
SoftEther VPN Project distributes the up-to-date source-code
on all the following open-source repositories:
- GitHub
https://github.com/SoftEtherVPN/SoftEtherVPN_Stable/
To fetch the source code from GitHub:
$ git clone https://github.com/SoftEtherVPN/SoftEtherVPN_Stable.git
We hope that you can reach one of the above URLs at least!
SOURCE CODE CONTRIBUTION
------------------------
Your contribution to SoftEther VPN Project is much appreciated.
Please send patches to us through GitHub.
Read the SoftEther VPN Patch Acceptance Policy in advance:
https://www.softether.org/5-download/src/9.patch
DEAR SECURITY EXPERTS
---------------------
If you find a bug or a security vulnerability please kindly inform us
about the problem immediately so that we can fix the security problem
to protect a lot of users around the world as soon as possible.
Our e-mail address for security reports is:
softether-vpn-security [at] softether.org
Please note that the above e-mail address is not a technical support
inquiry address. If you need technical assistance, please visit
https://www.softether.org/ and ask your question on the users forum.
DISCLAIMER
----------
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
THIS SOFTWARE IS DEVELOPED IN JAPAN, AND DISTRIBUTED FROM JAPAN,
UNDER JAPANESE LAWS. YOU MUST AGREE IN ADVANCE TO USE, COPY, MODIFY,
MERGE, PUBLISH, DISTRIBUTE, SUBLICENSE, AND/OR SELL COPIES OF THIS
SOFTWARE, THAT ANY JURIDICAL DISPUTES WHICH ARE CONCERNED TO THIS
SOFTWARE OR ITS CONTENTS, AGAINST US (SOFTETHER PROJECT, SOFTETHER
CORPORATION, DAIYUU NOBORI OR OTHER SUPPLIERS), OR ANY JURIDICAL
DISPUTES AGAINST US WHICH ARE CAUSED BY ANY KIND OF USING, COPYING,
MODIFYING, MERGING, PUBLISHING, DISTRIBUTING, SUBLICENSING, AND/OR
SELLING COPIES OF THIS SOFTWARE SHALL BE REGARDED AS BE CONSTRUED AND
CONTROLLED BY JAPANESE LAWS, AND YOU MUST FURTHER CONSENT TO
EXCLUSIVE JURISDICTION AND VENUE IN THE COURTS SITTING IN TOKYO,
JAPAN. YOU MUST WAIVE ALL DEFENSES OF LACK OF PERSONAL JURISDICTION
AND FORUM NON CONVENIENS. PROCESS MAY BE SERVED ON EITHER PARTY IN
THE MANNER AUTHORIZED BY APPLICABLE LAW OR COURT RULE.
USE ONLY IN JAPAN. DO NOT USE THIS SOFTWARE IN ANOTHER COUNTRY UNLESS
YOU HAVE A CONFIRMATION THAT THIS SOFTWARE DOES NOT VIOLATE ANY
CRIMINAL LAWS OR CIVIL RIGHTS IN THAT PARTICULAR COUNTRY. USING THIS
SOFTWARE IN OTHER COUNTRIES IS COMPLETELY AT YOUR OWN RISK. THE
SOFTETHER VPN PROJECT HAS DEVELOPED AND DISTRIBUTED THIS SOFTWARE TO
COMPLY ONLY WITH THE JAPANESE LAWS AND EXISTING CIVIL RIGHTS INCLUDING
PATENTS WHICH ARE SUBJECTS APPLY IN JAPAN. OTHER COUNTRIES' LAWS OR
CIVIL RIGHTS ARE NONE OF OUR CONCERNS NOR RESPONSIBILITIES. WE HAVE
NEVER INVESTIGATED ANY CRIMINAL REGULATIONS, CIVIL LAWS OR
INTELLECTUAL PROPERTY RIGHTS INCLUDING PATENTS IN ANY OF OTHER 200+
COUNTRIES AND TERRITORIES. BY NATURE, THERE ARE 200+ REGIONS IN THE
WORLD, WITH DIFFERENT LAWS. IT IS IMPOSSIBLE TO VERIFY EVERY
COUNTRIES' LAWS, REGULATIONS AND CIVIL RIGHTS TO MAKE THE SOFTWARE
COMPLY WITH ALL COUNTRIES' LAWS BY THE PROJECT. EVEN IF YOU WILL BE
SUED BY A PRIVATE ENTITY OR BE DAMAGED BY A PUBLIC SERVANT IN YOUR
COUNTRY, THE DEVELOPERS OF THIS SOFTWARE WILL NEVER BE LIABLE TO
RECOVER OR COMPENSATE SUCH DAMAGES, CRIMINAL OR CIVIL
RESPONSIBILITIES. NOTE THAT THIS LINE IS NOT LICENSE RESTRICTION BUT
JUST A STATEMENT FOR WARNING AND DISCLAIMER.
READ AND UNDERSTAND THE 'WARNING.TXT' FILE BEFORE USING THIS SOFTWARE.
SOME SOFTWARE PROGRAMS FROM THIRD PARTIES ARE INCLUDED ON THIS SOFTWARE
WITH LICENSE CONDITIONS WHICH ARE DESCRIBED ON THE 'THIRD_PARTY.TXT' FILE.

View File

@ -1,804 +0,0 @@
BitVisor(R) VPN Client Module (IPsec Driver):
Copyright (c) 2007, 2008 University of Tsukuba.
Copyright (C) 2007, 2008 National Institute of Information and Communications
Technology.
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
3. Neither the name of the University of Tsukuba nor the names of its
contributors may be used to endorse or promote products derived from this
software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-------------------
Microsoft(R) C Runtime Library:
(c) 2007 Microsoft Corporation. All Rights Reserved.
-------------------
RSA Security Inc. PKCS #11 Cryptographic Token Interface (Cryptoki):
License to copy and use this software is granted provided that it is
identified as "RSA Security Inc. PKCS #11 Cryptographic Token Interface
(Cryptoki)" in all material mentioning or referencing this software.
License is also granted to make and use derivative works provided that such
works are identified as "derived from the RSA Security Inc. PKCS #11
Cryptographic Token Interface (Cryptoki)" in all material mentioning or
referencing the derived work.
RSA Security Inc. makes no representations concerning either the
merchantability of this software or the suitability of this software for any
particular purpose. It is provided "as is" without express or implied warranty
of any kind.
-------------------
WinPcap:
Copyright (c) 2001 - 2003 NetGroup, Politecnico di Torino (Italy)
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
3. Neither the name of the Politecnico di Torino nor the names of its
contributors may be used to endorse or promote products derived from this
software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE,
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-------------------
libedit:
Copyright (c) 1992, 1993 The Regents of the University of California. All
rights reserved.
This code is derived from software contributed to Berkeley by Christos Zoulas
of Cornell University.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
3. Neither the name of the University nor the names of its contributors may be
used to endorse or promote products derived from this software without
specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND ANY
EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR ANY
DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-------------------
libiconv:
GNU LIBRARY GENERAL PUBLIC LICENSE
Version 2, June 1991
Copyright (C) 1991 Free Software Foundation, Inc.
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
Everyone is permitted to copy and distribute verbatim copies of this license
document, but changing it is not allowed.
[This is the first released version of the library GPL. It is
numbered 2 because it goes with version 2 of the ordinary GPL.]
Preamble
The licenses for most software are designed to take away your freedom to
share and change it. By contrast, the GNU General Public Licenses are intended
to guarantee your freedom to share and change free software--to make sure the
software is free for all its users.
This license, the Library General Public License, applies to some specially
designated Free Software Foundation software, and to any other libraries whose
authors decide to use it. You can use it for your libraries, too.
When we speak of free software, we are referring to freedom, not price. Our
General Public Licenses are designed to make sure that you have the freedom to
distribute copies of free software (and charge for
this service if you wish), that you receive source code or can get it if you
want it, that you can change the software or use pieces of it in new free
programs; and that you know you can do these things.
To protect your rights, we need to make restrictions that forbid anyone to
deny you these rights or to ask you to surrender the rights. These
restrictions translate to certain responsibilities for you if you distribute
copies of the library, or if you modify it.
For example, if you distribute copies of the library, whether gratis or for
a fee, you must give the recipients all the rights that we gave you. You must
make sure that they, too, receive or can get the source
code. If you link a program with the library, you must provide complete object
files to the recipients so that they can relink them with the library, after
making changes to the library and recompiling it. And you must show them these
terms so they know their rights.
Our method of protecting your rights has two steps: (1) copyright the
library, and (2) offer you this license which gives you legal permission to
copy, distribute and/or modify the library.
Also, for each distributor's protection, we want to make certain that
everyone understands that there is no warranty for this free library. If the
library is modified by someone else and passed on, we want its recipients to
know that what they have is not the original version, so that any problems
introduced by others will not reflect on the original authors' reputations.
Finally, any free program is threatened constantly by software patents. We
wish to avoid the danger that companies distributing free software will
individually obtain patent licenses, thus in effect transforming the program
into proprietary software. To prevent this, we have made it clear that any
patent must be licensed for everyone's free use or not licensed at all.
Most GNU software, including some libraries, is covered by the ordinary GNU
General Public License, which was designed for utility programs. This license,
the GNU Library General Public License, applies to certain designated
libraries. This license is quite different from the ordinary one; be sure to
read it in full, and don't assume that anything in it is the same as in the
ordinary license.
The reason we have a separate public license for some libraries is that they
blur the distinction we usually make between modifying or adding to a program
and simply using it. Linking a program with a library, without changing the
library, is in some sense simply using the library, and is analogous to
running a utility program or application program. However, in a textual and
legal sense, the linked executable is a combined work, a derivative of the
original library, and the ordinary General Public License treats it as such.
Because of this blurred distinction, using the ordinary General Public
License for libraries did not effectively promote software sharing, because
most developers did not use the libraries. We concluded that weaker conditions
might promote sharing better.
However, unrestricted linking of non-free programs would deprive the users
of those programs of all benefit from the free status of the libraries
themselves. This Library General Public License is intended to
permit developers of non-free programs to use free libraries, while preserving
your freedom as a user of such programs to change the free libraries that are
incorporated in them. (We have not seen how to achieve this as regards changes
in header files, but we have achieved it as regards changes in the actual
functions of the Library.) The hope is that this will lead to faster
development of free libraries.
The precise terms and conditions for copying, distribution and modification
follow. Pay close attention to the difference between a "work based on the
library" and a "work that uses the library". The former contains code derived
from the library, while the latter only works together with the library.
Note that it is possible for a library to be covered by the ordinary General
Public License rather than by this special one.
GNU LIBRARY GENERAL PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. This License Agreement applies to any software library which contains a
notice placed by the copyright holder or other authorized party saying it may
be distributed under the terms of this Library
General Public License (also called "this License"). Each licensee is
addressed as "you".
A "library" means a collection of software functions and/or data prepared so
as to be conveniently linked with application programs (which use some of
those functions and data) to form executables.
The "Library", below, refers to any such software library or work which has
been distributed under these terms. A "work based on the Library" means either
the Library or any derivative work under copyright law: that is to say, a work
containing the Library or a portion of it, either verbatim or with
modifications and/or translated straightforwardly into another language.
(Hereinafter, translation is included without limitation in the term
"modification".)
"Source code" for a work means the preferred form of the work for making
modifications to it. For a library, complete source code means all the source
code for all modules it contains, plus any associated interface definition
files, plus the scripts used to control compilation and installation of the
library.
Activities other than copying, distribution and modification are not covered
by this License; they are outside its scope. The act of running a program
using the Library is not restricted, and output from such a program is covered
only if its contents constitute a work based on the Library (independent of
the use of the Library in a tool for writing it). Whether that is true depends
on what the Library does and what the program that uses the Library does.
1. You may copy and distribute verbatim copies of the Library's complete
source code as you receive it, in any medium, provided that you conspicuously
and appropriately publish on each copy an appropriate copyright notice and
disclaimer of warranty; keep intact all the notices that refer to this License
and to the absence of any warranty; and distribute a copy of this License
along with the Library.
You may charge a fee for the physical act of transferring a copy, and you
may at your option offer warranty protection in exchange for a fee.
2. You may modify your copy or copies of the Library or any portion of it,
thus forming a work based on the Library, and copy and distribute such
modifications or work under the terms of Section 1 above, provided that you
also meet all of these conditions:
a) The modified work must itself be a software library.
b) You must cause the files modified to carry prominent notices stating
that you changed the files and the date of any change.
c) You must cause the whole of the work to be licensed at no charge to all
third parties under the terms of this License.
d) If a facility in the modified Library refers to a function or a table
of data to be supplied by an application program that uses the facility, other
than as an argument passed when the facility is invoked, then you must make a
good faith effort to ensure that, in the event an application does not supply
such function or table, the facility still operates, and performs whatever
part of its purpose remains meaningful.
(For example, a function in a library to compute square roots has a
purpose that is entirely well-defined independent of the application.
Therefore, Subsection 2d requires that any application-supplied function or
table used by this function must be optional: if the application does not
supply it, the square root function must still compute square roots.)
These requirements apply to the modified work as a whole. If identifiable
sections of that work are not derived from the Library, and can be reasonably
considered independent and separate works in themselves, then this License,
and its terms, do not apply to those sections when you distribute them as
separate works. But when you distribute the same sections as part of a whole
which is a work based on the Library, the distribution of the whole must be on
the terms of this License, whose permissions for other licensees extend to the
entire whole, and thus to each and every part regardless of who wrote it.
Thus, it is not the intent of this section to claim rights or contest your
rights to work written entirely by you; rather, the intent is to exercise the
right to control the distribution of derivative or collective works based on
the Library.
In addition, mere aggregation of another work not based on the Library with
the Library (or with a work based on the Library) on a volume of a storage or
distribution medium does not bring the other work under the scope of this
License.
3. You may opt to apply the terms of the ordinary GNU General Public
License instead of this License to a given copy of the Library. To do this,
you must alter all the notices that refer to this License, so that they refer
to the ordinary GNU General Public License, version 2, instead of to this
License. (If a newer version than version 2 of the ordinary GNU General Public
License has appeared, then you can specify that version instead if you wish.)
Do not make any other change in these notices.
Once this change is made in a given copy, it is irreversible for that copy,
so the ordinary GNU General Public License applies to all subsequent copies
and derivative works made from that copy.
This option is useful when you wish to copy part of the code of the Library
into a program that is not a library.
4. You may copy and distribute the Library (or a portion or derivative of
it, under Section 2) in object code or executable form under the terms of
Sections 1 and 2 above provided that you accompany it with the complete
corresponding machine-readable source code, which must be distributed under
the terms of Sections 1 and 2 above on a medium customarily used for software
interchange.
If distribution of object code is made by offering access to copy from a
designated place, then offering equivalent access to copy the source code from
the same place satisfies the requirement to distribute the source code, even
though third parties are not compelled to copy the source along with the
object code.
5. A program that contains no derivative of any portion of the Library, but
is designed to work with the Library by being compiled or linked with it, is
called a "work that uses the Library". Such a work, in isolation, is not a
derivative work of the Library, and therefore falls outside the scope of this
License.
However, linking a "work that uses the Library" with the Library creates an
executable that is a derivative of the Library (because it contains portions
of the Library), rather than a "work that uses the library". The executable is
therefore covered by this License.
Section 6 states terms for distribution of such executables.
When a "work that uses the Library" uses material from a header file that is
part of the Library, the object code for the work may be a derivative work of
the Library even though the source code is not.
Whether this is true is especially significant if the work can be linked
without the Library, or if the work is itself a library. The threshold for
this to be true is not precisely defined by law.
If such an object file uses only numerical parameters, data structure
layouts and accessors, and small macros and small inline functions (ten lines
or less in length), then the use of the object file is unrestricted,
regardless of whether it is legally a derivative work. (Executables containing
this object code plus portions of the Library will still fall under Section
6.)
Otherwise, if the work is a derivative of the Library, you may distribute
the object code for the work under the terms of Section 6. Any executables
containing that work also fall under Section 6, whether or not they are linked
directly with the Library itself.
6. As an exception to the Sections above, you may also compile or link a
"work that uses the Library" with the Library to produce a work containing
portions of the Library, and distribute that work under terms of your choice,
provided that the terms permit modification of the work for the customer's own
use and reverse engineering for debugging such modifications.
You must give prominent notice with each copy of the work that the Library
is used in it and that the Library and its use are covered by this License.
You must supply a copy of this License. If the work during execution displays
copyright notices, you must include the copyright notice for the Library among
them, as well as a reference directing the user to the copy of this License.
Also, you must do one of these things:
a) Accompany the work with the complete corresponding machine-readable
source code for the Library including whatever changes were used in the work
(which must be distributed under Sections 1 and 2 above) ; and, if the work is
an executable linked with the Library, with the complete machine-readable
"work that uses the Library", as object code and/or source code, so that the
user can modify the Library and then relink to produce a modified executable
containing the modified Library. (It is understood that the user who changes
the contents of definitions files in the Library will not necessarily be able
to recompile the application to use the modified definitions.)
b) Accompany the work with a written offer, valid for at least three
years, to give the same user the materials specified in Subsection 6a, above,
for a charge no more than the cost of performing this distribution.
c) If distribution of the work is made by offering access to copy from a
designated place, offer equivalent access to copy the above specified
materials from the same place.
d) Verify that the user has already received a copy of these materials or
that you have already sent this user a copy.
For an executable, the required form of the "work that uses the Library"
must include any data and utility programs needed for reproducing the
executable from it. However, as a special exception, the source code
distributed need not include anything that is normally distributed (in either
source or binary form) with the major components (compiler, kernel, and so on)
of the operating system on which the executable runs, unless that component
itself accompanies the executable.
It may happen that this requirement contradicts the license restrictions of
other proprietary libraries that do not normally accompany the operating
system. Such a contradiction means you cannot use both them and the Library
together in an executable that you distribute.
7. You may place library facilities that are a work based on the Library
side-by-side in a single library together with other library facilities not
covered by this License, and distribute such a combined library, provided that
the separate distribution of the work based on the Library and of the other
library facilities is otherwise permitted, and provided that you do these two
things:
a) Accompany the combined library with a copy of the same work based on
the Library, uncombined with any other library facilities. This must be
distributed under the terms of the Sections above.
b) Give prominent notice with the combined library of the fact that part
of it is a work based on the Library, and explaining where to find the
accompanying uncombined form of the same work.
8. You may not copy, modify, sublicense, link with, or distribute the
Library except as expressly provided under this License. Any attempt otherwise
to copy, modify, sublicense, link with, or distribute the Library is void, and
will automatically terminate your rights under this License. However, parties
who have received copies, or rights, from you under this License will not have
their licenses terminated so long as such parties remain in full compliance.
9. You are not required to accept this License, since you have not signed
it. However, nothing else grants you permission to modify or distribute the
Library or its derivative works. These actions are prohibited by law if you do
not accept this License. Therefore, by modifying or distributing the Library
(or any work based on the Library), you indicate your acceptance of this
License to do so, and all its terms and conditions for copying, distributing
or modifying the Library or works based on it.
10. Each time you redistribute the Library (or any work based on the
Library), the recipient automatically receives a license from the original
licensor to copy, distribute, link with or modify the Library subject to these
terms and conditions. You may not impose any further restrictions on the
recipients' exercise of the rights granted herein. You are not responsible for
enforcing compliance by third parties to this License.
11. If, as a consequence of a court judgment or allegation of patent
infringement or for any other reason (not limited to patent issues),
conditions are imposed on you (whether by court order, agreement or otherwise)
that contradict the conditions of this License, they do not excuse you from
the conditions of this License. If you cannot distribute so as to satisfy
simultaneously your obligations under this License and any other pertinent
obligations, then as a consequence you may not distribute the Library at all.
For example, if a patent license would not permit royalty-free redistribution
of the Library by all those who receive copies directly or indirectly through
you, then the only way you could satisfy both it and this License would be to
refrain entirely from distribution of the Library.
If any portion of this section is held invalid or unenforceable under any
particular circumstance, the balance of the section is intended to apply, and
the section as a whole is intended to apply in other circumstances.
It is not the purpose of this section to induce you to infringe any patents or
other property right claims or to contest validity of any such claims; this
section has the sole purpose of protecting the integrity of the free software
distribution system which is implemented by public license practices. Many
people have made generous contributions to the wide range of software
distributed through that system in reliance on consistent application of that
system; it is up to the author/donor to decide if he or she is willing to
distribute software through any other system and a licensee cannot impose that
choice.
This section is intended to make thoroughly clear what is believed to be a
consequence of the rest of this License.
12. If the distribution and/or use of the Library is restricted in certain
countries either by patents or by copyrighted interfaces, the original
copyright holder who places the Library under this License may add an explicit
geographical distribution limitation excluding those countries, so that
distribution is permitted only in or among countries not thus excluded. In
such case, this License incorporates the limitation as if written in the body
of this License.
13. The Free Software Foundation may publish revised and/or new versions of
the Library General Public License from time to time. Such new versions will
be similar in spirit to the present version, but may differ in detail to
address new problems or concerns.
Each version is given a distinguishing version number. If the Library
specifies a version number of this License which applies to it and "any later
version", you have the option of following the terms and conditions either of
that version or of any later version published by the Free Software
Foundation. If the Library does not specify a license version number, you may
choose any version ever published by the Free Software Foundation.
14. If you wish to incorporate parts of the Library into other free programs
whose distribution conditions are incompatible with these, write to the author
to ask for permission. For software which is copyrighted by the Free Software
Foundation, write to the Free Software Foundation; we sometimes make
exceptions for this. Our decision will be guided by the two goals of
preserving the free status of all derivatives of our free software and of
promoting the sharing and reuse of software generally.
NO WARRANTY
15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY FOR
THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE
STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE
LIBRARY "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED,
INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND
PERFORMANCE OF THE LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE,
YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
OUT OF THE USE OR INABILITY TO USE THE LIBRARY (INCLUDING BUT NOT LIMITED TO
LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR
THIRD PARTIES OR A FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE),
EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH
DAMAGES.
END OF TERMS AND CONDITIONS
-------------------
ncurses:
Copyright (c) 1998-2005,2006 Free Software Foundation, Inc.
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, distribute with
modifications, sublicense, and/or sell copies of the Software, and to permit
persons to whom the Software is furnished to do so, subject to the following
conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR
IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Except as contained in this notice, the name(s) of the above copyright holders
shall not be used in advertising or otherwise to promote the sale, use or
other dealings in this Software without prior written authorization.
-------------------
OpenSSL:
OpenSSL License
Copyright (c) 1998-2011 The OpenSSL Project. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
3. All advertising materials mentioning features or use of this software must
display the following acknowledgment: "This product includes software
developed by the OpenSSL Project for use in the OpenSSL Toolkit.
(http://www.openssl.org/)"
4. The names "OpenSSL Toolkit" and "OpenSSL Project" must not be used to
endorse or promote products derived from this software without prior written
permission. For written permission, please contact openssl-core@openssl.org.
5. Products derived from this software may not be called "OpenSSL" nor may
"OpenSSL" appear in their names without prior written permission of the
OpenSSL Project.
6. Redistributions of any form whatsoever must retain the following
acknowledgment: "This product includes software developed by the OpenSSL
Project for use in the OpenSSL Toolkit (http://www.openssl.org/)"
THIS SOFTWARE IS PROVIDED BY THE OpenSSL PROJECT ``AS IS'' AND ANY EXPRESSED
OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
EVENT SHALL THE OpenSSL PROJECT OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
This product includes cryptographic software written by Eric Young
(eay@cryptsoft.com). This product includes software written by Tim Hudson
(tjh@cryptsoft.com).
Original SSLeay License
Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) All rights reserved.
This package is an SSL implementation written by Eric Young
(eay@cryptsoft.com). The implementation was written so as to conform with
Netscapes SSL.
This library is free for commercial and non-commercial use as long as the
following conditions are aheared to. The following conditions apply to all
code found in this distribution, be it the RC4, RSA, lhash, DES, etc., code;
not just the SSL code. The SSL documentation included with this distribution
is covered by the same copyright terms except that the holder is Tim Hudson
(tjh@cryptsoft.com).
Copyright remains Eric Young's, and as such any Copyright notices in the code
are not to be removed. If this package is used in a product, Eric Young should
be given attribution as the author of the parts of the library used. This can
be in the form of a textual message at program startup or in documentation
(online or textual) provided with the package.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the copyright notice, this list
of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
3. All advertising materials mentioning features or use of this software must
display the following acknowledgement: "This product includes cryptographic
software written by Eric Young (eay@cryptsoft.com)" The word 'cryptographic'
can be left out if the rouines from the library being used are not
cryptographic related :-).
4. If you include any Windows specific code (or a derivative thereof) from the
apps directory (application code) you must include an acknowledgement: "This
product includes software written by Tim Hudson (tjh@cryptsoft.com)"
THIS SOFTWARE IS PROVIDED BY ERIC YOUNG ``AS IS'' AND ANY EXPRESS OR IMPLIED
WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
The licence and distribution terms for any publically available version or
derivative of this code cannot be changed. i.e. this code cannot simply be
copied and put under another distribution licence [including the GNU Public
Licence.]
-------------------
zlib:
Acknowledgments:
The deflate format used by zlib was defined by Phil Katz. The deflate and
zlib specifications were written by L. Peter Deutsch. Thanks to all the people
who reported problems and suggested various improvements in zlib; they are too
numerous to cite here.
Copyright notice:
(C) 1995-2004 Jean-loup Gailly and Mark Adler
This software is provided 'as-is', without any express or implied warranty.
In no event will the authors be held liable for any damages arising from the
use of this software.
Permission is granted to anyone to use this software for any purpose,
including commercial applications, and to alter it and redistribute it freely,
subject to the following restrictions:
1. The origin of this software must not be misrepresented; you must not
claim that you wrote the original software. If you use this software in a
product, an acknowledgment in the product documentation would be appreciated
but is not required.
2. Altered source versions must be plainly marked as such, and must not be
misrepresented as being the original software.
3. This notice may not be removed or altered from any source distribution.
Jean-loup Gailly Mark Adler
jloup@gzip.org madler@alumni.caltech.edu
If you use the zlib library in a product, we would appreciate *not* receiving
lengthy legal documents to sign. The sources are provided for free but without
warranty of any kind. The library has been entirely written by Jean-loup
Gailly and Mark Adler; it does not include third-party code.
If you redistribute modified sources, we would appreciate that you include in
the file ChangeLog history information documenting your changes. Please read
the FAQ for more information on the distribution of modified source versions.
-------------------
Intel AESNI Sample Library:
Copyright (c) 2010, Intel Corporation
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
* Neither the name of Intel Corporation nor the names of its contributors may
be used to endorse or promote products derived from this software without
specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
Issue Date: Aug 6, 2010
-------------------
libmincrypt:
Copyright 2013 The Android Open Source Project
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
* Neither the name of Google Inc. nor the names of its contributors may
be used to endorse or promote products derived from this software
without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY Google Inc. ``AS IS'' AND ANY EXPRESS OR
IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
EVENT SHALL Google Inc. BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-------------------
NOTES WRITTEN BY SOFTETHER CORPORATION
Note for users of non-Windows version of PacketiX VPN: The enumerated bundle
of License Agreements above are copies of original License Agreements of each
library programs which PacketiX VPN uses. PacketiX VPN is not a delivered work
from these libraries. PacketiX VPN is a separated work from the libraries, but
it may call functions of the libraries (whether or not PacketiX VPN calls such
functions are depended on the user's intention to link them or not on user's
side computer). While some libraries indicate GPL or LGPL as a condition to
re-distribute, PacketiX VPN is not license under GPL nor LGPL. Therefore, we
took special care not to make PacketiX VPN become delivered works of any GPL
or LGPL libraries. In order to achieve that, both PacketiX VPN and GPL/LGPL
libraries are distributed with isolated forms (means that any program files of
PacketiX VPN are not bound nor linked to any GPL/LGPL libraries). If a user of
PacketiX VPN wants to link GPL/LGPL libraries by their own decisions,
operations and responsibilities, he may do that on his computer. However, if a
delivered work under copyright law is created as a result of such an
operation, such a delivered work must not re-distributed to other people,
because it may violate GPL/LGPL libraries' conditions.
Note for users of Windows version of PacketiX VPN: For technical reason, the
above texts are exactly same as a file which is also contained on the
non-Windows version of PacketiX VPN. Actually, the Windows version of PacketiX
VPN has no relations to any GPL/LGPL libraries enumerated above.
SoftEther Corporation provides source codes of some GPL/LGPL/other libraries
listed above on its web server. Anyone can download, use and re-distribute
them under individual licenses which are contained on each archive file,
available from the following URL:
http://uploader.softether.co.jp/src/
-------------------
Copyright Notes and Acknowledgments for PacketiX VPN (Commercial Version):
PacketiX VPN has some contributed codes from SoftEther VPN Project
(http://www.softether.org/).
These contributed codes have been granted by contributors to be imported into
the PacketiX VPN source-tree without GPLv2 conditions.
The list of contributors for SoftEther VPN Project:
https://github.com/SoftEtherVPN/SoftEtherVPN/blob/master/AUTHORS.TXT
SoftEther Corporation, the distributor of PacketiX VPN, appreciates all
contributors for SoftEther VPN Project very much.
See also: http://www.softether.org/5-download/src/9.patch

View File

@ -1,565 +0,0 @@
THE IMPORTANT NOTICES ABOUT SOFTETHER VPN
FUNCTIONS OF VPN COMMUNICATIONS EMBEDDED ON THIS SOFTWARE ARE VERY POWERFUL
THAN EVER. THIS STRONG VPN ABILITY WILL BRING YOU HUGE BENEFITS. HOWEVER, IF
YOU MISUSE THIS SOFTWARE, IT MIGHT DAMAGE YOURSELF. IN ORDER TO AVOID SUCH
RISKS, THIS DOCUMENT ACCOUNTS IMPORTANT NOTICES FOR CUSTOMERS WHO ARE WILLING
TO USE THIS SOFTWARE. THE FOLLOWING INSTRUCTIONS ARE VERY IMPORTANT. READ AND
UNDERSTAND IT CAREFULLY. ADDITIONALLY, IF YOU ARE PLANNING TO USE THE DYNAMIC
DNS, THE NAT TRAVERSAL OR THE VPN AZURE FUNCTIONS, READ THE SECTION 3.5
CAREFULLY. THESE FUNCTIONS ARE FREE SERVICES PROVIDED VIA THE INTERNET, ARE
NOT GUARANTEED, AND ARE NOT INTENDED TO BE USED FOR BUSINESS OR COMMERCIAL
USE. DO NOT USE THESE SERVICES FOR YOUR BUSINESS OR COMMERCIAL USE.
1. VPN Communication Protocols
1.1. SoftEther VPN Protocol
SoftEther VPN can perform VPN communication. Unlike traditional VPN protocols,
SoftEther VPN has an implementation of the newly-designed "SoftEther VPN
Protocol (SE-VPN Protocol)" . SE-VPN protocol encapsulates any Ethernet
packets into a HTTPS (HTTP over SSL) connection. Therefore SE-VPN protocol can
communicate beyond firewalls even if the firewall is configured to block
traditional VPN packets by network administrator. SE-VPN protocol is designed
and implemented to comply TLS 1.0 (RFC 5246) and HTTPS (RFC 2818). However, it
sometimes have different behavior to RFCs. If you are a network administrator
and want to block SE-VPN protocols on the firewall, you can adopt a
"white-list" policy on the firewall to filter any TCP or UDP packets on the
border except explicitly allowed packets towards specific web sites and
servers.
1.2. NAT Traversal Function
Generally, if you use traditional VPN systems you have to request a network
administrator to make the NAT or firewall to "open" or "relay" specific TCP or
UDP ports. However, there are demands somehow to eliminate such working costs
on network administrators. In order to satisfy such demands, SoftEther VPN has
the newly-implemented "NAT Traversal" function. NAT Traversal is enabled by
default. A SoftEther VPN Server running on the computer behind NAT or firewall
can accept VPN connections from the Internet, without any special
configurations on firewalls or NATs. If you want to disable the NAT Traversal
function, modify the "DisableNatTraversal" to "true" on the configuration file
of SoftEther VPN Server. In order to disable it on the client-side, append
"/tcp" suffix on the destination hostname.
1.3. Dynamic DNS Function
Traditional legacy VPN system requires a static global IP address on the VPN
server. In consideration of shortage of global IP addresses, SoftEther
Corporation implements the "Dynamic DNS Function" on SoftEther VPN Server.
Dynamic DNS is enabled by default. Dynamic DNS function notify the current
global IP address of the PC to the Dynamic DNS Servers which are operated by
SoftEther Corporation. A globally-unique hostname (FQDN) such as
"abc.softether.net" ( "abc" varies as unique per a user) will be assigned on
the VPN Server. If you tell this unique hostname to a VPN user, the user can
specify it as the destination VPN Sever hostname on the VPN Client and will be
able to connect the VPN Server. No IP addresses are required to know
beforehand. If the IP address of the VPN Server varies, the registered IP
address related to the hostname of Dynamic DNS service will be changed
automatically. By this mechanism, no longer need a static global IP address
which costs monthly to ISPs. You can use consumer-level inexpensive Internet
connection with dynamic IP address in order to operate an enterprise-level VPN
system. If you want to disable Dynamic DNS, specify "true" on the "Disabled"
items of the "DDnsClient" directive on the SoftEther VPN Server configuration
file. * Note for residents in People's Republic of China: If your VPN Server
is running on the People's Republic of China, the DNS suffix will be replaced
to "sedns.cn" domain. The "sedns.cn" domain is the service possessed and
operated by "Beijing Daiyuu SoftEther Technology Co., Ltd" which is a
Chinese-local enterprise.
1.4. VPN over ICMP / VPN over DNS functions
If you want to make a VPN connection between SoftEther VPN Client / Bridge and
SoftEther VPN Server, but if TCP and UDP packets are prohibited by the
firewall, then you can encapsulates payloads into "ICMP" (as known as Ping) or
"DNS" packets. This function can realize a VPN connection by using ICMP or DNS
even if the firewall or router blocks every TCP or UDP connections. VPN over
ICMP / VPN over DNS functions are designed to comply standard ICMP and DNS
specifications as possible, however it sometimes has a behavior not to fully
comply them. Therefore, few poor-quality routers may be caused a
memory-overflow or something troubles when a lot of ICMP or DNS packets are
passed, and such routers sometimes freezes or reboots. It might affects other
users on the same network. To avoid such risks, append the suffix "/tcp" on
the destination hostname which is specified on the VPN-client side to disable
VPN over ICMP / DNS functions.
1.5. VPN Azure Cloud Service
If your SoftEther VPN Server is placed behind the NAT or firwall, and by some
reason you cannot use NAT Traversal function, Dynamic DNS function or VPN over
ICMP/DNS function, you can use VPN Azure Clouse Service. SoftEther Corporation
operates VPN Azure Cloud on Internet. After the VPN Server makes a connection
to the VPN Azure Cloud, the hostname "abc.vpnazure.net" ( "abc" is a unique
hostname) can be specified to connect to the VPN Server via the VPN Azure
Cloud. Practically, such a hostname is pointing a global IP address of one of
cloud servers which are operated by SoftEther Corporation. If A VPN Client
connects to such a VPN Azure host, then the VPN Azure host will relay all
traffics between the VPN Client and the VPN Server. VPN Azure is disabled by
default. You can activate it easily by using VPN Server Configuration Tool.
1.6. UDP Acceleration
SoftEther VPN has the UDP Acceleration Function. If a VPN consists of two
sites detects that UDP channel can be established, UDP will be automatically
used. By this function, throughput of UDP increases. If direct UDP channel can
be established, direct UDP packets will be used. However, if there is
something obstacles such as firewalls or NATs, the "UDP Hole Punching"
technology will be used, instead. The "UDP Hole Punching" uses the cloud
servers which SoftEther Corporation operates on Internet. UDP Acceleration can
be disabled anytime by setting up so on the VPN-client side.
2. VPN Software
2.1. SoftEther VPN Client
If you use SoftEther VPN Client on Windows, the Virtual Network Adapter device
driver will be installed on Windows. The Virtual Network Adapter is
implemented as a kernel-mode driver for Windows. The driver is
digitally-signed by a certificate issued by VeriSign, Inc. and also sub-signed
by Symantec Corporation. A message to ask you want to sure install the driver
might be popped up on the screen. SoftEther VPN Client may response the
message if possible. SoftEther VPN Client also optimizes the configuration of
MMCSS (Multimedia Class Scheduler Service) on Windows. You can undo the
optimizations of MMCSS afterwards.
2.2. SoftEther VPN Server / Bridge
If you use SoftEther VPN Server / Bridge on Windows with "Local Bridge"
functions, you have to install the low-level Ethernet packet processing driver
on the computer. The driver is digitally-signed by a certificate issued by
VeriSign, Inc. and also sub-signed by Symantec Corporation. SoftEther VPN
Server / Bridge may disable the TCP/IP offloading features on the physical
network adapter for Local Bridge function. In Windows Vista / 2008 or greater
version, VPN Server may inject a packet-filter driver which complies Windows
Filter Platform (WPF) specification into the kernel in order to provide IPsec
function. The packet-filter driver will be loaded available only if IPsec
function is enabled. Once you enables IPsec function of SoftEther VPN Server,
the built-in IPsec function of Windows will be disabled. After you disabled
IPsec function of SoftEther VPN Server, then the built-in IPsec function of
Windows will revive. In order to provide the Local Bridge function, SoftEther
VPN Server / Bridge disables the TCP/IP offloading function on the operating
system.
2.3. User-mode Installation
You can install SoftEther VPN Server and SoftEther VPN Bridge as "User-mode"
on Windows. In other words, even if you don't have Windows system
administrator's privileges, you can install SoftEther VPN as a normal user.
User-mode install will disable a few functions, however other most functions
work well. Therefore, for example, an employee can install SoftEther VPN
Server on the computer in the office network, and he will be able to connect
to the server from his home. In order to realize such a system by user-self,
no system administrative privileges are required in the view-point of
technical. However, breaking rules of the company to install software on the
computer without authority might be regarded as an unfavorable behavior. If
you are an employee and belong to the company, and the company-policy
prohibits installing software or making communications towards Internet
without permission, you have to obtain a permission from the network
administrator or the executive officer of your company in advance to install
SoftEther VPN. If you install VPN Server / Bridge as User-mode, an icon will
be appeared on the Windows task-tray. If you feel that the icon disturbs you,
you can hide it by your operation. However, you must not exploit this hiding
function to install VPN Server on other person's computer as a spyware. Such
behavior might be an offence against the criminal law.
2.4. Keep Alive Function
SoftEther VPN Server and SoftEther VPN Bridge has Keep Alive Function by
default. The purpose of this function is to sustain the Internet line active.
The function transmits UDP packets with a random-byte-array-payload
periodically. This function is useful to avoid automatic disconnection on
mobile or dial-up connections. You can disable Keep Alive Function anytime.
2.5. Uninstallation
The uninstallation process of SoftEther VPN software will delete all program
files. However, non-program files (such as files and data which are generated
by running of programs) ) will not be deleted. For technical reason, the exe
and resource files of uninstaller might remain. Such remaining files never
affects to use the computer, however you can delete it manually. Kernel-mode
drivers might not be deleted, however such drivers will not be loaded after
the next boot of Windows. You can use "sc" command of Windows to delete
kernel-mode drivers manually.
2.6. Security
You should set the administrator's password on SoftEther VPN Server / Bridge
after installation. If you neglect to do it, another person can access to
SoftEther VPN Server / Bridge and can set the password without your
permission. This caution might be also applied on SoftEther VPN Client for
Linux.
2.7. Automatic Update Notification
SoftEther VPN software for Windows has an automatic update notification
function. It accesses to the SoftEther Update server periodically to check
whether or not the latest version of software is released. If the latest
version is released, the notification message will be popped up on the screen.
In order to achieve this purpose, the version, language settings, the unique
identifier, the IP address of your computer and the hostname of VPN Server
which is connected to will be sent to the SoftEther Update server. No personal
information will be sent. Automatic Update Notification is enabled by default,
however you can disable it on the configuration screen. The setting whether
turned on or turned off will be saved individually corresponding to each
destination VPN server, by VPN Server Manager.
2.8. Virtual NAT Function
A Virtual Hub on SoftEther VPN Server / Bridge has "Virtual NAT Function" .
Virtual NAT Function can share a single IP address on the physical network by
multiple private IP address of VPN Clients. There are two operation mode of
Virtual NAT: User-mode and Kernel-mode. In the user-mode operation, Virtual
NAT shares an IP address which is assigned on the host operating system.
Unlike user-mode, the kernel-mode operation attempts to find DHCP servers on
the physical network. If there are two or more physical networks, a DHCP
server will be sought automatically for each segments serially. If a DHCP
server found, and an IP address is acquired, the IP address will be used by
the Virtual NAT. In this case, an IP entry as a DHCP client will be registered
on the IP pool of the physical DHCP Server. The physical default gateway and
the DNS server will be used by the Virtual NAT in order to communicate with
hosts in Internet. In kernel-mode operation, a Virtual Hub has a virtual MAC
address which is operating on the physical Ethernet segment. In order to check
the connectivity to Internet, SoftEther VPN periodically sends DNS query
packet to resolve the IP address of host "www.yahoo.com" or "www.baidu.com" ,
and attempts to connect to the TCP port 80 of such a resulted IP address for
connectivity check.
2.9. Unattended Installation of Kernel-mode Components
When SoftEther VPN will detect a necessity to install the kernel-mode
components on Windows, a confirmation message will be appeared by Windows
system. In this occasion, SoftEther VPN software will switch to the Unattended
Installation mode in order to respond "Yes" to Windows. This is a solution to
prevent dead-locks when a remote-administration is performed from remote
place.
2.10. Windows Firewall
SoftEther VPN software will register itself as a safe-program. Such an entry
will be remain after the uninstallation. You can remove it manually from the
Control Panel of Windows.
3. Internet Services
3.1. Internet Services which are provided by SoftEther Corporation
SoftEther Corporation provides Dynamic DNS, NAT Traversal and VPN Azure server
services on the Internet. These services are free of charge. Customers can
access to the services by using SoftEther VPN software, via Internet. These
service will be planned to be available from Open-Source version of "SoftEther
VPN" which will be released in the future.
3.2. Sent Information and Privacy Protection
SoftEther VPN software may send an IP address, hostname, the version of VPN
software on the customer's computer to the cloud service operated by SoftEther
Corporation, in order to use the above services. These sending of information
are minimal necessary to use the services. No personal information will be
sent. SoftEther Corporation records log files of the cloud service servers for
90 days at least with the received information. Such logs will be used for
troubleshooting and other legitimate activities. SoftEther Corporation may
provide logs to a public servant of Japanese government who are belonging to
courts, police stations and the prosecutor's office, in order to comply such
authorities' order. (Every Japanese public servants are liable by law to keep
the information close.) Moreover, the IP addresses or other information will
be processed statistically and provided to the public, not to expose the each
concrete IP address, in order to release the release of research activities.
3.3. Communication Data via VPN Azure Service
Regardless of the above 3.2 rule, if the customer sends or receives VPN
packets using VPN Azure Cloud Service, the actual payloads will stored and
forwarded via the volatile memory of the servers for very short period. Such a
behavior is naturally needed to provide the "VPN relay service" . No payloads
will be recorded on "fixed" storages such as hard-drives. However, the
"Wiretapping for Criminals Procedures Act" (The 137th legislation ruled on
August 18, 1999 in Japan) requires telecommunication companies to allow the
Japanese government authority to conduct a wire-tapping on the line. VPN Azure
Servers which are physically placed on Japan are subjects of this law.
3.4. Comply to Japanese Telecommunication Laws
SoftEther Corporation complies with Japanese Telecommunication Laws as
necessary to provide online services via Internet.
3.5. Free and Academic Experiment Services
SoftEther provides Dynamic DNS, NAT Traversal and VPN Azure as academic
experiment services. Therefore, there services can be used for free of charge.
These services are not parts of "SoftEther VPN Software Products" . These
services are provided without any warranty. The services may be suspended or
discontinued by technical or operational matters. In such occasions, users
will not be able to use the services. A user have to understand such risks,
and to acknowledge that such risks are borne by a user-self. SoftEther will
never be liable to results or damages of use or unable-to-use of the service.
Even if the user has already paid the license-fee of the commercial version of
SoftEther VPN, such paid fees don't include any fees of these services.
Therefore, if the online services will stop or be discontinued, no refunds or
recoveries of damages will be provided by SoftEther Corporation.
3.6. DNS Proxy Cloud Servers
In some regions, when a user uses Internet, a DNS query sometimes broken or
lost when it is passing through the ISP line. If SoftEther VPN Server, Client
or Bridge detects a possibility that the accessing to the actual VPN server
might be unstable, then DNS queries will be also transferred to the DNS proxy
cloud servers which are operated by SoftEther Corporation. A DNS proxy cloud
server will respond DNS queries with answering correct a IP address.
4. General Cautions
4.1. Needs an Approval from Network Administrator
SoftEther VPN has powerful functions which don't require special settings by
network administrators. For example, you need not to ask the administrator to
configure the existing firewall in order to "open" a TCP/UDP port. Such
characteristic features are for the purpose to eliminate working times and
costs of network administrators, and avoid misconfiguration-risks around the
tasks to open specific exception ports on the firewall. However, any employees
belong to the company have to obtain an approval from the network
administrator before installs SoftEther VPN. If your network administrator
neglects to provide such an approval, you can consider to take an approval
from an upper authority. (For example, executive officer of the company.) If
you use SoftEther VPN without any approvals from the authority of your
company, you might have disadvantage. SoftEther Corporation will be never
liable for results or damages of using SoftEther VPN.
4.2. Observe Laws of Your Country
If your country's law prohibits the use of encryption, you have to disable the
encryption function of SoftEther VPN by yourself. Similarly, in some countries
or regions, some functions of SoftEther VPN might be prohibited to use by
laws. Other countries' laws are none of SoftEther Corporation's concern
because SoftEther Corporation is an enterprise which is located and registered
in Japan physically. For example, there might be a risk that a part of
SoftEther VPN conflicts an existing patent which is valid only on the specific
region. SoftEther Corporation has no interests in such specific region outside
Japan's territory. Therefore, if you want to use SoftEther VPN in regions
outside Japan, you have to be careful not to violate third-person's rights.
You have to verify the legitimacy of the use of SoftEther VPN in the specific
region before you actually use it in such region. By nature, there are almost
200 countries in the World, and each country's law is different each other. It
is practically impossible to verify every countries' laws and regulations and
make the software comply with all countries' laws in advance to release the
software. Therefore SoftEther Corporation has verified the legitimacy of
SoftEther VPN against the laws and regulations of only Japan. If a user uses
SoftEther VPN in a specific country, and damaged by public servants of the
government authority, SoftEther Corporation will never be liable to recover or
compensate such damages or criminal responsibilities.
5. VPN Gate Academic Experiment Project
(This chapter applies only on SoftEther VPN software package which contains
the extension plug-in for VPN Gate Academic Experiment Project.)
5.1. About VPN Gate Academic Experiment Project
VPN Gate Academic Experiment Project is an online service operated for just
the academic research purpose at the graduate school of University of Tsukuba,
Japan. The purpose of this research is to expend our knowledge about the
"Global Distributed Public VPN Relay Server" (GDPVRS) technology. For details,
please visit http://www.vpngate.net/.
5.2. About VPN Gate Service
SoftEther VPN Server and SoftEther VPN Client may contain "VPN Gate Service"
program. However, VPN Gate Service is disabled by default.
VPN Gate Service should be activated and enabled by the voluntary intention of
the owner of the computer which SoftEther VPN Server or SoftEther VPN Client
is installed on. After you activate VPN Gate Service, the computer will be
start to serve as a part of the Global Distributed Public VPN Relay Servers.
The IP address, hostname and related information of the computer will be sent
and registered to the directory server of VPN Gate Academic Experiment
Project, and they will be published and disclosed to the public. This
mechanism will allow any VPN Gate Client software's user to connect to the VPN
Gate Service running on your computer. While the VPN session between a VPN
Gate Client and your VPN Gate Service is established, the VPN Gate Client's
user can send/receive any IP packets towards the Internet via the VPN Gate
Service. The global IP address of the VPN Gate Service's hosing computer will
be used as the source IP address of such communications which a VPN Gate
Client initiates.
VPN Gate Service will send some information to the VPN Gate Academic
Experiment Service Directory Server. The information includes the operator's
information which described in section 5.5, logging settings, uptime,
operating system version, type of protocol, port numbers, quality information,
statistical information, VPN Gate clients' log history data (includes dates,
IP addresses, version numbers and IDs) and the version of the software. These
information will be exposed on the directory. VPN Gate Service also receives a
key for encoding which is described on the chapter 5.9 from the directory
server.
5.3. Details of VPN Gate Service's Behavior
If you enable VPN Gate Service manually, which is disabled by default, the
"VPNGATE" Virtual Hub will be created on the SoftEther VPN Server. If you are
using SoftEther VPN Client and attempt to active VPN Gate Service on it, an
equivalent program to SoftEther VPN Server will be invoked on the same process
of SoftEther VPN Client, and the "VPNGATE" Virtual Hub will be created. The
"VPNGATE" Virtual Hub contains a user named "VPN" by default which permits
anyone on the Internet to make a VPN connection to the Virtual Hub. Once a VPN
Client connects to the "VPNGATE" Virtual Hub, any communication between the
user and the Internet will pass through the Virtual Hub, and
transmitted/received using the physical network interface on the computer
which SoftEther VPN Server (or SoftEther VPN Client) is running on. This will
cause the result that a destination host specified by the VPN Client will
identify that the source of the communication has initiated from the VPN Gate
Service's hosting computer's IP address. However, for safety, any packets
which destinations are within 192.168.0.0/255.255.0.0, 172.16.0.0/255.240.0.0
or 10.0.0.0/255.0.0.0 will be blocked by the "VPNGATE" Virtual Hub in order to
protect your local network. Therefore, if you run VPN Gate Service on your
corporate network or private network, it is safe because anonymous VPN Client
users will not be permitted to access such private networks. VPN Gate Service
also serves as relay for accessing to the VPN Gate Directory Server.
In order to make VPN Gate Service familiar with firewalls and NATs, it opens
an UDP port by using the NAT Traversal function which is described on the
section 1.2. It also opens and listens on some TCP ports, and some TCP and UDP
ports will be specified as the target port of Universal Plug and Play (UPnP)
Port Transfer entries which are requested to your local routers. UPnP request
packets will be sent periodically. Some routers keep such an opened TCP/UDP
port permanently on the device. If you wish to close them, do it manually.
VPN Gate Service also provides the mirror-site function for www.vpngate.net.
This is a mechanism that a copy of the latest contents from www.vpngate.net
will be hosted by the mirror-site tiny HTTP server which is running on the VPN
Gate Service program. It will register itself on the mirror-sites list in
www.vpngate.net. However, it never relays any other communications which are
not towards www.vpngate.net.
5.4. Communication between Internet via VPN Gate Service
VPN Gate Service provides a routing between users and the Internet, by using
the Virtual NAT Function which is described on the section 2.8. VPN Gate
Service sends polling Ping packets to the server which is located on
University of Tsukuba, and the Google Public DNS Server which is identified as
8.8.8.8, in order to check the latest quality of your Internet line. VPN Gate
Service also sends and receives a lot of random packets to/from the Speed Test
Server on University of Tsukuba. These quality data will be reported to VPN
Gate Directory Server, automatically and periodically. The result will be
saved and disclosed to the public. These periodical polling communication are
adjusted not to occupy the Internet line, however in some circumstances they
might occupy the line.
5.5. Operator's Information of VPN Gate Service
If you activate VPN Gate Service on your computer, the computer will be a part
of the Global Distributed Public VPN Relay Servers. Therefore, the Operator's
administrative information of your VPN Gate Service should be reported and
registered on the VPN Gate Service Directory. Operator's information contains
the name of the operator and the abuse-reporting contact e-mail address. These
information can be inputted on the screen if the VPN Gate configuration.
Inputted information will be transmitted to the VPN Gate Directory Server,
stored and disclosed to the public. So you have to be careful to input
information. By the way, until you specify something as the operator's
information, the computer's hostname will be used automatically as the field
of the name of the operator, by appending the "'s owner" string after the
hostname.
5.6. Observe Laws to Operate VPN Gate Service
In some countries or regions, a user who is planning to activate and operate
VPN Gate Service, he are mandated to obtain a license or register a service
from/to the government. If your region has such a regulation, you must fulfill
mandated process before activating VPN Gate Service in advance. Neither the
developers nor operators of the VPN Gate Academic Experiment Project will be
liable for legal/criminal responsibilities or damages which are occurred from
failure to comply your local laws.
5.7. Protect Privacy of Communication
Most of countries have a law which requires communication service's operators,
including VPN Gate Service operators, to protect the privacy of communication
of third-persons. When you operate VPN Gate Service, you must always protect
user's privacy.
5.8. Packet Logs
The packet logging function is implemented on VPN Gate Service. It records
essential headers of major TCP/IP packets which are transmitted via the
Virtual Hub. This function will be helpful to investigate the "original IP
address" of the initiator of communication who was a connected user of your
VPN Gate Service, by checking the packet logs and the connection logs. The
packet logs are recorded only for such legitimate investigates purpose. Do not
peek nor leak packet logs except the rightful purpose. Such act will be
violate the section 5.7.
5.9. Packet Logs Automatic Archiving and Encoding Function
The VPN Gate Academic Experiment Service is operated and running under the
Japanese constitution and laws. The Japanese constitution laws demand strictly
protection over the privacy of communication. Because this service is under
Japanese rules, the program of VPN Gate Service implements this "Automatic Log
File Encoding" protection mechanism, and enabled by default.
The VPN Gate Service is currently configured to encode packet log files which
has passed two or more weeks automatically, by default. In order to protect
privacy of communication, if a packet log file is once encoded, even the
administrator of the local computer cannot censor the packet log file. This
mechanism protects privacy of end-users of VPN Gate Service.
You can change the VPN Gate Service setting to disable this automatic encoding
function. Then packet log files will never be encoded even after two weeks
passed. In such a configuration, all packet logs will remain as plain-text on
the disk. Therefore you have to take care not to violate user's privacy.
If you are liable to decode an encoded packet log files (for example: a VPN
Gate Service's user illegally abused your VPN Gate Service and you have to
decode the packet logs in order to comply the laws), contact the administrator
of the VPN Gate Academic Experiment Service at Graduate School of University
of Tsukuba, Japan. You can find the contact address at
http://www.vpngate.net/. The administrator of VPN Gate Service will respond to
decode the packet logs if there is an appropriate and legal request from court
or other judicial authorities, according to laws.
5.10. Caution if You Operate VPN Gate Service in the Japan's Territories
When a user operates VPN Gate Service in the Japan's territories, such an act
may be regulated under the Japanese Telecommunication Laws if the operation is
a subject to the law. However, in such a circumstance, according to the
"Japanese Telecommunication Business Compete Manual [supplemental version]" ,
non- profitable operations of communications are not identified as a
"telecommunication business" . So usual operators of VPN Gate Service are not
subjects to "telecommunication business operators" , and not be mandated to
register to the government. Even so, legalities to protect the privacy of
communication still imposed. As a conclusion, if you operate VPN Gate Service
in the Japan's Territories, you must not leak the secrets of communications
which are transmitted via your operating VPN Gate Service.
5.11. VPN Gate Client
If SoftEther VPN Client contains the VPN Gate Client plug-in, you can use it
to obtain the list of current operating VPN Gate Service servers in the
Internet, and make a VPN connection to a specific server on the list.
VPN Gate Client always keeps the latest list of the VPN Gate Services
periodically. Be careful if you are using a pay-per-use Internet line.
When you start the VPN Gate Client software, the screen which asks you
activate or not VPN Gate Service will be appeared. For details of VPN Gate
Service, read the above sections.
5.12. Caution before Joining or Exploiting VPN Gate Academic Experiment
Project
The VPN Gate Academic Experiment Service is operated as a research project at
the graduate school on University of Tsukuba, Japan. The service is governed
under the Japanese laws. Other countries' laws are none of our concerns nor
responsibilities.
By nature, there are almost 200 countries in the World, with different laws.
It is impossible to verify every countries' laws and regulations and make the
software comply with all countries' laws in advance to release the software.
If a user uses VPN Gate service in a specific country, and damaged by public
servants of the authority, the developer of either the service or software
will never be liable to recover or compensate such damages or criminal
responsibilities.
By using this software and service, the user must observe all concerned laws
and rules with user's own responsibility. The user will be completely liable
to any damages and responsibilities which are results of using this software
and service, regardless of either inside or outside of Japan's territory.
If you don't agree nor understand the above warnings, do not use any of VPN
Gate Academic Experiment Service functions.
VPN Gate is a research project for just academic purpose only. VPN Gate was
developed as a plug-in for SoftEther VPN and UT-VPN. However, all parts of VPN
Gate were developed on this research project at University of Tsukuba. Any
parts of VPN Gate are not developed by SoftEther Corporation. The VPN Gate
Research Project is not a subject to be led, operated, promoted nor guaranteed
by SoftEther Corporation.
5.13. The P2P Relay Function in the VPN Gate Client to strengthen the
capability of circumvention of censorship firewalls
VPN Gate Clients, which are published since January 2015, include the P2P
Relay Function. The P2P Relay Function is implemented in order to strengthen
the capability of circumvention of censorship firewalls. If the P2P Relay
Function in your VPN Gate Client is enabled, then the P2P Relay Function will
accept the incoming VPN connections from the VPN Gate users, which are located
on mainly same regions around you, and will provide the relay function to the
external remote VPN Gate Servers, which are hosted by third parties in the
free Internet environment. This P2P Relay Function never provides the shared
NAT functions nor replaces the outgoing IP address of the VPN Gate users to
your IP addresses because this P2P Relay Function only provides the
"reflection service" (hair-pin relaying), relaying from incoming VPN Gate
users to an external VPN Gate Server. In this situation, VPN tunnels via your
P2P Relay Function will be finally terminated on the external VPN Gate Server,
not your VPN Gate Client. However, the VPN Gate Server as the final
destination will record your IP address as the source IP address of VPN
tunnels which will be initiated by your P2P Relay Function. Additionally, user
packets which are transmitted via your P2P Relay Function will be recorded on
your computer as packet logs as described on the section 5.8. After you
installed the VPN Gate Client, and if the P2P Relay Function will be enabled
automatically, then all matters on the 5.2, 5.3, 5.4, 5.5, 5.6, 5.7, 5.8, 5.9,
5.10, 5.11 and 5.12 sections will be applied to you and your computer, as same
to the situation when you enabled the VPN Gate Service (the VPN Gate Server
function). If your P2P Function is enabled, then your computer's IP address
and the default operator's name which is described on the section 5.5 will be
listed on the VPN Gate Server List which is provided by the VPN Gate Project.
You can change these strings by editing the "vpn_gate_relay.config" file
manually. Note that you need to stop the VPN Client service before editing it.
The VPN Gate Client will automatically enable the P2P Relay Function on your
computer if the VPN Gate Client detects that your computer might be located in
regions where there are existing censorship firewalls. If you want to disable
the P2P Relay Function, you must set the "DisableRelayServer" flag to "true"
on the "vpn_client.config" file which is the configuration file of the VPN
Client. Note that you need to stop the VPN Client service before editing it.
The VPN Gate Client does not recognize the particular regulation of your
country or your region. The VPN Gate Client activates the P2P Relay Function
even if your country or your region has the law to restrict running P2P relay
functions. Therefore, in such a case, you must disable the P2P Relay Function
on the VPN Gate Client manually by setting the "DisableRelayServer" flag if
you reside in such a restricted area, in your own responsibility.

View File

@ -1,14 +0,0 @@
The contents of the "centos" directory were written
by Dexter Ang (https://github.com/thepoch) and has been contributed
to the SoftEther VPN Project main source-tree.
Note that SoftEther VPN Project has not tested this centos package.
Please try it at your own risk.
See also:
Files for building CentOS/RHEL RPM. #29
https://github.com/SoftEtherVPN/SoftEtherVPN/pull/29
February 18, 2004
Daiyuu Nobori
SoftEther VPN Project

View File

@ -1,56 +0,0 @@
The files here are for building an RPM package installable on CentOS 6.x/RHEL 6.x.
I (Dexter Ang, aka @thepoch) am not affiliated with the SoftEther VPN Project. Any bugs, suggestions, improvements on building an RPM should probably be reported to me.
## Install and run
After the package is built and installed, you can start the service as root:
service vpnserver start
You can also have it start automatically:
chkconfig vpnserver on
## Files
This project containts the following files to build an RPM of SoftEther VPN:
* SPEC/softethervpn.spec - The main spec file
* SOURCES/fix-makefiles.sh - Script that modifies the original makefiles so it properly makes with BUILDROOT.
* linux_??bit.mak - Makefiles modified using fix-makefiles.sh. You can replace these with the original from source, and rerun the script above.
* init.d/vpnserver - initscript
* scripts/* - scripts that are originally generated by the original makefiles.
## To Build on CentOS 6.x
As root, install the following packages:
yum -y groupinstall "Development Tools"
yum -y install ncurses-devel openssl-devel readline-devel
yum -y install rpmdevtools
As a regular user, create your rpmbuild directory structure:
rpmdev-setuptree
Copy over the files from their respective directories in this repository into your rpmbuild directory. Then
rpmbuild -ba SPECS/softethervpn.spec
The resulting RPM will be in the RPM directory. Install this as root:
rpm -Uvh RPMS/`arch`/softethervpn-4*rpm
## Known Issues
1. Currently, vpnserver hangs when stopped on CentOS 6.5. Have not had time to debug. Ticket #18 on SoftEtherVPN [https://github.com/SoftEtherVPN/SoftEtherVPN/issues/18](https://github.com/SoftEtherVPN/SoftEtherVPN/issues/18).
2. Directory structure retained as-is under /usr/vpn*.
3. Not built into separate packages (ie vpnserver, vpnclient, etc. are all in one).
4. When uninstalling, if you ran any of the SoftEtherVPN binaries, configuration and other files are generated in /usr/vpn*. So these directories will remain when you uninstall the RPM. You can delete these if you don't plan on using the configurations again.
## Personal Notes
1. This is my first time creating a spec file, creating an RPM, etc. Apologies in advance for any mistakes.
2. This was tested using sources for version: **4.04.9412**. I'll try and update this as new versions come out.

View File

@ -1,74 +0,0 @@
#!/bin/sh
# Works as of:
# %define majorversion 4.04
# %define minorversion 9412
# %define dateversion 2014.01.15
#
# sed commands could be optimized a bit, but I wanted to keep the makefiles exactly the same
# as the original to minimize issues. May modify this in the future.
#
# 32-bit
sed -i -e "s/^INSTALL_BINDIR=/INSTALL_BINDIR=\$\(DESTDIR\)/g" linux_32bit.mak
sed -i -e "s/^INSTALL_VPNSERVER_DIR=/INSTALL_VPNSERVER_DIR=\$\(DESTDIR\)/g" linux_32bit.mak
sed -i -e "s/^INSTALL_VPNBRIDGE_DIR=/INSTALL_VPNBRIDGE_DIR=\$\(DESTDIR\)/g" linux_32bit.mak
sed -i -e "s/^INSTALL_VPNCLIENT_DIR=/INSTALL_VPNCLIENT_DIR=\$\(DESTDIR\)/g" linux_32bit.mak
sed -i -e "s/^INSTALL_VPNCMD_DIR=/INSTALL_VPNCMD_DIR=\$\(DESTDIR\)/g" linux_32bit.mak
## for the echos
sed -i -e "s/^\techo/#\techo/g" linux_32bit.mak
sed -i -e "s/^\tchmod/#\tchmod/g" linux_32bit.mak
## vpnserver
sed -i -e "s/\@mkdir -p \$(INSTALL_VPNSERVER_DIR)/install -d \$(INSTALL_VPNSERVER_DIR)/g" linux_32bit.mak
sed -i -e "s/cp bin\/vpnserver\/hamcore.se2 \$(INSTALL_VPNSERVER_DIR)hamcore.se2/install -m 600 bin\/vpnserver\/hamcore.se2 \$(INSTALL_VPNSERVER_DIR)hamcore.se2/g" linux_32bit.mak
sed -i -e "s/cp bin\/vpnserver\/vpnserver \$(INSTALL_VPNSERVER_DIR)vpnserver/install -m 755 bin\/vpnserver\/vpnserver \$(INSTALL_VPNSERVER_DIR)vpnserver/g" linux_32bit.mak
## vpnbridge
sed -i -e "s/\@mkdir -p \$(INSTALL_VPNBRIDGE_DIR)/install -d \$(INSTALL_VPNBRIDGE_DIR)/g" linux_32bit.mak
sed -i -e "s/cp bin\/vpnbridge\/hamcore.se2 \$(INSTALL_VPNBRIDGE_DIR)hamcore.se2/install -m 600 bin\/vpnbridge\/hamcore.se2 \$(INSTALL_VPNBRIDGE_DIR)hamcore.se2/g" linux_32bit.mak
sed -i -e "s/cp bin\/vpnbridge\/vpnbridge \$(INSTALL_VPNBRIDGE_DIR)vpnbridge/install -m 755 bin\/vpnbridge\/vpnbridge \$(INSTALL_VPNBRIDGE_DIR)vpnbridge/g" linux_32bit.mak
## vpnclient
sed -i -e "s/\@mkdir -p \$(INSTALL_VPNCLIENT_DIR)/install -d \$(INSTALL_VPNCLIENT_DIR)/g" linux_32bit.mak
sed -i -e "s/cp bin\/vpnclient\/hamcore.se2 \$(INSTALL_VPNCLIENT_DIR)hamcore.se2/install -m 600 bin\/vpnclient\/hamcore.se2 \$(INSTALL_VPNCLIENT_DIR)hamcore.se2/g" linux_32bit.mak
sed -i -e "s/cp bin\/vpnclient\/vpnclient \$(INSTALL_VPNCLIENT_DIR)vpnclient/install -m 755 bin\/vpnclient\/vpnclient \$(INSTALL_VPNCLIENT_DIR)vpnclient/g" linux_32bit.mak
## vpncmd
sed -i -e "s/\@mkdir -p \$(INSTALL_VPNCMD_DIR)/install -d \$(INSTALL_VPNCMD_DIR)/g" linux_32bit.mak
sed -i -e "s/cp bin\/vpncmd\/hamcore.se2 \$(INSTALL_VPNCMD_DIR)hamcore.se2/install -m 600 bin\/vpncmd\/hamcore.se2 \$(INSTALL_VPNCMD_DIR)hamcore.se2/g" linux_32bit.mak
sed -i -e "s/cp bin\/vpncmd\/vpncmd \$(INSTALL_VPNCMD_DIR)vpncmd/install -m 755 bin\/vpncmd\/vpncmd \$(INSTALL_VPNCMD_DIR)vpncmd/g" linux_32bit.mak
# --------------------------------------------------
# 64-bit
sed -i -e "s/^INSTALL_BINDIR=/INSTALL_BINDIR=\$\(DESTDIR\)/g" linux_64bit.mak
sed -i -e "s/^INSTALL_VPNSERVER_DIR=/INSTALL_VPNSERVER_DIR=\$\(DESTDIR\)/g" linux_64bit.mak
sed -i -e "s/^INSTALL_VPNBRIDGE_DIR=/INSTALL_VPNBRIDGE_DIR=\$\(DESTDIR\)/g" linux_64bit.mak
sed -i -e "s/^INSTALL_VPNCLIENT_DIR=/INSTALL_VPNCLIENT_DIR=\$\(DESTDIR\)/g" linux_64bit.mak
sed -i -e "s/^INSTALL_VPNCMD_DIR=/INSTALL_VPNCMD_DIR=\$\(DESTDIR\)/g" linux_64bit.mak
## for the echos
sed -i -e "s/^\techo/#\techo/g" linux_64bit.mak
sed -i -e "s/^\tchmod/#\tchmod/g" linux_64bit.mak
## vpnserver
sed -i -e "s/\@mkdir -p \$(INSTALL_VPNSERVER_DIR)/install -d \$(INSTALL_VPNSERVER_DIR)/g" linux_64bit.mak
sed -i -e "s/cp bin\/vpnserver\/hamcore.se2 \$(INSTALL_VPNSERVER_DIR)hamcore.se2/install -m 600 bin\/vpnserver\/hamcore.se2 \$(INSTALL_VPNSERVER_DIR)hamcore.se2/g" linux_64bit.mak
sed -i -e "s/cp bin\/vpnserver\/vpnserver \$(INSTALL_VPNSERVER_DIR)vpnserver/install -m 755 bin\/vpnserver\/vpnserver \$(INSTALL_VPNSERVER_DIR)vpnserver/g" linux_64bit.mak
## vpnbridge
sed -i -e "s/\@mkdir -p \$(INSTALL_VPNBRIDGE_DIR)/install -d \$(INSTALL_VPNBRIDGE_DIR)/g" linux_64bit.mak
sed -i -e "s/cp bin\/vpnbridge\/hamcore.se2 \$(INSTALL_VPNBRIDGE_DIR)hamcore.se2/install -m 600 bin\/vpnbridge\/hamcore.se2 \$(INSTALL_VPNBRIDGE_DIR)hamcore.se2/g" linux_64bit.mak
sed -i -e "s/cp bin\/vpnbridge\/vpnbridge \$(INSTALL_VPNBRIDGE_DIR)vpnbridge/install -m 755 bin\/vpnbridge\/vpnbridge \$(INSTALL_VPNBRIDGE_DIR)vpnbridge/g" linux_64bit.mak
## vpnclient
sed -i -e "s/\@mkdir -p \$(INSTALL_VPNCLIENT_DIR)/install -d \$(INSTALL_VPNCLIENT_DIR)/g" linux_64bit.mak
sed -i -e "s/cp bin\/vpnclient\/hamcore.se2 \$(INSTALL_VPNCLIENT_DIR)hamcore.se2/install -m 600 bin\/vpnclient\/hamcore.se2 \$(INSTALL_VPNCLIENT_DIR)hamcore.se2/g" linux_64bit.mak
sed -i -e "s/cp bin\/vpnclient\/vpnclient \$(INSTALL_VPNCLIENT_DIR)vpnclient/install -m 755 bin\/vpnclient\/vpnclient \$(INSTALL_VPNCLIENT_DIR)vpnclient/g" linux_64bit.mak
## vpncmd
sed -i -e "s/\@mkdir -p \$(INSTALL_VPNCMD_DIR)/install -d \$(INSTALL_VPNCMD_DIR)/g" linux_64bit.mak
sed -i -e "s/cp bin\/vpncmd\/hamcore.se2 \$(INSTALL_VPNCMD_DIR)hamcore.se2/install -m 600 bin\/vpncmd\/hamcore.se2 \$(INSTALL_VPNCMD_DIR)hamcore.se2/g" linux_64bit.mak
sed -i -e "s/cp bin\/vpncmd\/vpncmd \$(INSTALL_VPNCMD_DIR)vpncmd/install -m 755 bin\/vpncmd\/vpncmd \$(INSTALL_VPNCMD_DIR)vpncmd/g" linux_64bit.mak

View File

@ -1,102 +0,0 @@
#!/bin/sh
#
# vpnserver This shell script takes care of starting and stopping
# SoftEther VPN server.
#
# chkconfig: - 99 1
# description: SoftEther VPN server.
#
### BEGIN INIT INFO
# Provides: vpnserver
# Required-Start: $local_fs $network
# Required-Stop: $local_fs $network
# Short-Description: start and stop SoftEther VPN server.
# Description: SoftEther VPN server.
### END INIT INFO
# Source function library.
. /etc/rc.d/init.d/functions
exec="/usr/vpnserver/vpnserver"
prog="vpnserver"
#config="<path to major config file>"
#[ -e /etc/sysconfig/$prog ] && . /etc/sysconfig/$prog
pidfile=/usr/vpnserver/.pid_3E649A678269D4A01B73BF9E3388D075
lockfile=/var/lock/subsys/$prog
start() {
[ -x $exec ] || exit 5
# [ -f $config ] || exit 6
echo -n $"Starting $prog: "
$exec start
retval=$?
echo
[ $retval -eq 0 ] && touch $lockfile
return $retval
}
stop() {
echo -n $"Stopping $prog: "
/usr/bin/timeout 60 $exec stop || /usr/bin/killall -q -9 $prog
retval=$?
echo
[ $retval -eq 0 ] && rm -f $lockfile
return $retval
}
restart() {
stop
start
}
reload() {
restart
}
force_reload() {
restart
}
rh_status() {
status -p $pidfile $prog
}
rh_status_q() {
rh_status >/dev/null 2>&1
}
case "$1" in
start)
rh_status_q && exit 0
$1
;;
stop)
rh_status_q || exit 0
$1
;;
restart)
$1
;;
reload)
rh_status_q || exit 7
$1
;;
force-reload)
force_reload
;;
status)
rh_status
;;
condrestart|try-restart)
rh_status_q || exit 0
restart
;;
*)
echo $"Usage: $0 {start|stop|status|restart|condrestart|try-restart|reload|force-reload}"
exit 2
esac
exit $?

View File

@ -1,456 +0,0 @@
# SoftEther VPN Source Code
#
# Copyright (c) Daiyuu Nobori.
# Copyright (c) SoftEther VPN Project, University of Tsukuba, Japan.
# Copyright (c) SoftEther Corporation.
# Copyright (c) all contributors on SoftEther VPN project in GitHub.
#
# http://www.softether.org/
#
# License: The Apache License, Version 2.0
# https://www.apache.org/licenses/LICENSE-2.0
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
# SOFTWARE.
#
# Platform: os=Linux, bits=32bit
# Variables
CC=gcc
OPTIONS_COMPILE_DEBUG=-D_DEBUG -DDEBUG -DUNIX -DUNIX_LINUX -D_REENTRANT -DREENTRANT -D_THREAD_SAFE -D_THREADSAFE -DTHREAD_SAFE -DTHREADSAFE -D_FILE_OFFSET_BITS=64 -I./src/ -I./src/Cedar/ -I./src/Mayaqua/ -g -fsigned-char
OPTIONS_LINK_DEBUG=-g -fsigned-char -lm -ldl -lrt -lpthread -lssl -lcrypto -lreadline -lncurses -lz
OPTIONS_COMPILE_RELEASE=-DNDEBUG -DVPN_SPEED -DUNIX -DUNIX_LINUX -D_REENTRANT -DREENTRANT -D_THREAD_SAFE -D_THREADSAFE -DTHREAD_SAFE -DTHREADSAFE -D_FILE_OFFSET_BITS=64 -I./src/ -I./src/Cedar/ -I./src/Mayaqua/ -O2 -fsigned-char
OPTIONS_LINK_RELEASE=-O2 -fsigned-char -lm -ldl -lrt -lpthread -lssl -lcrypto -lreadline -lncurses -lz
INSTALL_BINDIR=$(DESTDIR)/usr/bin/
INSTALL_VPNSERVER_DIR=$(DESTDIR)/usr/vpnserver/
INSTALL_VPNBRIDGE_DIR=$(DESTDIR)/usr/vpnbridge/
INSTALL_VPNCLIENT_DIR=$(DESTDIR)/usr/vpnclient/
INSTALL_VPNCMD_DIR=$(DESTDIR)/usr/vpncmd/
ifeq ($(DEBUG),YES)
OPTIONS_COMPILE=$(OPTIONS_COMPILE_DEBUG)
OPTIONS_LINK=$(OPTIONS_LINK_DEBUG)
else
OPTIONS_COMPILE=$(OPTIONS_COMPILE_RELEASE)
OPTIONS_LINK=$(OPTIONS_LINK_RELEASE)
endif
# Files
HEADERS_MAYAQUA=src/Mayaqua/Cfg.h src/Mayaqua/cryptoki.h src/Mayaqua/Encrypt.h src/Mayaqua/FileIO.h src/Mayaqua/intelaes/iaesni.h src/Mayaqua/Internat.h src/Mayaqua/Kernel.h src/Mayaqua/Mayaqua.h src/Mayaqua/MayaType.h src/Mayaqua/Memory.h src/Mayaqua/Microsoft.h src/Mayaqua/Network.h src/Mayaqua/Object.h src/Mayaqua/OS.h src/Mayaqua/Pack.h src/Mayaqua/pkcs11.h src/Mayaqua/pkcs11f.h src/Mayaqua/pkcs11t.h src/Mayaqua/Secure.h src/Mayaqua/Str.h src/Mayaqua/Table.h src/Mayaqua/TcpIp.h src/Mayaqua/Tick64.h src/Mayaqua/Tracking.h src/Mayaqua/TunTap.h src/Mayaqua/Unix.h src/Mayaqua/Win32.h src/Mayaqua/zlib/zconf.h src/Mayaqua/zlib/zlib.h
HEADERS_CEDAR=src/Cedar/Account.h src/Cedar/Admin.h src/Cedar/AzureClient.h src/Cedar/AzureServer.h src/Cedar/Bridge.h src/Cedar/BridgeUnix.h src/Cedar/BridgeWin32.h src/Cedar/Cedar.h src/Cedar/CedarPch.h src/Cedar/CedarType.h src/Cedar/Client.h src/Cedar/CM.h src/Cedar/CMInner.h src/Cedar/Command.h src/Cedar/Connection.h src/Cedar/Console.h src/Cedar/Database.h src/Cedar/DDNS.h src/Cedar/EM.h src/Cedar/EMInner.h src/Cedar/EtherLog.h src/Cedar/Hub.h src/Cedar/Interop_OpenVPN.h src/Cedar/Interop_SSTP.h src/Cedar/IPsec.h src/Cedar/IPsec_EtherIP.h src/Cedar/IPsec_IKE.h src/Cedar/IPsec_IkePacket.h src/Cedar/IPsec_IPC.h src/Cedar/IPsec_L2TP.h src/Cedar/IPsec_PPP.h src/Cedar/IPsec_Win7.h src/Cedar/IPsec_Win7Inner.h src/Cedar/Layer3.h src/Cedar/Link.h src/Cedar/Listener.h src/Cedar/Logging.h src/Cedar/Nat.h src/Cedar/NativeStack.h src/Cedar/netcfgn.h src/Cedar/netcfgx.h src/Cedar/NM.h src/Cedar/NMInner.h src/Cedar/NullLan.h src/Cedar/Protocol.h src/Cedar/Radius.h src/Cedar/Remote.h src/Cedar/Sam.h src/Cedar/SecureInfo.h src/Cedar/SecureNAT.h src/Cedar/SeLowUser.h src/Cedar/Server.h src/Cedar/Session.h src/Cedar/SM.h src/Cedar/SMInner.h src/Cedar/SW.h src/Cedar/SWInner.h src/Cedar/UdpAccel.h src/Cedar/UT.h src/Cedar/VG.h src/Cedar/Virtual.h src/Cedar/VLan.h src/Cedar/VLanUnix.h src/Cedar/VLanWin32.h src/Cedar/WaterMark.h src/Cedar/WebUI.h src/Cedar/Win32Com.h src/Cedar/winpcap/bittypes.h src/Cedar/winpcap/bucket_lookup.h src/Cedar/winpcap/count_packets.h src/Cedar/winpcap/Devioctl.h src/Cedar/winpcap/Gnuc.h src/Cedar/winpcap/ip6_misc.h src/Cedar/winpcap/memory_t.h src/Cedar/winpcap/normal_lookup.h src/Cedar/winpcap/Ntddndis.h src/Cedar/winpcap/Ntddpack.h src/Cedar/winpcap/Packet32.h src/Cedar/winpcap/pcap.h src/Cedar/winpcap/pcap-bpf.h src/Cedar/winpcap/pcap-int.h src/Cedar/winpcap/pcap-stdinc.h src/Cedar/winpcap/pthread.h src/Cedar/winpcap/remote-ext.h src/Cedar/winpcap/sched.h src/Cedar/winpcap/semaphore.h src/Cedar/winpcap/tcp_session.h src/Cedar/winpcap/time_calls.h src/Cedar/winpcap/tme.h src/Cedar/winpcap/Win32-Extensions.h src/Cedar/WinUi.h src/Cedar/Wpc.h
OBJECTS_MAYAQUA=tmp/objs/Mayaqua/Cfg.o tmp/objs/Mayaqua/Encrypt.o tmp/objs/Mayaqua/FileIO.o tmp/objs/Mayaqua/Internat.o tmp/objs/Mayaqua/Kernel.o tmp/objs/Mayaqua/Mayaqua.o tmp/objs/Mayaqua/Memory.o tmp/objs/Mayaqua/Microsoft.o tmp/objs/Mayaqua/Network.o tmp/objs/Mayaqua/Object.o tmp/objs/Mayaqua/OS.o tmp/objs/Mayaqua/Pack.o tmp/objs/Mayaqua/Secure.o tmp/objs/Mayaqua/Str.o tmp/objs/Mayaqua/Table.o tmp/objs/Mayaqua/TcpIp.o tmp/objs/Mayaqua/Tick64.o tmp/objs/Mayaqua/Tracking.o tmp/objs/Mayaqua/Unix.o tmp/objs/Mayaqua/Win32.o
OBJECTS_CEDAR=tmp/objs/Cedar/Account.o tmp/objs/Cedar/Admin.o tmp/objs/Cedar/AzureClient.o tmp/objs/Cedar/AzureServer.o tmp/objs/Cedar/Bridge.o tmp/objs/Cedar/BridgeUnix.o tmp/objs/Cedar/BridgeWin32.o tmp/objs/Cedar/Cedar.o tmp/objs/Cedar/CedarPch.o tmp/objs/Cedar/Client.o tmp/objs/Cedar/CM.o tmp/objs/Cedar/Command.o tmp/objs/Cedar/Connection.o tmp/objs/Cedar/Console.o tmp/objs/Cedar/Database.o tmp/objs/Cedar/DDNS.o tmp/objs/Cedar/EM.o tmp/objs/Cedar/EtherLog.o tmp/objs/Cedar/Hub.o tmp/objs/Cedar/Interop_OpenVPN.o tmp/objs/Cedar/Interop_SSTP.o tmp/objs/Cedar/IPsec.o tmp/objs/Cedar/IPsec_EtherIP.o tmp/objs/Cedar/IPsec_IKE.o tmp/objs/Cedar/IPsec_IkePacket.o tmp/objs/Cedar/IPsec_IPC.o tmp/objs/Cedar/IPsec_L2TP.o tmp/objs/Cedar/IPsec_PPP.o tmp/objs/Cedar/IPsec_Win7.o tmp/objs/Cedar/Layer3.o tmp/objs/Cedar/Link.o tmp/objs/Cedar/Listener.o tmp/objs/Cedar/Logging.o tmp/objs/Cedar/Nat.o tmp/objs/Cedar/NativeStack.o tmp/objs/Cedar/NM.o tmp/objs/Cedar/NullLan.o tmp/objs/Cedar/Protocol.o tmp/objs/Cedar/Radius.o tmp/objs/Cedar/Remote.o tmp/objs/Cedar/Sam.o tmp/objs/Cedar/SecureInfo.o tmp/objs/Cedar/SecureNAT.o tmp/objs/Cedar/SeLowUser.o tmp/objs/Cedar/Server.o tmp/objs/Cedar/Session.o tmp/objs/Cedar/SM.o tmp/objs/Cedar/SW.o tmp/objs/Cedar/UdpAccel.o tmp/objs/Cedar/UT.o tmp/objs/Cedar/VG.o tmp/objs/Cedar/Virtual.o tmp/objs/Cedar/VLan.o tmp/objs/Cedar/VLanUnix.o tmp/objs/Cedar/VLanWin32.o tmp/objs/Cedar/WaterMark.o tmp/objs/Cedar/WebUI.o tmp/objs/Cedar/WinUi.o tmp/objs/Cedar/Wpc.o
HAMCORE_FILES=src/bin/hamcore/authors.txt src/bin/hamcore/backup_dir_readme.txt src/bin/hamcore/empty.config src/bin/hamcore/empty_sevpnclient.config src/bin/hamcore/eula.txt src/bin/hamcore/install_src.dat src/bin/hamcore/lang.config src/bin/hamcore/languages.txt src/bin/hamcore/legal.txt src/bin/hamcore/openvpn_readme.pdf src/bin/hamcore/openvpn_readme.txt src/bin/hamcore/openvpn_sample.ovpn src/bin/hamcore/root_certs.dat src/bin/hamcore/SOURCES_OF_BINARY_FILES.TXT src/bin/hamcore/strtable_cn.stb src/bin/hamcore/strtable_en.stb src/bin/hamcore/strtable_ja.stb src/bin/hamcore/vpnweb_sample_cn.htm src/bin/hamcore/vpnweb_sample_en.htm src/bin/hamcore/vpnweb_sample_ja.htm src/bin/hamcore/warning_cn.txt src/bin/hamcore/warning_en.txt src/bin/hamcore/warning_ja.txt src/bin/hamcore/webui/cryptcom.cgi src/bin/hamcore/webui/edituser.cgi src/bin/hamcore/webui/error.cgi src/bin/hamcore/webui/hub.cgi src/bin/hamcore/webui/license.cgi src/bin/hamcore/webui/listener.cgi src/bin/hamcore/webui/localbridge.cgi src/bin/hamcore/webui/login.cgi src/bin/hamcore/webui/newhub.cgi src/bin/hamcore/webui/redirect.cgi src/bin/hamcore/webui/securenat.cgi src/bin/hamcore/webui/server.cgi src/bin/hamcore/webui/session.cgi src/bin/hamcore/webui/user.cgi src/bin/hamcore/webui/webui.css
# Build Action
default: build
build: $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR) bin/vpnserver/vpnserver bin/vpnclient/vpnclient bin/vpnbridge/vpnbridge bin/vpncmd/vpncmd
# Mayaqua Kernel Code
tmp/objs/Mayaqua/Cfg.o: src/Mayaqua/Cfg.c $(HEADERS_MAYAQUA)
@mkdir -p tmp/
@mkdir -p tmp/objs/
@mkdir -p tmp/objs/Mayaqua/
@mkdir -p tmp/objs/Cedar/
@mkdir -p tmp/as/
@mkdir -p bin/
@mkdir -p bin/vpnserver/
@mkdir -p bin/vpnclient/
@mkdir -p bin/vpnbridge/
@mkdir -p bin/vpncmd/
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/Cfg.c -o tmp/objs/Mayaqua/Cfg.o
tmp/objs/Mayaqua/Encrypt.o: src/Mayaqua/Encrypt.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/Encrypt.c -o tmp/objs/Mayaqua/Encrypt.o
tmp/objs/Mayaqua/FileIO.o: src/Mayaqua/FileIO.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/FileIO.c -o tmp/objs/Mayaqua/FileIO.o
tmp/objs/Mayaqua/Internat.o: src/Mayaqua/Internat.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/Internat.c -o tmp/objs/Mayaqua/Internat.o
tmp/objs/Mayaqua/Kernel.o: src/Mayaqua/Kernel.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/Kernel.c -o tmp/objs/Mayaqua/Kernel.o
tmp/objs/Mayaqua/Mayaqua.o: src/Mayaqua/Mayaqua.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/Mayaqua.c -o tmp/objs/Mayaqua/Mayaqua.o
tmp/objs/Mayaqua/Memory.o: src/Mayaqua/Memory.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/Memory.c -o tmp/objs/Mayaqua/Memory.o
tmp/objs/Mayaqua/Microsoft.o: src/Mayaqua/Microsoft.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/Microsoft.c -o tmp/objs/Mayaqua/Microsoft.o
tmp/objs/Mayaqua/Network.o: src/Mayaqua/Network.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/Network.c -o tmp/objs/Mayaqua/Network.o
tmp/objs/Mayaqua/Object.o: src/Mayaqua/Object.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/Object.c -o tmp/objs/Mayaqua/Object.o
tmp/objs/Mayaqua/OS.o: src/Mayaqua/OS.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/OS.c -o tmp/objs/Mayaqua/OS.o
tmp/objs/Mayaqua/Pack.o: src/Mayaqua/Pack.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/Pack.c -o tmp/objs/Mayaqua/Pack.o
tmp/objs/Mayaqua/Secure.o: src/Mayaqua/Secure.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/Secure.c -o tmp/objs/Mayaqua/Secure.o
tmp/objs/Mayaqua/Str.o: src/Mayaqua/Str.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/Str.c -o tmp/objs/Mayaqua/Str.o
tmp/objs/Mayaqua/Table.o: src/Mayaqua/Table.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/Table.c -o tmp/objs/Mayaqua/Table.o
tmp/objs/Mayaqua/TcpIp.o: src/Mayaqua/TcpIp.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/TcpIp.c -o tmp/objs/Mayaqua/TcpIp.o
tmp/objs/Mayaqua/Tick64.o: src/Mayaqua/Tick64.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/Tick64.c -o tmp/objs/Mayaqua/Tick64.o
tmp/objs/Mayaqua/Tracking.o: src/Mayaqua/Tracking.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/Tracking.c -o tmp/objs/Mayaqua/Tracking.o
tmp/objs/Mayaqua/Unix.o: src/Mayaqua/Unix.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/Unix.c -o tmp/objs/Mayaqua/Unix.o
tmp/objs/Mayaqua/Win32.o: src/Mayaqua/Win32.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/Win32.c -o tmp/objs/Mayaqua/Win32.o
# Cedar Communication Module Code
tmp/objs/Cedar/Account.o: src/Cedar/Account.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Account.c -o tmp/objs/Cedar/Account.o
tmp/objs/Cedar/Admin.o: src/Cedar/Admin.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Admin.c -o tmp/objs/Cedar/Admin.o
tmp/objs/Cedar/AzureClient.o: src/Cedar/AzureClient.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/AzureClient.c -o tmp/objs/Cedar/AzureClient.o
tmp/objs/Cedar/AzureServer.o: src/Cedar/AzureServer.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/AzureServer.c -o tmp/objs/Cedar/AzureServer.o
tmp/objs/Cedar/Bridge.o: src/Cedar/Bridge.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR) src/Cedar/BridgeUnix.c
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Bridge.c -o tmp/objs/Cedar/Bridge.o
tmp/objs/Cedar/BridgeUnix.o: src/Cedar/BridgeUnix.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/BridgeUnix.c -o tmp/objs/Cedar/BridgeUnix.o
tmp/objs/Cedar/BridgeWin32.o: src/Cedar/BridgeWin32.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/BridgeWin32.c -o tmp/objs/Cedar/BridgeWin32.o
tmp/objs/Cedar/Cedar.o: src/Cedar/Cedar.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Cedar.c -o tmp/objs/Cedar/Cedar.o
tmp/objs/Cedar/CedarPch.o: src/Cedar/CedarPch.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/CedarPch.c -o tmp/objs/Cedar/CedarPch.o
tmp/objs/Cedar/Client.o: src/Cedar/Client.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Client.c -o tmp/objs/Cedar/Client.o
tmp/objs/Cedar/CM.o: src/Cedar/CM.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/CM.c -o tmp/objs/Cedar/CM.o
tmp/objs/Cedar/Command.o: src/Cedar/Command.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Command.c -o tmp/objs/Cedar/Command.o
tmp/objs/Cedar/Connection.o: src/Cedar/Connection.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Connection.c -o tmp/objs/Cedar/Connection.o
tmp/objs/Cedar/Console.o: src/Cedar/Console.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Console.c -o tmp/objs/Cedar/Console.o
tmp/objs/Cedar/Database.o: src/Cedar/Database.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Database.c -o tmp/objs/Cedar/Database.o
tmp/objs/Cedar/DDNS.o: src/Cedar/DDNS.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/DDNS.c -o tmp/objs/Cedar/DDNS.o
tmp/objs/Cedar/EM.o: src/Cedar/EM.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/EM.c -o tmp/objs/Cedar/EM.o
tmp/objs/Cedar/EtherLog.o: src/Cedar/EtherLog.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/EtherLog.c -o tmp/objs/Cedar/EtherLog.o
tmp/objs/Cedar/Hub.o: src/Cedar/Hub.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Hub.c -o tmp/objs/Cedar/Hub.o
tmp/objs/Cedar/Interop_OpenVPN.o: src/Cedar/Interop_OpenVPN.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Interop_OpenVPN.c -o tmp/objs/Cedar/Interop_OpenVPN.o
tmp/objs/Cedar/Interop_SSTP.o: src/Cedar/Interop_SSTP.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Interop_SSTP.c -o tmp/objs/Cedar/Interop_SSTP.o
tmp/objs/Cedar/IPsec.o: src/Cedar/IPsec.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/IPsec.c -o tmp/objs/Cedar/IPsec.o
tmp/objs/Cedar/IPsec_EtherIP.o: src/Cedar/IPsec_EtherIP.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/IPsec_EtherIP.c -o tmp/objs/Cedar/IPsec_EtherIP.o
tmp/objs/Cedar/IPsec_IKE.o: src/Cedar/IPsec_IKE.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/IPsec_IKE.c -o tmp/objs/Cedar/IPsec_IKE.o
tmp/objs/Cedar/IPsec_IkePacket.o: src/Cedar/IPsec_IkePacket.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/IPsec_IkePacket.c -o tmp/objs/Cedar/IPsec_IkePacket.o
tmp/objs/Cedar/IPsec_IPC.o: src/Cedar/IPsec_IPC.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/IPsec_IPC.c -o tmp/objs/Cedar/IPsec_IPC.o
tmp/objs/Cedar/IPsec_L2TP.o: src/Cedar/IPsec_L2TP.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/IPsec_L2TP.c -o tmp/objs/Cedar/IPsec_L2TP.o
tmp/objs/Cedar/IPsec_PPP.o: src/Cedar/IPsec_PPP.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/IPsec_PPP.c -o tmp/objs/Cedar/IPsec_PPP.o
tmp/objs/Cedar/IPsec_Win7.o: src/Cedar/IPsec_Win7.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/IPsec_Win7.c -o tmp/objs/Cedar/IPsec_Win7.o
tmp/objs/Cedar/Layer3.o: src/Cedar/Layer3.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Layer3.c -o tmp/objs/Cedar/Layer3.o
tmp/objs/Cedar/Link.o: src/Cedar/Link.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Link.c -o tmp/objs/Cedar/Link.o
tmp/objs/Cedar/Listener.o: src/Cedar/Listener.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Listener.c -o tmp/objs/Cedar/Listener.o
tmp/objs/Cedar/Logging.o: src/Cedar/Logging.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Logging.c -o tmp/objs/Cedar/Logging.o
tmp/objs/Cedar/Nat.o: src/Cedar/Nat.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Nat.c -o tmp/objs/Cedar/Nat.o
tmp/objs/Cedar/NativeStack.o: src/Cedar/NativeStack.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/NativeStack.c -o tmp/objs/Cedar/NativeStack.o
tmp/objs/Cedar/NM.o: src/Cedar/NM.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/NM.c -o tmp/objs/Cedar/NM.o
tmp/objs/Cedar/NullLan.o: src/Cedar/NullLan.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/NullLan.c -o tmp/objs/Cedar/NullLan.o
tmp/objs/Cedar/Protocol.o: src/Cedar/Protocol.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Protocol.c -o tmp/objs/Cedar/Protocol.o
tmp/objs/Cedar/Radius.o: src/Cedar/Radius.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Radius.c -o tmp/objs/Cedar/Radius.o
tmp/objs/Cedar/Remote.o: src/Cedar/Remote.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Remote.c -o tmp/objs/Cedar/Remote.o
tmp/objs/Cedar/Sam.o: src/Cedar/Sam.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Sam.c -o tmp/objs/Cedar/Sam.o
tmp/objs/Cedar/SecureInfo.o: src/Cedar/SecureInfo.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/SecureInfo.c -o tmp/objs/Cedar/SecureInfo.o
tmp/objs/Cedar/SecureNAT.o: src/Cedar/SecureNAT.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/SecureNAT.c -o tmp/objs/Cedar/SecureNAT.o
tmp/objs/Cedar/SeLowUser.o: src/Cedar/SeLowUser.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/SeLowUser.c -o tmp/objs/Cedar/SeLowUser.o
tmp/objs/Cedar/Server.o: src/Cedar/Server.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Server.c -o tmp/objs/Cedar/Server.o
tmp/objs/Cedar/Session.o: src/Cedar/Session.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Session.c -o tmp/objs/Cedar/Session.o
tmp/objs/Cedar/SM.o: src/Cedar/SM.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/SM.c -o tmp/objs/Cedar/SM.o
tmp/objs/Cedar/SW.o: src/Cedar/SW.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/SW.c -o tmp/objs/Cedar/SW.o
tmp/objs/Cedar/UdpAccel.o: src/Cedar/UdpAccel.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/UdpAccel.c -o tmp/objs/Cedar/UdpAccel.o
tmp/objs/Cedar/UT.o: src/Cedar/UT.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/UT.c -o tmp/objs/Cedar/UT.o
tmp/objs/Cedar/VG.o: src/Cedar/VG.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/VG.c -o tmp/objs/Cedar/VG.o
tmp/objs/Cedar/Virtual.o: src/Cedar/Virtual.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Virtual.c -o tmp/objs/Cedar/Virtual.o
tmp/objs/Cedar/VLan.o: src/Cedar/VLan.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/VLan.c -o tmp/objs/Cedar/VLan.o
tmp/objs/Cedar/VLanUnix.o: src/Cedar/VLanUnix.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/VLanUnix.c -o tmp/objs/Cedar/VLanUnix.o
tmp/objs/Cedar/VLanWin32.o: src/Cedar/VLanWin32.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/VLanWin32.c -o tmp/objs/Cedar/VLanWin32.o
tmp/objs/Cedar/WaterMark.o: src/Cedar/WaterMark.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/WaterMark.c -o tmp/objs/Cedar/WaterMark.o
tmp/objs/Cedar/WebUI.o: src/Cedar/WebUI.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/WebUI.c -o tmp/objs/Cedar/WebUI.o
tmp/objs/Cedar/WinUi.o: src/Cedar/WinUi.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/WinUi.c -o tmp/objs/Cedar/WinUi.o
tmp/objs/Cedar/Wpc.o: src/Cedar/Wpc.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Wpc.c -o tmp/objs/Cedar/Wpc.o
# hamcore.se2 Archive File
src/bin/BuiltHamcoreFiles/unix/hamcore.se2: tmp/hamcorebuilder $(HAMCORE_FILES)
@mkdir -p src/bin/BuiltHamcoreFiles/unix/
tmp/hamcorebuilder src/bin/hamcore/ src/bin/BuiltHamcoreFiles/unix/hamcore.se2
# hamcorebuilder Utility
tmp/hamcorebuilder: src/hamcorebuilder/hamcorebuilder.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR) $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR)
@mkdir -p tmp/
$(CC) $(OPTIONS_COMPILE) $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR) src/hamcorebuilder/hamcorebuilder.c $(OPTIONS_LINK) -o tmp/hamcorebuilder
# vpnserver
bin/vpnserver/vpnserver: tmp/as/vpnserver.a bin/vpnserver/hamcore.se2 $(HEADERS_MAYAQUA) $(HEADERS_CEDAR) $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR)
$(CC) tmp/as/vpnserver.a $(OPTIONS_LINK) -o bin/vpnserver/vpnserver
tmp/as/vpnserver.a: tmp/objs/vpnserver.o $(HEADERS_MAYAQUA) $(HEADERS_CEDAR) $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR)
rm -f tmp/as/vpnserver.a
ar r tmp/as/vpnserver.a $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR) tmp/objs/vpnserver.o
ranlib tmp/as/vpnserver.a
bin/vpnserver/hamcore.se2: src/bin/BuiltHamcoreFiles/unix/hamcore.se2
cp src/bin/BuiltHamcoreFiles/unix/hamcore.se2 bin/vpnserver/hamcore.se2
tmp/objs/vpnserver.o: src/vpnserver/vpnserver.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR) $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/vpnserver/vpnserver.c -o tmp/objs/vpnserver.o
# vpnclient
bin/vpnclient/vpnclient: tmp/as/vpnclient.a bin/vpnclient/hamcore.se2 $(HEADERS_MAYAQUA) $(HEADERS_CEDAR) $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR)
$(CC) tmp/as/vpnclient.a $(OPTIONS_LINK) -o bin/vpnclient/vpnclient
tmp/as/vpnclient.a: tmp/objs/vpnclient.o $(HEADERS_MAYAQUA) $(HEADERS_CEDAR) $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR)
rm -f tmp/as/vpnclient.a
ar r tmp/as/vpnclient.a $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR) tmp/objs/vpnclient.o
ranlib tmp/as/vpnclient.a
bin/vpnclient/hamcore.se2: src/bin/BuiltHamcoreFiles/unix/hamcore.se2
cp src/bin/BuiltHamcoreFiles/unix/hamcore.se2 bin/vpnclient/hamcore.se2
tmp/objs/vpnclient.o: src/vpnclient/vpncsvc.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR) $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/vpnclient/vpncsvc.c -o tmp/objs/vpnclient.o
# vpnbridge
bin/vpnbridge/vpnbridge: tmp/as/vpnbridge.a bin/vpnbridge/hamcore.se2 $(HEADERS_MAYAQUA) $(HEADERS_CEDAR) $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR)
$(CC) tmp/as/vpnbridge.a $(OPTIONS_LINK) -o bin/vpnbridge/vpnbridge
tmp/as/vpnbridge.a: tmp/objs/vpnbridge.o $(HEADERS_MAYAQUA) $(HEADERS_CEDAR) $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR)
rm -f tmp/as/vpnbridge.a
ar r tmp/as/vpnbridge.a $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR) tmp/objs/vpnbridge.o
ranlib tmp/as/vpnbridge.a
bin/vpnbridge/hamcore.se2: src/bin/BuiltHamcoreFiles/unix/hamcore.se2
cp src/bin/BuiltHamcoreFiles/unix/hamcore.se2 bin/vpnbridge/hamcore.se2
tmp/objs/vpnbridge.o: src/vpnbridge/vpnbridge.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR) $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/vpnbridge/vpnbridge.c -o tmp/objs/vpnbridge.o
# vpncmd
bin/vpncmd/vpncmd: tmp/as/vpncmd.a bin/vpncmd/hamcore.se2 $(HEADERS_MAYAQUA) $(HEADERS_CEDAR) $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR)
$(CC) tmp/as/vpncmd.a $(OPTIONS_LINK) -o bin/vpncmd/vpncmd
tmp/as/vpncmd.a: tmp/objs/vpncmd.o $(HEADERS_MAYAQUA) $(HEADERS_CEDAR) $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR)
rm -f tmp/as/vpncmd.a
ar r tmp/as/vpncmd.a $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR) tmp/objs/vpncmd.o
ranlib tmp/as/vpncmd.a
bin/vpncmd/hamcore.se2: src/bin/BuiltHamcoreFiles/unix/hamcore.se2
cp src/bin/BuiltHamcoreFiles/unix/hamcore.se2 bin/vpncmd/hamcore.se2
tmp/objs/vpncmd.o: src/vpncmd/vpncmd.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR) $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/vpncmd/vpncmd.c -o tmp/objs/vpncmd.o
# Install
install: $(INSTALL_BINDIR)vpnserver $(INSTALL_BINDIR)vpnbridge $(INSTALL_BINDIR)vpnclient $(INSTALL_BINDIR)vpncmd
@echo
@echo "--------------------------------------------------------------------"
@echo "Installation completed successfully."
@echo
@echo "Execute 'vpnserver start' to run the SoftEther VPN Server background service."
@echo "Execute 'vpnbridge start' to run the SoftEther VPN Bridge background service."
@echo "Execute 'vpnclient start' to run the SoftEther VPN Client background service."
@echo "Execute 'vpncmd' to run SoftEther VPN Command-Line Utility to configure VPN Server, VPN Bridge or VPN Client."
@echo "--------------------------------------------------------------------"
@echo
$(INSTALL_BINDIR)vpnserver: bin/vpnserver/hamcore.se2 bin/vpnserver/vpnserver
install -d $(INSTALL_VPNSERVER_DIR)
install -m 600 bin/vpnserver/hamcore.se2 $(INSTALL_VPNSERVER_DIR)hamcore.se2
install -m 755 bin/vpnserver/vpnserver $(INSTALL_VPNSERVER_DIR)vpnserver
# echo "#!/bin/sh" > $(INSTALL_BINDIR)vpnserver
# echo $(INSTALL_VPNSERVER_DIR)vpnserver '"$$@"' >> $(INSTALL_BINDIR)vpnserver
# echo 'exit $$?' >> $(INSTALL_BINDIR)vpnserver
# chmod 755 $(INSTALL_BINDIR)vpnserver
$(INSTALL_BINDIR)vpnbridge: bin/vpnbridge/hamcore.se2 bin/vpnbridge/vpnbridge
install -d $(INSTALL_VPNBRIDGE_DIR)
install -m 600 bin/vpnbridge/hamcore.se2 $(INSTALL_VPNBRIDGE_DIR)hamcore.se2
install -m 755 bin/vpnbridge/vpnbridge $(INSTALL_VPNBRIDGE_DIR)vpnbridge
# echo "#!/bin/sh" > $(INSTALL_BINDIR)vpnbridge
# echo $(INSTALL_VPNBRIDGE_DIR)vpnbridge '"$$@"' >> $(INSTALL_BINDIR)vpnbridge
# echo 'exit $$?' >> $(INSTALL_BINDIR)vpnbridge
# chmod 755 $(INSTALL_BINDIR)vpnbridge
$(INSTALL_BINDIR)vpnclient: bin/vpnclient/hamcore.se2 bin/vpnclient/vpnclient
install -d $(INSTALL_VPNCLIENT_DIR)
install -m 600 bin/vpnclient/hamcore.se2 $(INSTALL_VPNCLIENT_DIR)hamcore.se2
install -m 755 bin/vpnclient/vpnclient $(INSTALL_VPNCLIENT_DIR)vpnclient
# echo "#!/bin/sh" > $(INSTALL_BINDIR)vpnclient
# echo $(INSTALL_VPNCLIENT_DIR)vpnclient '"$$@"' >> $(INSTALL_BINDIR)vpnclient
# echo 'exit $$?' >> $(INSTALL_BINDIR)vpnclient
# chmod 755 $(INSTALL_BINDIR)vpnclient
$(INSTALL_BINDIR)vpncmd: bin/vpncmd/hamcore.se2 bin/vpncmd/vpncmd
install -d $(INSTALL_VPNCMD_DIR)
install -m 600 bin/vpncmd/hamcore.se2 $(INSTALL_VPNCMD_DIR)hamcore.se2
install -m 755 bin/vpncmd/vpncmd $(INSTALL_VPNCMD_DIR)vpncmd
# echo "#!/bin/sh" > $(INSTALL_BINDIR)vpncmd
# echo $(INSTALL_VPNCMD_DIR)vpncmd '"$$@"' >> $(INSTALL_BINDIR)vpncmd
# echo 'exit $$?' >> $(INSTALL_BINDIR)vpncmd
# chmod 755 $(INSTALL_BINDIR)vpncmd
# Clean
clean:
-rm -f $(OBJECTS_MAYAQUA)
-rm -f $(OBJECTS_CEDAR)
-rm -f tmp/objs/vpnserver.o
-rm -f tmp/as/vpnserver.a
-rm -f bin/vpnserver/vpnserver
-rm -f bin/vpnserver/hamcore.se2
-rm -f tmp/objs/vpnclient.o
-rm -f tmp/as/vpnclient.a
-rm -f bin/vpnclient/vpnclient
-rm -f bin/vpnclient/hamcore.se2
-rm -f tmp/objs/vpnbridge.o
-rm -f tmp/as/vpnbridge.a
-rm -f bin/vpnbridge/vpnbridge
-rm -f bin/vpnbridge/hamcore.se2
-rm -f tmp/objs/vpncmd.o
-rm -f tmp/as/vpncmd.a
-rm -f bin/vpncmd/vpncmd
-rm -f bin/vpncmd/hamcore.se2
-rm -f tmp/hamcorebuilder
-rm -f src/bin/BuiltHamcoreFiles/unix/hamcore.se2
# Help Strings
help:
@echo "make [DEBUG=YES]"
@echo "make install"
@echo "make clean"

View File

@ -1,456 +0,0 @@
# SoftEther VPN Source Code
#
# Copyright (c) Daiyuu Nobori.
# Copyright (c) SoftEther VPN Project, University of Tsukuba, Japan.
# Copyright (c) SoftEther Corporation.
# Copyright (c) all contributors on SoftEther VPN project in GitHub.
#
# http://www.softether.org/
#
# License: The Apache License, Version 2.0
# https://www.apache.org/licenses/LICENSE-2.0
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
# SOFTWARE.
#
# Platform: os=Linux, bits=64bit
# Variables
CC=gcc
OPTIONS_COMPILE_DEBUG=-D_DEBUG -DDEBUG -DUNIX -DUNIX_LINUX -DCPU_64 -D_REENTRANT -DREENTRANT -D_THREAD_SAFE -D_THREADSAFE -DTHREAD_SAFE -DTHREADSAFE -D_FILE_OFFSET_BITS=64 -I./src/ -I./src/Cedar/ -I./src/Mayaqua/ -g -fsigned-char -m64
OPTIONS_LINK_DEBUG=-g -fsigned-char -m64 -lm -ldl -lrt -lpthread -lssl -lcrypto -lreadline -lncurses -lz
OPTIONS_COMPILE_RELEASE=-DNDEBUG -DVPN_SPEED -DUNIX -DUNIX_LINUX -DCPU_64 -D_REENTRANT -DREENTRANT -D_THREAD_SAFE -D_THREADSAFE -DTHREAD_SAFE -DTHREADSAFE -D_FILE_OFFSET_BITS=64 -I./src/ -I./src/Cedar/ -I./src/Mayaqua/ -O2 -fsigned-char -m64
OPTIONS_LINK_RELEASE=-O2 -fsigned-char -m64 -lm -ldl -lrt -lpthread -lssl -lcrypto -lreadline -lncurses -lz
INSTALL_BINDIR=$(DESTDIR)/usr/bin/
INSTALL_VPNSERVER_DIR=$(DESTDIR)/usr/vpnserver/
INSTALL_VPNBRIDGE_DIR=$(DESTDIR)/usr/vpnbridge/
INSTALL_VPNCLIENT_DIR=$(DESTDIR)/usr/vpnclient/
INSTALL_VPNCMD_DIR=$(DESTDIR)/usr/vpncmd/
ifeq ($(DEBUG),YES)
OPTIONS_COMPILE=$(OPTIONS_COMPILE_DEBUG)
OPTIONS_LINK=$(OPTIONS_LINK_DEBUG)
else
OPTIONS_COMPILE=$(OPTIONS_COMPILE_RELEASE)
OPTIONS_LINK=$(OPTIONS_LINK_RELEASE)
endif
# Files
HEADERS_MAYAQUA=src/Mayaqua/Cfg.h src/Mayaqua/cryptoki.h src/Mayaqua/Encrypt.h src/Mayaqua/FileIO.h src/Mayaqua/intelaes/iaesni.h src/Mayaqua/Internat.h src/Mayaqua/Kernel.h src/Mayaqua/Mayaqua.h src/Mayaqua/MayaType.h src/Mayaqua/Memory.h src/Mayaqua/Microsoft.h src/Mayaqua/Network.h src/Mayaqua/Object.h src/Mayaqua/OS.h src/Mayaqua/Pack.h src/Mayaqua/pkcs11.h src/Mayaqua/pkcs11f.h src/Mayaqua/pkcs11t.h src/Mayaqua/Secure.h src/Mayaqua/Str.h src/Mayaqua/Table.h src/Mayaqua/TcpIp.h src/Mayaqua/Tick64.h src/Mayaqua/Tracking.h src/Mayaqua/TunTap.h src/Mayaqua/Unix.h src/Mayaqua/Win32.h src/Mayaqua/zlib/zconf.h src/Mayaqua/zlib/zlib.h
HEADERS_CEDAR=src/Cedar/Account.h src/Cedar/Admin.h src/Cedar/AzureClient.h src/Cedar/AzureServer.h src/Cedar/Bridge.h src/Cedar/BridgeUnix.h src/Cedar/BridgeWin32.h src/Cedar/Cedar.h src/Cedar/CedarPch.h src/Cedar/CedarType.h src/Cedar/Client.h src/Cedar/CM.h src/Cedar/CMInner.h src/Cedar/Command.h src/Cedar/Connection.h src/Cedar/Console.h src/Cedar/Database.h src/Cedar/DDNS.h src/Cedar/EM.h src/Cedar/EMInner.h src/Cedar/EtherLog.h src/Cedar/Hub.h src/Cedar/Interop_OpenVPN.h src/Cedar/Interop_SSTP.h src/Cedar/IPsec.h src/Cedar/IPsec_EtherIP.h src/Cedar/IPsec_IKE.h src/Cedar/IPsec_IkePacket.h src/Cedar/IPsec_IPC.h src/Cedar/IPsec_L2TP.h src/Cedar/IPsec_PPP.h src/Cedar/IPsec_Win7.h src/Cedar/IPsec_Win7Inner.h src/Cedar/Layer3.h src/Cedar/Link.h src/Cedar/Listener.h src/Cedar/Logging.h src/Cedar/Nat.h src/Cedar/NativeStack.h src/Cedar/netcfgn.h src/Cedar/netcfgx.h src/Cedar/NM.h src/Cedar/NMInner.h src/Cedar/NullLan.h src/Cedar/Protocol.h src/Cedar/Radius.h src/Cedar/Remote.h src/Cedar/Sam.h src/Cedar/SecureInfo.h src/Cedar/SecureNAT.h src/Cedar/SeLowUser.h src/Cedar/Server.h src/Cedar/Session.h src/Cedar/SM.h src/Cedar/SMInner.h src/Cedar/SW.h src/Cedar/SWInner.h src/Cedar/UdpAccel.h src/Cedar/UT.h src/Cedar/VG.h src/Cedar/Virtual.h src/Cedar/VLan.h src/Cedar/VLanUnix.h src/Cedar/VLanWin32.h src/Cedar/WaterMark.h src/Cedar/WebUI.h src/Cedar/Win32Com.h src/Cedar/winpcap/bittypes.h src/Cedar/winpcap/bucket_lookup.h src/Cedar/winpcap/count_packets.h src/Cedar/winpcap/Devioctl.h src/Cedar/winpcap/Gnuc.h src/Cedar/winpcap/ip6_misc.h src/Cedar/winpcap/memory_t.h src/Cedar/winpcap/normal_lookup.h src/Cedar/winpcap/Ntddndis.h src/Cedar/winpcap/Ntddpack.h src/Cedar/winpcap/Packet32.h src/Cedar/winpcap/pcap.h src/Cedar/winpcap/pcap-bpf.h src/Cedar/winpcap/pcap-int.h src/Cedar/winpcap/pcap-stdinc.h src/Cedar/winpcap/pthread.h src/Cedar/winpcap/remote-ext.h src/Cedar/winpcap/sched.h src/Cedar/winpcap/semaphore.h src/Cedar/winpcap/tcp_session.h src/Cedar/winpcap/time_calls.h src/Cedar/winpcap/tme.h src/Cedar/winpcap/Win32-Extensions.h src/Cedar/WinUi.h src/Cedar/Wpc.h
OBJECTS_MAYAQUA=tmp/objs/Mayaqua/Cfg.o tmp/objs/Mayaqua/Encrypt.o tmp/objs/Mayaqua/FileIO.o tmp/objs/Mayaqua/Internat.o tmp/objs/Mayaqua/Kernel.o tmp/objs/Mayaqua/Mayaqua.o tmp/objs/Mayaqua/Memory.o tmp/objs/Mayaqua/Microsoft.o tmp/objs/Mayaqua/Network.o tmp/objs/Mayaqua/Object.o tmp/objs/Mayaqua/OS.o tmp/objs/Mayaqua/Pack.o tmp/objs/Mayaqua/Secure.o tmp/objs/Mayaqua/Str.o tmp/objs/Mayaqua/Table.o tmp/objs/Mayaqua/TcpIp.o tmp/objs/Mayaqua/Tick64.o tmp/objs/Mayaqua/Tracking.o tmp/objs/Mayaqua/Unix.o tmp/objs/Mayaqua/Win32.o
OBJECTS_CEDAR=tmp/objs/Cedar/Account.o tmp/objs/Cedar/Admin.o tmp/objs/Cedar/AzureClient.o tmp/objs/Cedar/AzureServer.o tmp/objs/Cedar/Bridge.o tmp/objs/Cedar/BridgeUnix.o tmp/objs/Cedar/BridgeWin32.o tmp/objs/Cedar/Cedar.o tmp/objs/Cedar/CedarPch.o tmp/objs/Cedar/Client.o tmp/objs/Cedar/CM.o tmp/objs/Cedar/Command.o tmp/objs/Cedar/Connection.o tmp/objs/Cedar/Console.o tmp/objs/Cedar/Database.o tmp/objs/Cedar/DDNS.o tmp/objs/Cedar/EM.o tmp/objs/Cedar/EtherLog.o tmp/objs/Cedar/Hub.o tmp/objs/Cedar/Interop_OpenVPN.o tmp/objs/Cedar/Interop_SSTP.o tmp/objs/Cedar/IPsec.o tmp/objs/Cedar/IPsec_EtherIP.o tmp/objs/Cedar/IPsec_IKE.o tmp/objs/Cedar/IPsec_IkePacket.o tmp/objs/Cedar/IPsec_IPC.o tmp/objs/Cedar/IPsec_L2TP.o tmp/objs/Cedar/IPsec_PPP.o tmp/objs/Cedar/IPsec_Win7.o tmp/objs/Cedar/Layer3.o tmp/objs/Cedar/Link.o tmp/objs/Cedar/Listener.o tmp/objs/Cedar/Logging.o tmp/objs/Cedar/Nat.o tmp/objs/Cedar/NativeStack.o tmp/objs/Cedar/NM.o tmp/objs/Cedar/NullLan.o tmp/objs/Cedar/Protocol.o tmp/objs/Cedar/Radius.o tmp/objs/Cedar/Remote.o tmp/objs/Cedar/Sam.o tmp/objs/Cedar/SecureInfo.o tmp/objs/Cedar/SecureNAT.o tmp/objs/Cedar/SeLowUser.o tmp/objs/Cedar/Server.o tmp/objs/Cedar/Session.o tmp/objs/Cedar/SM.o tmp/objs/Cedar/SW.o tmp/objs/Cedar/UdpAccel.o tmp/objs/Cedar/UT.o tmp/objs/Cedar/VG.o tmp/objs/Cedar/Virtual.o tmp/objs/Cedar/VLan.o tmp/objs/Cedar/VLanUnix.o tmp/objs/Cedar/VLanWin32.o tmp/objs/Cedar/WaterMark.o tmp/objs/Cedar/WebUI.o tmp/objs/Cedar/WinUi.o tmp/objs/Cedar/Wpc.o
HAMCORE_FILES=src/bin/hamcore/authors.txt src/bin/hamcore/backup_dir_readme.txt src/bin/hamcore/empty.config src/bin/hamcore/empty_sevpnclient.config src/bin/hamcore/eula.txt src/bin/hamcore/install_src.dat src/bin/hamcore/lang.config src/bin/hamcore/languages.txt src/bin/hamcore/legal.txt src/bin/hamcore/openvpn_readme.pdf src/bin/hamcore/openvpn_readme.txt src/bin/hamcore/openvpn_sample.ovpn src/bin/hamcore/root_certs.dat src/bin/hamcore/SOURCES_OF_BINARY_FILES.TXT src/bin/hamcore/strtable_cn.stb src/bin/hamcore/strtable_en.stb src/bin/hamcore/strtable_ja.stb src/bin/hamcore/vpnweb_sample_cn.htm src/bin/hamcore/vpnweb_sample_en.htm src/bin/hamcore/vpnweb_sample_ja.htm src/bin/hamcore/warning_cn.txt src/bin/hamcore/warning_en.txt src/bin/hamcore/warning_ja.txt src/bin/hamcore/webui/cryptcom.cgi src/bin/hamcore/webui/edituser.cgi src/bin/hamcore/webui/error.cgi src/bin/hamcore/webui/hub.cgi src/bin/hamcore/webui/license.cgi src/bin/hamcore/webui/listener.cgi src/bin/hamcore/webui/localbridge.cgi src/bin/hamcore/webui/login.cgi src/bin/hamcore/webui/newhub.cgi src/bin/hamcore/webui/redirect.cgi src/bin/hamcore/webui/securenat.cgi src/bin/hamcore/webui/server.cgi src/bin/hamcore/webui/session.cgi src/bin/hamcore/webui/user.cgi src/bin/hamcore/webui/webui.css
# Build Action
default: build
build: $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR) bin/vpnserver/vpnserver bin/vpnclient/vpnclient bin/vpnbridge/vpnbridge bin/vpncmd/vpncmd
# Mayaqua Kernel Code
tmp/objs/Mayaqua/Cfg.o: src/Mayaqua/Cfg.c $(HEADERS_MAYAQUA)
@mkdir -p tmp/
@mkdir -p tmp/objs/
@mkdir -p tmp/objs/Mayaqua/
@mkdir -p tmp/objs/Cedar/
@mkdir -p tmp/as/
@mkdir -p bin/
@mkdir -p bin/vpnserver/
@mkdir -p bin/vpnclient/
@mkdir -p bin/vpnbridge/
@mkdir -p bin/vpncmd/
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/Cfg.c -o tmp/objs/Mayaqua/Cfg.o
tmp/objs/Mayaqua/Encrypt.o: src/Mayaqua/Encrypt.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/Encrypt.c -o tmp/objs/Mayaqua/Encrypt.o
tmp/objs/Mayaqua/FileIO.o: src/Mayaqua/FileIO.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/FileIO.c -o tmp/objs/Mayaqua/FileIO.o
tmp/objs/Mayaqua/Internat.o: src/Mayaqua/Internat.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/Internat.c -o tmp/objs/Mayaqua/Internat.o
tmp/objs/Mayaqua/Kernel.o: src/Mayaqua/Kernel.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/Kernel.c -o tmp/objs/Mayaqua/Kernel.o
tmp/objs/Mayaqua/Mayaqua.o: src/Mayaqua/Mayaqua.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/Mayaqua.c -o tmp/objs/Mayaqua/Mayaqua.o
tmp/objs/Mayaqua/Memory.o: src/Mayaqua/Memory.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/Memory.c -o tmp/objs/Mayaqua/Memory.o
tmp/objs/Mayaqua/Microsoft.o: src/Mayaqua/Microsoft.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/Microsoft.c -o tmp/objs/Mayaqua/Microsoft.o
tmp/objs/Mayaqua/Network.o: src/Mayaqua/Network.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/Network.c -o tmp/objs/Mayaqua/Network.o
tmp/objs/Mayaqua/Object.o: src/Mayaqua/Object.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/Object.c -o tmp/objs/Mayaqua/Object.o
tmp/objs/Mayaqua/OS.o: src/Mayaqua/OS.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/OS.c -o tmp/objs/Mayaqua/OS.o
tmp/objs/Mayaqua/Pack.o: src/Mayaqua/Pack.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/Pack.c -o tmp/objs/Mayaqua/Pack.o
tmp/objs/Mayaqua/Secure.o: src/Mayaqua/Secure.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/Secure.c -o tmp/objs/Mayaqua/Secure.o
tmp/objs/Mayaqua/Str.o: src/Mayaqua/Str.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/Str.c -o tmp/objs/Mayaqua/Str.o
tmp/objs/Mayaqua/Table.o: src/Mayaqua/Table.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/Table.c -o tmp/objs/Mayaqua/Table.o
tmp/objs/Mayaqua/TcpIp.o: src/Mayaqua/TcpIp.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/TcpIp.c -o tmp/objs/Mayaqua/TcpIp.o
tmp/objs/Mayaqua/Tick64.o: src/Mayaqua/Tick64.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/Tick64.c -o tmp/objs/Mayaqua/Tick64.o
tmp/objs/Mayaqua/Tracking.o: src/Mayaqua/Tracking.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/Tracking.c -o tmp/objs/Mayaqua/Tracking.o
tmp/objs/Mayaqua/Unix.o: src/Mayaqua/Unix.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/Unix.c -o tmp/objs/Mayaqua/Unix.o
tmp/objs/Mayaqua/Win32.o: src/Mayaqua/Win32.c $(HEADERS_MAYAQUA)
$(CC) $(OPTIONS_COMPILE) -c src/Mayaqua/Win32.c -o tmp/objs/Mayaqua/Win32.o
# Cedar Communication Module Code
tmp/objs/Cedar/Account.o: src/Cedar/Account.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Account.c -o tmp/objs/Cedar/Account.o
tmp/objs/Cedar/Admin.o: src/Cedar/Admin.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Admin.c -o tmp/objs/Cedar/Admin.o
tmp/objs/Cedar/AzureClient.o: src/Cedar/AzureClient.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/AzureClient.c -o tmp/objs/Cedar/AzureClient.o
tmp/objs/Cedar/AzureServer.o: src/Cedar/AzureServer.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/AzureServer.c -o tmp/objs/Cedar/AzureServer.o
tmp/objs/Cedar/Bridge.o: src/Cedar/Bridge.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR) src/Cedar/BridgeUnix.c
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Bridge.c -o tmp/objs/Cedar/Bridge.o
tmp/objs/Cedar/BridgeUnix.o: src/Cedar/BridgeUnix.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/BridgeUnix.c -o tmp/objs/Cedar/BridgeUnix.o
tmp/objs/Cedar/BridgeWin32.o: src/Cedar/BridgeWin32.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/BridgeWin32.c -o tmp/objs/Cedar/BridgeWin32.o
tmp/objs/Cedar/Cedar.o: src/Cedar/Cedar.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Cedar.c -o tmp/objs/Cedar/Cedar.o
tmp/objs/Cedar/CedarPch.o: src/Cedar/CedarPch.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/CedarPch.c -o tmp/objs/Cedar/CedarPch.o
tmp/objs/Cedar/Client.o: src/Cedar/Client.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Client.c -o tmp/objs/Cedar/Client.o
tmp/objs/Cedar/CM.o: src/Cedar/CM.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/CM.c -o tmp/objs/Cedar/CM.o
tmp/objs/Cedar/Command.o: src/Cedar/Command.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Command.c -o tmp/objs/Cedar/Command.o
tmp/objs/Cedar/Connection.o: src/Cedar/Connection.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Connection.c -o tmp/objs/Cedar/Connection.o
tmp/objs/Cedar/Console.o: src/Cedar/Console.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Console.c -o tmp/objs/Cedar/Console.o
tmp/objs/Cedar/Database.o: src/Cedar/Database.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Database.c -o tmp/objs/Cedar/Database.o
tmp/objs/Cedar/DDNS.o: src/Cedar/DDNS.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/DDNS.c -o tmp/objs/Cedar/DDNS.o
tmp/objs/Cedar/EM.o: src/Cedar/EM.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/EM.c -o tmp/objs/Cedar/EM.o
tmp/objs/Cedar/EtherLog.o: src/Cedar/EtherLog.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/EtherLog.c -o tmp/objs/Cedar/EtherLog.o
tmp/objs/Cedar/Hub.o: src/Cedar/Hub.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Hub.c -o tmp/objs/Cedar/Hub.o
tmp/objs/Cedar/Interop_OpenVPN.o: src/Cedar/Interop_OpenVPN.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Interop_OpenVPN.c -o tmp/objs/Cedar/Interop_OpenVPN.o
tmp/objs/Cedar/Interop_SSTP.o: src/Cedar/Interop_SSTP.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Interop_SSTP.c -o tmp/objs/Cedar/Interop_SSTP.o
tmp/objs/Cedar/IPsec.o: src/Cedar/IPsec.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/IPsec.c -o tmp/objs/Cedar/IPsec.o
tmp/objs/Cedar/IPsec_EtherIP.o: src/Cedar/IPsec_EtherIP.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/IPsec_EtherIP.c -o tmp/objs/Cedar/IPsec_EtherIP.o
tmp/objs/Cedar/IPsec_IKE.o: src/Cedar/IPsec_IKE.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/IPsec_IKE.c -o tmp/objs/Cedar/IPsec_IKE.o
tmp/objs/Cedar/IPsec_IkePacket.o: src/Cedar/IPsec_IkePacket.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/IPsec_IkePacket.c -o tmp/objs/Cedar/IPsec_IkePacket.o
tmp/objs/Cedar/IPsec_IPC.o: src/Cedar/IPsec_IPC.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/IPsec_IPC.c -o tmp/objs/Cedar/IPsec_IPC.o
tmp/objs/Cedar/IPsec_L2TP.o: src/Cedar/IPsec_L2TP.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/IPsec_L2TP.c -o tmp/objs/Cedar/IPsec_L2TP.o
tmp/objs/Cedar/IPsec_PPP.o: src/Cedar/IPsec_PPP.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/IPsec_PPP.c -o tmp/objs/Cedar/IPsec_PPP.o
tmp/objs/Cedar/IPsec_Win7.o: src/Cedar/IPsec_Win7.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/IPsec_Win7.c -o tmp/objs/Cedar/IPsec_Win7.o
tmp/objs/Cedar/Layer3.o: src/Cedar/Layer3.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Layer3.c -o tmp/objs/Cedar/Layer3.o
tmp/objs/Cedar/Link.o: src/Cedar/Link.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Link.c -o tmp/objs/Cedar/Link.o
tmp/objs/Cedar/Listener.o: src/Cedar/Listener.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Listener.c -o tmp/objs/Cedar/Listener.o
tmp/objs/Cedar/Logging.o: src/Cedar/Logging.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Logging.c -o tmp/objs/Cedar/Logging.o
tmp/objs/Cedar/Nat.o: src/Cedar/Nat.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Nat.c -o tmp/objs/Cedar/Nat.o
tmp/objs/Cedar/NativeStack.o: src/Cedar/NativeStack.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/NativeStack.c -o tmp/objs/Cedar/NativeStack.o
tmp/objs/Cedar/NM.o: src/Cedar/NM.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/NM.c -o tmp/objs/Cedar/NM.o
tmp/objs/Cedar/NullLan.o: src/Cedar/NullLan.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/NullLan.c -o tmp/objs/Cedar/NullLan.o
tmp/objs/Cedar/Protocol.o: src/Cedar/Protocol.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Protocol.c -o tmp/objs/Cedar/Protocol.o
tmp/objs/Cedar/Radius.o: src/Cedar/Radius.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Radius.c -o tmp/objs/Cedar/Radius.o
tmp/objs/Cedar/Remote.o: src/Cedar/Remote.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Remote.c -o tmp/objs/Cedar/Remote.o
tmp/objs/Cedar/Sam.o: src/Cedar/Sam.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Sam.c -o tmp/objs/Cedar/Sam.o
tmp/objs/Cedar/SecureInfo.o: src/Cedar/SecureInfo.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/SecureInfo.c -o tmp/objs/Cedar/SecureInfo.o
tmp/objs/Cedar/SecureNAT.o: src/Cedar/SecureNAT.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/SecureNAT.c -o tmp/objs/Cedar/SecureNAT.o
tmp/objs/Cedar/SeLowUser.o: src/Cedar/SeLowUser.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/SeLowUser.c -o tmp/objs/Cedar/SeLowUser.o
tmp/objs/Cedar/Server.o: src/Cedar/Server.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Server.c -o tmp/objs/Cedar/Server.o
tmp/objs/Cedar/Session.o: src/Cedar/Session.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Session.c -o tmp/objs/Cedar/Session.o
tmp/objs/Cedar/SM.o: src/Cedar/SM.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/SM.c -o tmp/objs/Cedar/SM.o
tmp/objs/Cedar/SW.o: src/Cedar/SW.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/SW.c -o tmp/objs/Cedar/SW.o
tmp/objs/Cedar/UdpAccel.o: src/Cedar/UdpAccel.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/UdpAccel.c -o tmp/objs/Cedar/UdpAccel.o
tmp/objs/Cedar/UT.o: src/Cedar/UT.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/UT.c -o tmp/objs/Cedar/UT.o
tmp/objs/Cedar/VG.o: src/Cedar/VG.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/VG.c -o tmp/objs/Cedar/VG.o
tmp/objs/Cedar/Virtual.o: src/Cedar/Virtual.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Virtual.c -o tmp/objs/Cedar/Virtual.o
tmp/objs/Cedar/VLan.o: src/Cedar/VLan.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/VLan.c -o tmp/objs/Cedar/VLan.o
tmp/objs/Cedar/VLanUnix.o: src/Cedar/VLanUnix.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/VLanUnix.c -o tmp/objs/Cedar/VLanUnix.o
tmp/objs/Cedar/VLanWin32.o: src/Cedar/VLanWin32.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/VLanWin32.c -o tmp/objs/Cedar/VLanWin32.o
tmp/objs/Cedar/WaterMark.o: src/Cedar/WaterMark.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/WaterMark.c -o tmp/objs/Cedar/WaterMark.o
tmp/objs/Cedar/WebUI.o: src/Cedar/WebUI.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/WebUI.c -o tmp/objs/Cedar/WebUI.o
tmp/objs/Cedar/WinUi.o: src/Cedar/WinUi.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/WinUi.c -o tmp/objs/Cedar/WinUi.o
tmp/objs/Cedar/Wpc.o: src/Cedar/Wpc.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/Cedar/Wpc.c -o tmp/objs/Cedar/Wpc.o
# hamcore.se2 Archive File
src/bin/BuiltHamcoreFiles/unix/hamcore.se2: tmp/hamcorebuilder $(HAMCORE_FILES)
@mkdir -p src/bin/BuiltHamcoreFiles/unix/
tmp/hamcorebuilder src/bin/hamcore/ src/bin/BuiltHamcoreFiles/unix/hamcore.se2
# hamcorebuilder Utility
tmp/hamcorebuilder: src/hamcorebuilder/hamcorebuilder.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR) $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR)
@mkdir -p tmp/
$(CC) $(OPTIONS_COMPILE) $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR) src/hamcorebuilder/hamcorebuilder.c $(OPTIONS_LINK) -o tmp/hamcorebuilder
# vpnserver
bin/vpnserver/vpnserver: tmp/as/vpnserver.a bin/vpnserver/hamcore.se2 $(HEADERS_MAYAQUA) $(HEADERS_CEDAR) $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR)
$(CC) tmp/as/vpnserver.a $(OPTIONS_LINK) -o bin/vpnserver/vpnserver
tmp/as/vpnserver.a: tmp/objs/vpnserver.o $(HEADERS_MAYAQUA) $(HEADERS_CEDAR) $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR)
rm -f tmp/as/vpnserver.a
ar r tmp/as/vpnserver.a $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR) tmp/objs/vpnserver.o
ranlib tmp/as/vpnserver.a
bin/vpnserver/hamcore.se2: src/bin/BuiltHamcoreFiles/unix/hamcore.se2
cp src/bin/BuiltHamcoreFiles/unix/hamcore.se2 bin/vpnserver/hamcore.se2
tmp/objs/vpnserver.o: src/vpnserver/vpnserver.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR) $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/vpnserver/vpnserver.c -o tmp/objs/vpnserver.o
# vpnclient
bin/vpnclient/vpnclient: tmp/as/vpnclient.a bin/vpnclient/hamcore.se2 $(HEADERS_MAYAQUA) $(HEADERS_CEDAR) $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR)
$(CC) tmp/as/vpnclient.a $(OPTIONS_LINK) -o bin/vpnclient/vpnclient
tmp/as/vpnclient.a: tmp/objs/vpnclient.o $(HEADERS_MAYAQUA) $(HEADERS_CEDAR) $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR)
rm -f tmp/as/vpnclient.a
ar r tmp/as/vpnclient.a $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR) tmp/objs/vpnclient.o
ranlib tmp/as/vpnclient.a
bin/vpnclient/hamcore.se2: src/bin/BuiltHamcoreFiles/unix/hamcore.se2
cp src/bin/BuiltHamcoreFiles/unix/hamcore.se2 bin/vpnclient/hamcore.se2
tmp/objs/vpnclient.o: src/vpnclient/vpncsvc.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR) $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/vpnclient/vpncsvc.c -o tmp/objs/vpnclient.o
# vpnbridge
bin/vpnbridge/vpnbridge: tmp/as/vpnbridge.a bin/vpnbridge/hamcore.se2 $(HEADERS_MAYAQUA) $(HEADERS_CEDAR) $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR)
$(CC) tmp/as/vpnbridge.a $(OPTIONS_LINK) -o bin/vpnbridge/vpnbridge
tmp/as/vpnbridge.a: tmp/objs/vpnbridge.o $(HEADERS_MAYAQUA) $(HEADERS_CEDAR) $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR)
rm -f tmp/as/vpnbridge.a
ar r tmp/as/vpnbridge.a $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR) tmp/objs/vpnbridge.o
ranlib tmp/as/vpnbridge.a
bin/vpnbridge/hamcore.se2: src/bin/BuiltHamcoreFiles/unix/hamcore.se2
cp src/bin/BuiltHamcoreFiles/unix/hamcore.se2 bin/vpnbridge/hamcore.se2
tmp/objs/vpnbridge.o: src/vpnbridge/vpnbridge.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR) $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/vpnbridge/vpnbridge.c -o tmp/objs/vpnbridge.o
# vpncmd
bin/vpncmd/vpncmd: tmp/as/vpncmd.a bin/vpncmd/hamcore.se2 $(HEADERS_MAYAQUA) $(HEADERS_CEDAR) $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR)
$(CC) tmp/as/vpncmd.a $(OPTIONS_LINK) -o bin/vpncmd/vpncmd
tmp/as/vpncmd.a: tmp/objs/vpncmd.o $(HEADERS_MAYAQUA) $(HEADERS_CEDAR) $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR)
rm -f tmp/as/vpncmd.a
ar r tmp/as/vpncmd.a $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR) tmp/objs/vpncmd.o
ranlib tmp/as/vpncmd.a
bin/vpncmd/hamcore.se2: src/bin/BuiltHamcoreFiles/unix/hamcore.se2
cp src/bin/BuiltHamcoreFiles/unix/hamcore.se2 bin/vpncmd/hamcore.se2
tmp/objs/vpncmd.o: src/vpncmd/vpncmd.c $(HEADERS_MAYAQUA) $(HEADERS_CEDAR) $(OBJECTS_MAYAQUA) $(OBJECTS_CEDAR)
$(CC) $(OPTIONS_COMPILE) -c src/vpncmd/vpncmd.c -o tmp/objs/vpncmd.o
# Install
install: $(INSTALL_BINDIR)vpnserver $(INSTALL_BINDIR)vpnbridge $(INSTALL_BINDIR)vpnclient $(INSTALL_BINDIR)vpncmd
@echo
@echo "--------------------------------------------------------------------"
@echo "Installation completed successfully."
@echo
@echo "Execute 'vpnserver start' to run the SoftEther VPN Server background service."
@echo "Execute 'vpnbridge start' to run the SoftEther VPN Bridge background service."
@echo "Execute 'vpnclient start' to run the SoftEther VPN Client background service."
@echo "Execute 'vpncmd' to run SoftEther VPN Command-Line Utility to configure VPN Server, VPN Bridge or VPN Client."
@echo "--------------------------------------------------------------------"
@echo
$(INSTALL_BINDIR)vpnserver: bin/vpnserver/hamcore.se2 bin/vpnserver/vpnserver
install -d $(INSTALL_VPNSERVER_DIR)
install -m 600 bin/vpnserver/hamcore.se2 $(INSTALL_VPNSERVER_DIR)hamcore.se2
install -m 755 bin/vpnserver/vpnserver $(INSTALL_VPNSERVER_DIR)vpnserver
# echo "#!/bin/sh" > $(INSTALL_BINDIR)vpnserver
# echo $(INSTALL_VPNSERVER_DIR)vpnserver '"$$@"' >> $(INSTALL_BINDIR)vpnserver
# echo 'exit $$?' >> $(INSTALL_BINDIR)vpnserver
# chmod 755 $(INSTALL_BINDIR)vpnserver
$(INSTALL_BINDIR)vpnbridge: bin/vpnbridge/hamcore.se2 bin/vpnbridge/vpnbridge
install -d $(INSTALL_VPNBRIDGE_DIR)
install -m 600 bin/vpnbridge/hamcore.se2 $(INSTALL_VPNBRIDGE_DIR)hamcore.se2
install -m 755 bin/vpnbridge/vpnbridge $(INSTALL_VPNBRIDGE_DIR)vpnbridge
# echo "#!/bin/sh" > $(INSTALL_BINDIR)vpnbridge
# echo $(INSTALL_VPNBRIDGE_DIR)vpnbridge '"$$@"' >> $(INSTALL_BINDIR)vpnbridge
# echo 'exit $$?' >> $(INSTALL_BINDIR)vpnbridge
# chmod 755 $(INSTALL_BINDIR)vpnbridge
$(INSTALL_BINDIR)vpnclient: bin/vpnclient/hamcore.se2 bin/vpnclient/vpnclient
install -d $(INSTALL_VPNCLIENT_DIR)
install -m 600 bin/vpnclient/hamcore.se2 $(INSTALL_VPNCLIENT_DIR)hamcore.se2
install -m 755 bin/vpnclient/vpnclient $(INSTALL_VPNCLIENT_DIR)vpnclient
# echo "#!/bin/sh" > $(INSTALL_BINDIR)vpnclient
# echo $(INSTALL_VPNCLIENT_DIR)vpnclient '"$$@"' >> $(INSTALL_BINDIR)vpnclient
# echo 'exit $$?' >> $(INSTALL_BINDIR)vpnclient
# chmod 755 $(INSTALL_BINDIR)vpnclient
$(INSTALL_BINDIR)vpncmd: bin/vpncmd/hamcore.se2 bin/vpncmd/vpncmd
install -d $(INSTALL_VPNCMD_DIR)
install -m 600 bin/vpncmd/hamcore.se2 $(INSTALL_VPNCMD_DIR)hamcore.se2
install -m 755 bin/vpncmd/vpncmd $(INSTALL_VPNCMD_DIR)vpncmd
# echo "#!/bin/sh" > $(INSTALL_BINDIR)vpncmd
# echo $(INSTALL_VPNCMD_DIR)vpncmd '"$$@"' >> $(INSTALL_BINDIR)vpncmd
# echo 'exit $$?' >> $(INSTALL_BINDIR)vpncmd
# chmod 755 $(INSTALL_BINDIR)vpncmd
# Clean
clean:
-rm -f $(OBJECTS_MAYAQUA)
-rm -f $(OBJECTS_CEDAR)
-rm -f tmp/objs/vpnserver.o
-rm -f tmp/as/vpnserver.a
-rm -f bin/vpnserver/vpnserver
-rm -f bin/vpnserver/hamcore.se2
-rm -f tmp/objs/vpnclient.o
-rm -f tmp/as/vpnclient.a
-rm -f bin/vpnclient/vpnclient
-rm -f bin/vpnclient/hamcore.se2
-rm -f tmp/objs/vpnbridge.o
-rm -f tmp/as/vpnbridge.a
-rm -f bin/vpnbridge/vpnbridge
-rm -f bin/vpnbridge/hamcore.se2
-rm -f tmp/objs/vpncmd.o
-rm -f tmp/as/vpncmd.a
-rm -f bin/vpncmd/vpncmd
-rm -f bin/vpncmd/hamcore.se2
-rm -f tmp/hamcorebuilder
-rm -f src/bin/BuiltHamcoreFiles/unix/hamcore.se2
# Help Strings
help:
@echo "make [DEBUG=YES]"
@echo "make install"
@echo "make clean"

View File

@ -1,3 +0,0 @@
#!/bin/sh
/usr/vpnbridge/vpnbridge "$@"
exit $?

View File

@ -1,3 +0,0 @@
#!/bin/sh
/usr/vpnclient/vpnclient "$@"
exit $?

View File

@ -1,3 +0,0 @@
#!/bin/sh
/usr/vpncmd/vpncmd "$@"
exit $?

View File

@ -1,3 +0,0 @@
#!/bin/sh
/usr/vpnserver/vpnserver "$@"
exit $?

View File

@ -1,102 +0,0 @@
%define majorversion 4
%define minorversion 19
%define buildversion 9582
%define dateversion 2015.10.06
%define buildrelease beta
Name: softethervpn
Version: %{majorversion}.%{minorversion}.%{buildversion}
Release: 1%{?dist}
Summary: An Open-Source Free Cross-platform Multi-protocol VPN Program
Group: Applications/Internet
License: GPLv2
URL: http://www.softether.org/
Source0: http://www.softether-download.com/files/softether/v%{majorversion}.%{minorversion}-%{buildversion}-%{buildrelease}-%{dateversion}-tree/Source_Code/softether-src-v%{majorversion}.%{minorversion}-%{buildversion}-%{buildrelease}.tar.gz
BuildRequires: ncurses-devel
BuildRequires: openssl-devel
BuildRequires: readline-devel
Requires(post): chkconfig
Requires(postun): initscripts
Requires(preun): chkconfig
Requires(preun): initscripts
%description
SoftEther VPN is one of the world's most powerful and easy-to-use multi-protocol VPN software. It runs on Windows, Linux, Mac, FreeBSD, and Solaris.
%prep
%setup -q -n v%{majorversion}.%{minorversion}-%{buildversion}
%build
%ifarch i386 i686
cp $RPM_SOURCE_DIR/linux_32bit.mak Makefile
%else
cp $RPM_SOURCE_DIR/linux_64bit.mak Makefile
%endif
make
%install
rm -rf $RPM_BUILD_ROOT
make install DESTDIR=$RPM_BUILD_ROOT
install -m 755 -d $RPM_BUILD_ROOT/usr/bin/
install -m 755 -d $RPM_BUILD_ROOT/etc/rc.d/init.d
install -m 755 $RPM_SOURCE_DIR/scripts/vpnserver $RPM_BUILD_ROOT/usr/bin/vpnserver
install -m 755 $RPM_SOURCE_DIR/scripts/vpnbridge $RPM_BUILD_ROOT/usr/bin/vpnbridge
install -m 755 $RPM_SOURCE_DIR/scripts/vpnclient $RPM_BUILD_ROOT/usr/bin/vpnclient
install -m 755 $RPM_SOURCE_DIR/scripts/vpncmd $RPM_BUILD_ROOT/usr/bin/vpncmd
install -m 755 $RPM_SOURCE_DIR/init.d/vpnserver $RPM_BUILD_ROOT/etc/rc.d/init.d/vpnserver
%clean
rm -rf $RPM_BUILD_ROOT
%files
%defattr(-,root,root,-)
%{_usr}/bin/vpnserver
%{_usr}/bin/vpnbridge
%{_usr}/bin/vpnclient
%{_usr}/bin/vpncmd
%{_usr}/vpnserver/hamcore.se2
%{_usr}/vpnserver/vpnserver
%{_usr}/vpnbridge/hamcore.se2
%{_usr}/vpnbridge/vpnbridge
%{_usr}/vpnclient/hamcore.se2
%{_usr}/vpnclient/vpnclient
%{_usr}/vpncmd/hamcore.se2
%{_usr}/vpncmd/vpncmd
%{_usr}/vpnserver/
%{_usr}/vpnbridge/
%{_usr}/vpnclient/
%{_usr}/vpncmd/
%{_initddir}/vpnserver
%doc AUTHORS.TXT BUILD_UNIX.TXT BUILD_WINDOWS.TXT ChangeLog ChangeLog.txt LICENSE LICENSE.TXT README README.TXT THIRD_PARTY.TXT WARNING.TXT
%post
/sbin/chkconfig --add vpnserver
#%postun
#if [ "$1" -ge "1" ]; then
# /sbin/service vpnserver condrestart >/dev/null 2>&1 || :
#fi
%preun
if [ $1 -eq 0 ]; then
/sbin/service vpnserver stop >/dev/null 2>&1
/sbin/chkconfig --del vpnserver
fi
%changelog
* Wed Sep 30 2015 Jeff Tang <mrjefftang@gmail.com> - 4.19.9582-1
- Update upstream to 4.19.9582-beta
* Wed Sep 30 2015 Jeff Tang <mrjefftang@gmail.com> - 4.19.9577-1
- Update upstream to 4.19.9577
* Wed Jan 29 2014 Dexter Ang <thepoch@gmail.com> - 4.04.9412-2
- Made initscript more Fedora/RH-like.
- initscript currently using killall. Need to fix this.
* Tue Jan 21 2014 Dexter Ang <thepoch@gmail.com>
- Initial release

1
compat
View File

@ -1 +0,0 @@
9

112
configure vendored
View File

@ -1,112 +0,0 @@
#!/bin/sh
echo '---------------------------------------------------------------------'
echo 'SoftEther VPN for Unix'
echo
echo 'Copyright (c) Daiyuu Nobori.'
echo 'Copyright (c) SoftEther VPN Project, University of Tsukuba, Japan.'
echo 'Copyright (c) SoftEther Corporation.'
echo 'Copyright (c) all contributors on SoftEther VPN project in GitHub.'
echo
echo 'License: The Apache License, Version 2.0'
echo
echo 'Read and understand README.TXT, LICENSE.TXT and WARNING.TXT before use.'
echo '---------------------------------------------------------------------'
echo
echo 'Welcome to the corner-cutting configure script !'
echo
OS=""
case "`uname -s`" in
Linux)
OS="linux"
;;
FreeBSD)
OS="freebsd"
;;
SunOS)
OS="solaris"
;;
Darwin)
OS="macos"
;;
OpenBSD)
OS="openbsd"
;;
*)
echo 'Select your operating system below:'
echo ' 1: Linux'
echo ' 2: FreeBSD'
echo ' 3: Solaris'
echo ' 4: Mac OS X'
echo ' 5: OpenBSD'
echo
echo -n 'Which is your operating system (1 - 5) ? : '
read TMP
echo
if test "$TMP" = "1"
then
OS="linux"
fi
if test "$TMP" = "2"
then
OS="freebsd"
fi
if test "$TMP" = "3"
then
OS="solaris"
fi
if test "$TMP" = "4"
then
OS="macos"
fi
if test "$TMP" = "5"
then
OS="openbsd"
fi
if test "$OS" = ""
then
echo "Wrong number."
exit 1
fi
;;
esac
CPU=""
case "`uname -m`" in
x86_64|amd64|aarch64|arm64|armv8*|mips64|ppc64|sparc64|alpha|ia64)
CPU=64bit
;;
i?86|x86pc|i86pc|armv4*|armv5*|armv6*|armv7*)
CPU=32bit
;;
*)
echo 'Select your CPU bits below:'
echo ' 1: 32-bit'
echo ' 2: 64-bit'
echo
echo -n 'Which is the type of your CPU (1 - 2) ? : '
read TMP
echo
if test "$TMP" = "1"
then
CPU="32bit"
fi
if test "$TMP" = "2"
then
CPU="64bit"
fi
if test "$CPU" = ""
then
echo "Wrong number."
exit 1
fi
;;
esac
cp src/makefiles/${OS}_${CPU}.mak Makefile
echo "The Makefile is generated. Run 'make' to build SoftEther VPN."

14
debian/README.TXT vendored
View File

@ -1,14 +0,0 @@
The contents of the "debian" directory were written
by Dmitry Orlov (https://github.com/mosquito) and has been contributed
to the SoftEther VPN Project main source-tree.
Note that SoftEther VPN Project has not tested this debian package.
Please try it at your own risk.
See also:
Add simple debian packaging #20
https://github.com/SoftEtherVPN/SoftEtherVPN/pull/20
February 5, 2004
Daiyuu Nobori
SoftEther VPN Project

View File

@ -1,3 +0,0 @@
#!/bin/sh
/opt/vpnbridge/vpnbridge "$@"
exit $?

View File

@ -1,3 +0,0 @@
#!/bin/sh
/opt/vpnclient/vpnclient "$@"
exit $?

3
debian/bin/vpncmd vendored
View File

@ -1,3 +0,0 @@
#!/bin/sh
/opt/vpncmd/vpncmd "$@"
exit $?

View File

@ -1,3 +0,0 @@
#!/bin/sh
/opt/vpnserver/vpnserver "$@"
exit $?

11
debian/changelog vendored
View File

@ -1,11 +0,0 @@
softether-vpn (0:4.29.9680-rtm) UNRELEASED; urgency=medium
* Bump
-- Mario Fetka <mario.fetka@gmail.com> Tue, 13 Mar 2018 17:30:04 +0100
softether-vpn (0:4.04.9412-rtm) unstable; urgency=low
* Testing debianization
-- Dmitry Orlov <me@mosquito.su> Tue, 4 Feb 2014 20:24:43 +0000

1
debian/compat vendored
View File

@ -1 +0,0 @@
9

80
debian/control vendored
View File

@ -1,80 +0,0 @@
Source: softether-vpn
Section: net
Priority: optional
Maintainer: Dmitry Orlov <me@mosquito.su>
Build-Depends: debhelper (>= 7.0.50~), libncurses-dev, linux-libc-dev, libssl-dev , libreadline-dev, build-essential, dh-exec, zlib1g-dev
Standards-Version: 3.9.1
Homepage: http://www.softether.org/
Package: softether-vpnbridge
Architecture: any
Depends: ${misc:Depends}, ${shlibs:Depends}, softether-vpncmd
Section: net
Description: VPN Bridge daemon
An Open-Source Free Cross-platform Multi-protocol VPN Program, as an academic project from University of Tsukuba.
SoftEther VPN ("SoftEther" means "Software Ethernet") is one of the world's most
powerful and easy-to-use multi-protocol VPN software.
It runs on Windows, Linux, Mac, FreeBSD and Solaris.
SoftEther VPN is open source. You can use SoftEther for any
personal or commercial use for free charge.
SoftEther VPN is an optimum alternative to
OpenVPN and Microsoft's VPN servers. SoftEther VPN
has a clone-function of OpenVPN Server.
You can integrate from OpenVPN to SoftEther VPN smoothly.
SoftEther VPN is faster than OpenVPN.
SoftEther VPN also supports Microsoft SSTP VPN for Windows Vista / 7 / 8.
Package: softether-vpnclient
Architecture: any
Depends: ${misc:Depends}, ${shlibs:Depends}, softether-vpncmd
Section: net
Description: VPN Client daemon
An Open-Source Free Cross-platform Multi-protocol VPN Program, as an academic project from University of Tsukuba.
SoftEther VPN ("SoftEther" means "Software Ethernet") is one of the world's most
powerful and easy-to-use multi-protocol VPN software.
It runs on Windows, Linux, Mac, FreeBSD and Solaris.
SoftEther VPN is open source. You can use SoftEther for any
personal or commercial use for free charge.
SoftEther VPN is an optimum alternative to
OpenVPN and Microsoft's VPN servers. SoftEther VPN
has a clone-function of OpenVPN Server.
You can integrate from OpenVPN to SoftEther VPN smoothly.
SoftEther VPN is faster than OpenVPN.
SoftEther VPN also supports Microsoft SSTP VPN for Windows Vista / 7 / 8.
Package: softether-vpncmd
Architecture: any
Depends: ${misc:Depends}, ${shlibs:Depends}
Section: net
Description: Command line utils
An Open-Source Free Cross-platform Multi-protocol VPN Program, as an academic project from University of Tsukuba.
SoftEther VPN ("SoftEther" means "Software Ethernet") is one of the world's most
powerful and easy-to-use multi-protocol VPN software.
It runs on Windows, Linux, Mac, FreeBSD and Solaris.
SoftEther VPN is open source. You can use SoftEther for any
personal or commercial use for free charge.
SoftEther VPN is an optimum alternative to
OpenVPN and Microsoft's VPN servers. SoftEther VPN
has a clone-function of OpenVPN Server.
You can integrate from OpenVPN to SoftEther VPN smoothly.
SoftEther VPN is faster than OpenVPN.
SoftEther VPN also supports Microsoft SSTP VPN for Windows Vista / 7 / 8.
Package: softether-vpnserver
Architecture: any
Depends: ${misc:Depends}, ${shlibs:Depends}, softether-vpncmd
Section: net
Description: VPN Server daemon
An Open-Source Free Cross-platform Multi-protocol VPN Program, as an academic project from University of Tsukuba.
SoftEther VPN ("SoftEther" means "Software Ethernet") is one of the world's most
powerful and easy-to-use multi-protocol VPN software.
It runs on Windows, Linux, Mac, FreeBSD and Solaris.
SoftEther VPN is open source. You can use SoftEther for any
personal or commercial use for free charge.
SoftEther VPN is an optimum alternative to
OpenVPN and Microsoft's VPN servers. SoftEther VPN
has a clone-function of OpenVPN Server.
You can integrate from OpenVPN to SoftEther VPN smoothly.
SoftEther VPN is faster than OpenVPN.
SoftEther VPN also supports Microsoft SSTP VPN for Windows Vista / 7 / 8.

View File

@ -1,68 +0,0 @@
#!/bin/bash
# use: ./debian/dch-generate.sh > ./debian/changelog
# desc: quick and dirty (emphasis on dirty) debian changelog generator for SoftEtherVPN
#
# Copyright (c) 2014 Sahal Ansari (github@sahal.info)
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# version 2 as published by the Free Software Foundation.
# warning: the following file has CRLF line endings (Windows)
# the location of the following file is relative to this script
cbuild="../src/CurrentBuild.txt"
# required for debian packaging
package="softether-vpn"
status="UNRELEASED"
# timezone in +hh:mm from UTC (+9 UTC)
tzone="+09:00"
# static changelog entry
entry="* See: http://www.softether.org/5-download/history"
# are you a debian maintainer?
if [ -z "$DEBFULLNAME" ]; then
DEBFULLNAME="John Q. Sample"
fi
if [ -z "$DEBEMAIL" ]; then
DEBEMAIL="tamade@example.org"
fi
# where am i located? in $DIR, of course!
DIR="$( cd "$( dirname "$0" )" && pwd )"
cd "$DIR"
# check if debian/changelog exists, check if $cbuild exists
if [ ! -e ./changelog ]; then
echo "Am I in debian/? I can't find changelog"
exit 1
fi
if [ ! -e "$cbuild" ]; then
echo "This doesn't look like the SoftEtherVPN source tree. I can't find ""$cbuild"
exit 1
fi
# version and date info from $cbuild are put into array ${cbuildarray[@]}
# build "${cbuildarray[0]}", major version "${cbuildarray[1]}",
# release type "${cbuildarray[2]}", and date "${cbuildarray[3]}"
while IFS=$'\r\n' read -r line_data; do
cbuildarray[i]="${line_data##*[A-Z]\ }"
((++i))
done < "$cbuild"
# "${cbuildarray[1]}" is converted from "406" to "4.06" using GNU awk
majorversion="$(echo "${cbuildarray[1]}" | awk '{sub(/[0-9]/,"&.",$0);print $0}')"
# "${cbuildarray[3]}" is split and the second half is converted from
# from "131655" to "13:16:55" using GNU awk then it's put back together
# (like humpty dumpty) and sent to GNU date for conversion to UTC
time="$(echo "${cbuildarray[3]#*_}" | awk '{gsub(/[0-9][0-9]/,"&:",$0);print $0}')"
date="$(date -R --date="$(echo "${cbuildarray[3]%_*}"" ""${time%?}""$tzone")")"
# print the new debian changelog
echo "$package"" (""$majorversion"".""${cbuildarray[0]}""-""${cbuildarray[2]}"") ""$status""; urgency=low"
echo
echo " ""$entry"
echo
echo " --"" ""$DEBFULLNAME"" <""$DEBEMAIL""> ""$date"
exit 0

19
debian/makefile.patch vendored
View File

@ -1,19 +0,0 @@
--- Makefile 2014-02-04 21:20:33.422762017 +0000
+++ Makefile.old 2014-02-04 21:20:10.298761727 +0000
@@ -32,11 +32,11 @@
OPTIONS_LINK_RELEASE=-O2 -fsigned-char -m64 -lm -ldl -lrt -lpthread -lssl -lcrypto -lreadline -lncurses -lz
-INSTALL_BINDIR=/usr/bin/
-INSTALL_VPNSERVER_DIR=/usr/vpnserver/
-INSTALL_VPNBRIDGE_DIR=/usr/vpnbridge/
-INSTALL_VPNCLIENT_DIR=/usr/vpnclient/
-INSTALL_VPNCMD_DIR=/usr/vpncmd/
+INSTALL_BINDIR=usr/bin/
+INSTALL_VPNSERVER_DIR=usr/vpnserver/
+INSTALL_VPNBRIDGE_DIR=usr/vpnbridge/
+INSTALL_VPNCLIENT_DIR=usr/vpnclient/
+INSTALL_VPNCMD_DIR=usr/vpncmd/
ifeq ($(DEBUG),YES)
OPTIONS_COMPILE=$(OPTIONS_COMPILE_DEBUG)

27
debian/rules vendored
View File

@ -1,27 +0,0 @@
#!/usr/bin/make -f
export DH_VERBOSE=1
CFLAGS := $(shell dpkg-buildflags --get CFLAGS)
LDFLAGS := $(shell dpkg-buildflags --get LDFLAGS)
%:
dh $@
override_dh_auto_configure: configure_config
override_dh_auto_clean:
rm -fr Makefile* usr bin tmp src/bin/BuiltHamcoreFiles
override_dh_auto_install:
patch -f < debian/makefile.patch
mkdir -p usr/bin
make install
configure_config:
if [ $(shell uname -m) = 'x86_64' ]; then echo -e "1\n2\n" | ./configure; fi
if [ $(shell uname -m) = 'i686' ]; then echo -e "1\n1\n" | ./configure; fi
if [ $(shell uname -m) = 'armv6l' ]; then echo -e "1\n1\n" | ./configure; fi
if [ $(shell uname -m) = 'armv5tel' ]; then echo -e "1\n1\n" | ./configure; fi
if [ $(shell uname -m) = 'aarch64' ]; then echo -e "1\n2\n" | ./configure; fi
if [ $(shell uname -m) = 'armv7l' ]; then echo -e "1\n1\n" | ./configure; fi

View File

@ -1,3 +0,0 @@
#! /usr/bin/dh-exec
debian/bin/vpnbridge usr/bin/
usr/vpnbridge opt/

View File

@ -1,3 +0,0 @@
#! /usr/bin/dh-exec
debian/bin/vpnclient usr/bin/
usr/vpnclient opt/

View File

@ -1,3 +0,0 @@
#! /usr/bin/dh-exec
debian/bin/vpncmd usr/bin/
usr/vpncmd opt/

View File

@ -1,83 +0,0 @@
#! /bin/sh
### BEGIN INIT INFO
# Provides: softether-vpnserver
# Required-Start: $network $remote_fs $syslog
# Required-Stop: $network $remote_fs $syslog
# Should-Start: network-manager
# Should-Stop: network-manager
# X-Start-Before: $x-display-manager gdm kdm xdm wdm ldm sdm nodm
# X-Interactive: true
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: SoftEther VPN service
### END INIT INFO
#
# Author: Dmitry Orlov <me@mosquito.su>
# From Debian skeleton (Tom deLombarde)
#
set -e
PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/usr/qmsys/bin
DAEMON=/usr/bin/vpnserver
NAME=vpnserver
DESC="SoftEtherVPN Server"
PIDFILE=/var/run/$NAME.pid
SCRIPTNAME=/etc/init.d/$NAME
# Gracefully exit if the package has been removed.
test -x $DAEMON || exit 0
# Read config file if it is present.
#if [ -r /etc/default/$NAME ]
#then
# . /etc/default/$NAME
#fi
case "$1" in
start)
echo -n "Starting $DESC: $NAME"
$DAEMON start
echo "."
;;
stop)
echo -n "Stopping $DESC: $NAME"
$DAEMON stop
echo "."
;;
#reload)
#
# If the daemon can reload its config files on the fly
# for example by sending it SIGHUP, do it here.
#
# If the daemon responds to changes in its config file
# directly anyway, make this a do-nothing entry.
#
# echo -n "Reloading $DESC configuration..."
# start-stop-daemon --stop --signal 1 --quiet --pidfile \
# $PIDFILE --exec $DAEMON
# echo "done."
#;;
restart|force-reload)
#
# If the "reload" option is implemented, move the "force-reload"
# option to the "reload" entry above. If not, "force-reload" is
# just the same as "restart".
#
echo -n "Restarting $DESC: $NAME"
$DAEMON stop
sleep 1
$DAEMON start
echo "."
;;
*)
# echo "Usage: $SCRIPTNAME {start|stop|restart|reload|force-reload}" >&2
echo "Usage: $SCRIPTNAME {start|stop|restart|force-reload}" >&2
exit 1
;;
esac
exit 0

View File

@ -1,3 +0,0 @@
#! /usr/bin/dh-exec
debian/bin/vpnserver usr/bin/
usr/vpnserver opt/

View File

@ -1 +0,0 @@
3.0 (quilt)

Binary file not shown.

View File

@ -0,0 +1 @@
7b0f93e0524d80c3f960768684bf8e8ec75c7b17

Binary file not shown.

View File

@ -0,0 +1 @@
7b0f93e0524d80c3f960768684bf8e8ec75c7b17

Binary file not shown.

View File

@ -0,0 +1 @@
5e4ee9a4783a2b5453388aebfca2d5be4132892b

Binary file not shown.

View File

@ -0,0 +1 @@
2a327d413bd0d0e8619c20cdc2316e60586fd496

Binary file not shown.

View File

@ -0,0 +1 @@
2a327d413bd0d0e8619c20cdc2316e60586fd496

View File

@ -1,125 +0,0 @@
How to build SoftEther VPN for UNIX
===================================
Requirements
------------
You need to install the following software to build SoftEther VPN for UNIX.
- Linux, FreeBSD, Solaris or Mac OS X.
- GNU Compiler Collectipon (gcc) and binary utilities.
- GNU Make (gmake).
- GNU C Library (glibc).
- POSIX Threads (pthread).
- OpenSSL (crypto, ssl).
- libiconv.
- readline.
- ncurses.
For example, the following commands help you to install the above programs
on Fedora or CentOS Linux:
$ yum -y groupinstall "Development Tools"
$ yum -y install readline-devel ncurses-devel openssl-devel
How to Build
------------
To build the programs from the source code, run the following commands:
$ ./configure
$ make
If any error occurs, please check the above requirements.
How to Install SoftEther VPN Server, Bridge or Client
-----------------------------------------------------
To install the vpnserver, vpnbridge and vpnclient programs into the
/usr/bin directory, run the following as the root user:
# make install
After the installation will complete successfully:
- Execute 'vpnserver start' to run the SoftEther VPN Server background service.
- Execute 'vpnbridge start' to run the SoftEther VPN Bridge background service.
- Execute 'vpnclient start' to run the SoftEther VPN Client background service.
- Execute 'vpncmd' to run SoftEther VPN Command-Line Utility to configure
VPN Server, VPN Bridge or VPN Client.
- You can also use VPN Server/Client Manager GUI Tool on other Windows PC to
connect to VPN services remotely.
You can download the GUI Tools from https://www.softether-download.com/.
How to Run SoftEther VPN Server for Test
----------------------------------------
To start the SoftEther VPN Server background service, run the following:
$ bin/vpnserver/vpnserver start
To stop the service, run the following:
$ bin/vpnserver/vpnserver stop
To configure the running SoftEther VPN Server service,
you can use SoftEther VPN Command Line Management Utility as following:
$ bin/vpncmd/vpncmd
Or you can also use VPN Server Manager GUI Tool on other Windows PC to
connect to the VPN Server remotely. You can download the GUI Tool
from https://www.softether-download.com/.
How to Run SoftEther VPN Bridge for Test
----------------------------------------
To start the SoftEther VPN Bridge background service, run the following:
$ bin/vpnbridge/vpnbridge start
To stop the service, run the following:
$ bin/vpnbridge/vpnbridge stop
To configure the running SoftEther VPN Bridge service,
you can use SoftEther VPN Command Line Management Utility as following:
$ bin/vpncmd/vpncmd
Or you can also use VPN Server Manager GUI Tool on other Windows PC to
connect to the VPN Bridge remotely. You can download the GUI Tool
from https://www.softether-download.com/.
How to Run SoftEther VPN Client for Test
----------------------------------------
To start the SoftEther VPN Client background service, run the following:
$ bin/vpnclient/vpnclient start
To stop the service, run the following:
$ bin/vpnclient/vpnclient stop
To configure the running SoftEther VPN Client service,
you can use SoftEther VPN Command Line Management Utility as following:
$ bin/vpncmd/vpncmd
Or you can also use VPN Client Manager GUI Tool on other Windows PC to
connect to the VPN Client remotely. You can download the GUI Tool
from https://www.softether-download.com/.
************************************
Thank You Using SoftEther VPN !
By SoftEther VPN Open-Source Project
https://www.softether.org/

View File

@ -1,44 +0,0 @@
How to build SoftEther VPN for Windows
======================================
Requirements
------------
You need to install the following software to build SoftEther VPN for Windows.
- Microsoft Windows XP, Vista, 7, 8 or later.
- Microsoft Visual Studio 2008 with the latest SP (SP1 9.0.30729.4462 QFE).
Make sure that you installed the x64 compiler and build tools.
* Note:
Visual Studio 2008 SP1 is required to build SoftEther VPN on Windows.
Please make sure that VS2008 'SP1' is installed.
Visual Studio 2010, 2012 or 2013 is currently not supported.
Visual Studio 2008 Express Edition is not supported.
Standard Edition, Professional Edition, Team System or Team Suite is
required.
Full Build Instructions
-----------------------
The following steps will build all SoftEther VPN program files, and also build
the installer packages of SoftEther VPN. It is very easy.
1. Run the "BuildAll.cmd" batch file in the "src" directory.
2. Wait until the building process will complete.
3. The built files are stored on the "output" directory.
Partly Build, Debug or Development Instructions on Visual Studio 2008
---------------------------------------------------------------------
If you are a programmer, you can open the SoftEther VPN solution file
with Visual Studio 2008 to customize. Open "src\SEVPN.sln" and enjoy it.
************************************
Thank You Using SoftEther VPN !
By SoftEther VPN Open-Source Project
https://www.softether.org/

View File

@ -1,19 +0,0 @@
SETLOCAL
SET BATCH_FILE_NAME=%0
SET BATCH_DIR_NAME=%0\..
SET NOW_TMP=%time:~0,2%
SET NOW=%date:~0,4%%date:~5,2%%date:~8,2%_%NOW_TMP: =0%%time:~3,2%%time:~6,2%
call "C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\vcvarsall.bat"
call "C:\Program Files\Microsoft Visual Studio 9.0\VC\vcvarsall.bat"
echo on
del %BATCH_DIR_NAME%\bin\BuildUtil.exe
C:\windows\Microsoft.NET\Framework\v3.5\MSBuild.exe /toolsversion:3.5 /verbosity:detailed /target:Clean /property:Configuration=Debug "%BATCH_DIR_NAME%\BuildUtil\BuildUtil.csproj"
C:\windows\Microsoft.NET\Framework\v3.5\MSBuild.exe /toolsversion:3.5 /verbosity:detailed /target:Rebuild /property:Configuration=Debug "%BATCH_DIR_NAME%\BuildUtil\BuildUtil.csproj"
cmd /k "%BATCH_DIR_NAME%\bin\BuildUtil.exe /CMD:All"

View File

@ -1,29 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0" xmlns:asmv3="urn:schemas-microsoft-com:asm.v3">
<trustInfo xmlns="urn:schemas-microsoft-com:asm.v3">
<security>
<requestedPrivileges>
<requestedExecutionLevel level="requireAdministrator" uiAccess="false"></requestedExecutionLevel>
</requestedPrivileges>
</security>
</trustInfo>
<dependency>
<dependentAssembly>
<assemblyIdentity type="win32" name="Microsoft.Windows.Common-Controls" version="6.0.0.0" processorArchitecture="amd64" publicKeyToken="6595b64144ccf1df" language="*"></assemblyIdentity>
</dependentAssembly>
</dependency>
<compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1">
<application>
<supportedOS Id="{1f676c76-80e1-4239-95bb-83d0f6d0da78}"></supportedOS>
<supportedOS Id="{e2011457-1546-43c5-a5fe-008deee3d3f0}"></supportedOS>
<supportedOS Id="{35138b9a-5d96-4fbd-8e2d-a2440225f93a}"></supportedOS>
<supportedOS Id="{4a2f28e3-53b9-4441-ba9c-d69d4a4a6e38}"></supportedOS>
<supportedOS Id="{8e0f7a12-bfb3-4fe8-b9a5-48fd50a15a9a}"></supportedOS>
</application>
</compatibility>
<asmv3:application>
<asmv3:windowsSettings xmlns="http://schemas.microsoft.com/SMI/2005/WindowsSettings">
<dpiAware>true</dpiAware>
</asmv3:windowsSettings>
</asmv3:application>
</assembly>

View File

@ -1,29 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0" xmlns:asmv3="urn:schemas-microsoft-com:asm.v3">
<trustInfo xmlns="urn:schemas-microsoft-com:asm.v3">
<security>
<requestedPrivileges>
<requestedExecutionLevel level="asInvoker" uiAccess="false"></requestedExecutionLevel>
</requestedPrivileges>
</security>
</trustInfo>
<dependency>
<dependentAssembly>
<assemblyIdentity type="win32" name="Microsoft.Windows.Common-Controls" version="6.0.0.0" processorArchitecture="amd64" publicKeyToken="6595b64144ccf1df" language="*"></assemblyIdentity>
</dependentAssembly>
</dependency>
<compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1">
<application>
<supportedOS Id="{1f676c76-80e1-4239-95bb-83d0f6d0da78}"></supportedOS>
<supportedOS Id="{e2011457-1546-43c5-a5fe-008deee3d3f0}"></supportedOS>
<supportedOS Id="{35138b9a-5d96-4fbd-8e2d-a2440225f93a}"></supportedOS>
<supportedOS Id="{4a2f28e3-53b9-4441-ba9c-d69d4a4a6e38}"></supportedOS>
<supportedOS Id="{8e0f7a12-bfb3-4fe8-b9a5-48fd50a15a9a}"></supportedOS>
</application>
</compatibility>
<asmv3:application>
<asmv3:windowsSettings xmlns="http://schemas.microsoft.com/SMI/2005/WindowsSettings">
<dpiAware>true</dpiAware>
</asmv3:windowsSettings>
</asmv3:application>
</assembly>

View File

@ -1,29 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0" xmlns:asmv3="urn:schemas-microsoft-com:asm.v3">
<trustInfo xmlns="urn:schemas-microsoft-com:asm.v3">
<security>
<requestedPrivileges>
<requestedExecutionLevel level="requireAdministrator" uiAccess="false"></requestedExecutionLevel>
</requestedPrivileges>
</security>
</trustInfo>
<dependency>
<dependentAssembly>
<assemblyIdentity type="win32" name="Microsoft.Windows.Common-Controls" version="6.0.0.0" processorArchitecture="x86" publicKeyToken="6595b64144ccf1df" language="*"></assemblyIdentity>
</dependentAssembly>
</dependency>
<compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1">
<application>
<supportedOS Id="{1f676c76-80e1-4239-95bb-83d0f6d0da78}"></supportedOS>
<supportedOS Id="{e2011457-1546-43c5-a5fe-008deee3d3f0}"></supportedOS>
<supportedOS Id="{35138b9a-5d96-4fbd-8e2d-a2440225f93a}"></supportedOS>
<supportedOS Id="{4a2f28e3-53b9-4441-ba9c-d69d4a4a6e38}"></supportedOS>
<supportedOS Id="{8e0f7a12-bfb3-4fe8-b9a5-48fd50a15a9a}"></supportedOS>
</application>
</compatibility>
<asmv3:application>
<asmv3:windowsSettings xmlns="http://schemas.microsoft.com/SMI/2005/WindowsSettings">
<dpiAware>true</dpiAware>
</asmv3:windowsSettings>
</asmv3:application>
</assembly>

View File

@ -1,29 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0" xmlns:asmv3="urn:schemas-microsoft-com:asm.v3">
<trustInfo xmlns="urn:schemas-microsoft-com:asm.v3">
<security>
<requestedPrivileges>
<requestedExecutionLevel level="asInvoker" uiAccess="false"></requestedExecutionLevel>
</requestedPrivileges>
</security>
</trustInfo>
<dependency>
<dependentAssembly>
<assemblyIdentity type="win32" name="Microsoft.Windows.Common-Controls" version="6.0.0.0" processorArchitecture="x86" publicKeyToken="6595b64144ccf1df" language="*"></assemblyIdentity>
</dependentAssembly>
</dependency>
<compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1">
<application>
<supportedOS Id="{1f676c76-80e1-4239-95bb-83d0f6d0da78}"></supportedOS>
<supportedOS Id="{e2011457-1546-43c5-a5fe-008deee3d3f0}"></supportedOS>
<supportedOS Id="{35138b9a-5d96-4fbd-8e2d-a2440225f93a}"></supportedOS>
<supportedOS Id="{4a2f28e3-53b9-4441-ba9c-d69d4a4a6e38}"></supportedOS>
<supportedOS Id="{8e0f7a12-bfb3-4fe8-b9a5-48fd50a15a9a}"></supportedOS>
</application>
</compatibility>
<asmv3:application>
<asmv3:windowsSettings xmlns="http://schemas.microsoft.com/SMI/2005/WindowsSettings">
<dpiAware>true</dpiAware>
</asmv3:windowsSettings>
</asmv3:application>
</assembly>

View File

@ -1,18 +0,0 @@
; VPN Client Web Installer Inf File
;
; Copyright (c) SoftEther Project at University of Tsukuba, Japan.
; All Rights Reserved.
[version]
signature="$CHICAGO$"
AdvancedINF=2.0
[Add.Code]
vpnweb.ocx=vpnweb.ocx
[vpnweb.ocx]
file-win32-x86=thiscab
clsid={64F1A16B-C3EE-484C-B551-35338A9BB6D2}
FileVersion=$CAB_VERSION$
RegisterServer=yes

Binary file not shown.

View File

@ -1,74 +0,0 @@
MICROSOFT CABINET SOFTWARE DEVELOPMENT KIT
END-USER LICENSE AGREEMENT FOR MICROSOFT SOFTWARE
IMPORTANT-READ CAREFULLY: This Microsoft End-User License Agreement ("EULA") is a legal agreement between you (either an individual or a single entity) and Microsoft Corporation for the Microsoft software product identified above, which includes computer software and associated media and printed materials, and may include "online" or electronic documentation ("SOFTWARE PRODUCT" or "SOFTWARE"). By installing, copying, or otherwise using the SOFTWARE PRODUCT, you agree to be bound by the terms of this EULA. If you do not agree to the terms of this EULA; promptly return the unused SOFTWARE PRODUCT to the place from which you obtained it for a full refund; or if you received the SOFTWARE PRODUCT as part of a subscription or other service from Microsoft, you may cancel the subscription and receive a pro rata portion of the subscription price.
SOFTWARE PRODUCT LICENSE
The SOFTWARE PRODUCT is protected by copyright laws and international copyright treaties, as well as other intellectual property laws and treaties. The SOFTWARE PRODUCT is licensed, not sold.
1. GRANT OF LICENSE. This EULA grants you the following limited, non-exclusive rights:
Software Product. You may install and use the SOFTWARE PRODUCT on a single computer solely for the purpose of developing applications which create, extract or manipulate files that are compatible with Microsoft CAB file format ("Application"). You may not use the SOFTWARE PRODUCT to create files which are not compatible with the Microsoft CAB file format.
Microsoft Developer Network Subscriber. If you acquired the SOFTWARE PRODUCT through a subscription to the Microsoft Developer Network, and you are either an individual developer or an individual designated within a single entity, you are granted the following additional rights with respect to the SOFTWARE PRODUCT: (a) you may make and use copies of the SOFTWARE PRODUCT on up to ten (10) separate computers, provided that you are the only individual using the SOFTWARE PRODUCT on each such computer, and (b) if you are a single entity, you may designate one individual within your organization to have the right to use the SOFTWARE PRODUCT in the manner described herein.
Sample Code. You may modify the sample source code located in the SOFTWARE PRODUCT's "SAMPLES" directory ("Sample Code") to design, develop, and test your Application. You may also reproduce and distribute the Sample Code in object code form along with any modifications you make to the Sample Code, provided that the modifications do not create files which are not compatible with Microsoft CAB file format and that you comply with the Distribution Requirements described below. For purposes of this section, "modifications" shall mean changes to the functionality of the Sample Code.
Redistributable Code. Portions of the SOFTWARE PRODUCT in the "BIN" and "LIB" directories are designated as "Redistributable Code." You may reproduce and distribute the Redistributable Code provided you comply with the Distribution Requirements described below.
Distribution Requirements. You may copy and redistribute the Sample Code and/or Redistributable Code (collectively "REDISTRIBUTABLE COMPONENTS") as described above, provided that (a) you distribute the REDISTRIBUTABLE COMPONENTS only in conjunction with, and as a part of, your Application; (b) your Application adds significant and primary functionality to the REDISTRIBUTABLE COMPONENTS; (c) the Application does not allow the use of the REDISTRIBUTABLE COMPONENTS for files which are not compatible with the Microsoft CAB files; (d) the executable code in the BIN directory may be redistributed unmodified in conjunction with your Application provided that your Application adds significant and primary functionality to the REDISTRIBUTABLE COMPONENTS; (e) the library code in the LIB directory may only be redistributed when linked into your Application; (f) you do not use Microsoft's name, logo, or trademarks to market your Application; (g) you include a valid copyright notice on your Application; and (h) you agree to indemnify, hold harmless, and defend Microsoft from and against any claims or lawsuits, including attorneys' fees, that arise or result from the use or distribution of your Application. Contact Microsoft for the applicable royalties due and other licensing terms for all other uses and/or distribution of the REDISTRIBUTABLE COMPONENTS.
Microsoft reserves all rights not expressly granted to you.
2. COPYRIGHT. All rights, title, and copyrights in and to the SOFTWARE PRODUCT (including, but not limited to, any images, photographs, animations, video, audio, music, text, and "applets" incorporated into the SOFTWARE PRODUCT) and any copies of the SOFTWARE PRODUCT are owned by Microsoft or its suppliers. The SOFTWARE PRODUCT is protected by copyright laws and international treaty provisions. Therefore, you must treat the SOFTWARE PRODUCT like any other copyrighted material, except that you may either (a) make one copy of the SOFTWARE PRODUCT solely for backup or archival purposes, or (b) install the SOFTWARE PRODUCT on a single computer, provided you keep the original solely for backup or archival purposes. You may not copy the printed materials accompanying the SOFTWARE PRODUCT.
3. PRERELEASE CODE. The SOFTWARE PRODUCT may contain PRERELEASE CODE that is not at the level of performance and compatibility of the final, generally available, product offering. These portions of the SOFTWARE PRODUCT may not operate correctly and may be substantially modified prior to first commercial shipment. Microsoft is not obligated to make this or any later version of the SOFTWARE PRODUCT commercially available. Microsoft grants you the right to distribute test versions of your Application created using the PRERELEASE CODE provided you comply with the Distribution Requirements described in Section 1 and the following additional provisions: (a) you must mark the test version of your Application "BETA" and (b) you are solely responsible for updating your customers with versions of your Application that operate satisfactorily with the final commercial release of the PRERELEASE CODE.
4. DESCRIPTION OF OTHER RIGHTS AND LIMITATIONS.
Limitations on Reverse-Engineering, Decompilation, and Disassembly. You may not reverse- engineer, decompile, or disassemble the SOFTWARE PRODUCT, except and only to the extent that such activity is expressly permitted by applicable law notwithstanding this limitation.
Rental. You may not rent or lease the SOFTWARE PRODUCT.
Software Transfer. You may permanently transfer all of your rights under this EULA, provided you retain no copies, you transfer all of the SOFTWARE PRODUCT (including all component parts, the media and printed materials, any upgrades, this EULA, and, if applicable, the Certificate of Authenticity), and the recipient agrees to the terms of this EULA. If the SOFTWARE PRODUCT is an upgrade, any transfer must include all prior versions of the SOFTWARE PRODUCT.
Termination. Without prejudice to any other rights, Microsoft may terminate this EULA if you fail to comply with the terms and conditions of this EULA. In such event, you must destroy all copies of the SOFTWARE PRODUCT and all of its component parts.
5. EXPORT RESTRICTIONS. You agree that neither you nor your customers intend to or will, directly or indirectly, export or transmit (a) the SOFTWARE PRODUCT or related documentation and technical data, or (b) your Application as described in Section 1 of this EULA (or any part thereof), or process, or service that is the direct product of the SOFTWARE PRODUCT to any country to which such export or transmission is restricted by any applicable U.S. regulation or statute, without the prior written consent, if required, of the Bureau of Export Administration of the U.S. Department of Commerce, or such other governmental entity as may have jurisdiction over such export or transmission.
6. U.S. GOVERNMENT RESTRICTED RIGHTS. The SOFTWARE PRODUCT and documentation are provided with RESTRICTED RIGHTS. Use, duplication, or disclosure by the Government is subject to restrictions as set forth in subparagraph (c)(1)(ii) of The Rights in Technical Data and Computer Software clause at DFARS 252.227-7013 or subparagraphs (c)(1) and (2) of the Commercial Computer Software - Restricted Rights at 48 CFR 52.227-19, as applicable. Manufacturer is Microsoft Corporation/One Microsoft Way/Redmond, WA 98052-6399.
MISCELLANEOUS
If you acquired this product in the United States, this EULA is governed by the laws of the State of Washington.
If you acquired this product in Canada, this EULA is governed by the laws of the Province of Ontario, Canada. Each of the parties hereto irrevocably attorns to the jurisdiction of the courts of the Province of Ontario and further agrees to commence any litigation that may arise hereunder in the courts located in the Judicial District of York, Province of Ontario.
If this product was acquired outside the United States, local law may apply.
Should you have any questions concerning this EULA, or if you desire to contact Microsoft for any reason, please contact the Microsoft subsidiary serving your country, or write: Microsoft Customer Sales and Service/One Microsoft Way/Redmond, WA 98052-6399.
NO WARRANTIES. To the maximum extent permitted by applicable law, Microsoft expressly disclaims any warranty for the SOFTWARE PRODUCT. The SOFTWARE PRODUCT and any related documentation are provided "as is" without warranty of any kind, either express or implied, including, without limitation, the implied warranties of merchantability or fitness for a particular purpose. The entire risk arising out of use or performance of the SOFTWARE PRODUCT remains with you.
LIMITATION OF LIABILITY. Microsoft's entire liability and your exclusive remedy under this EULA shall not exceed five dollars (US$5.00).
NO LIABILITY FOR CONSEQUENTIAL DAMAGES. To the maximum extent permitted by applicable law, in no event shall Microsoft or its suppliers be liable for any damages whatsoever (including, without limitation, damages for loss of business profit, business interruption, loss of business information, or any other pecuniary loss) arising out of the use of, or inability to use, this Microsoft product, even if Microsoft has been advised of the possibility of such damages. Because some states/jurisdictions do not allow the exclusion or limitation of liability for consequential or incidental damages, the above limitation may not apply to you.
Si vous avez acquis votre produit Microsoft au CANADA, la garantie limitée suivante vous concerne:
GARANTIE LIMITÉE
EXCLUSION DE GARANTIES. Microsoft renonce entièrement à toute garantie pour le LOGICIEL. Le LOGICIEL et toute autre documentation s'y rapportant sont fournis « comme tels » sans aucune garantie quelle qu'elle soit, expresse ou implicite, y compris, mais ne se limitant pas aux garanties implicites de la qualité marchande ou un usage particulier. Le risque total découlant de l'utilisation ou de la performance du LOGICIEL est entre vos mains.
RESPONSABILITÉ LIMITÉE. La seule obligation de Microsoft et votre recours exclusif concernant ce contrat n'excèderont pas cinq dollars (US$5.00).
ABSENCE DE RESPONSABILITÉ POUR LES DOMMAGES INDIRECTS. Microsoft ou ses
fournisseurs ne pourront être tenus responsables en aucune circonstance de tout dommage quel qu'il soit (y compris mais non de façon limitative les dommages directs ou indirects causés par la perte de bénéfices commerciaux, l'interruption des affaires, la perte d'information commerciale ou toute autre perte pécuniaire) résultant de l'utilisation ou de l'impossibilité d'utilisation de ce produit, et ce, même si la société Microsoft a été avisée de l'éventualité de tels dommages. Certains états/juridictions ne permettent pas l'exclusion ou la limitation de responsabilité relative aux dommages indirects ou consécutifs, et la limitation ci-dessus peut ne pas s'appliquer à votre égard.
La présente Convention est régie par les lois de la province d'Ontario, Canada. Chacune des parties à la Convention reconnaît irrévocablement la compétence des tribunaux de la province d'Ontario et consent à instituer tout litige qui pourrait découler de la Convention auprès des tribunaux situés dans le district judiciaire de York, province d'Ontario.
Au cas où vous auriez des questions concernant cette licence ou que vous désiriez vous mettre en rapport avec Microsoft pour quelque raison que ce soit, veuillez contacter la succursale Microsoft desservant votre pays, dont l'adresse est fournie dans ce produit, ou écrire à: Microsoft Customer Sales and Service, One Microsoft Way, Redmond, Washington 98052-6399.
3/27/97 10:39 AM 970860004

View File

@ -1,30 +0,0 @@
#pragma code_page(932)
1 VERSIONINFO
FILEVERSION $VER_MAJOR$,$VER_MINOR$,0,$VER_BUILD$
PRODUCTVERSION $VER_MAJOR$,$VER_MINOR$,0,$VER_BUILD$
FILEFLAGSMASK 0x17L
FILEOS 0x4L
FILETYPE 0x1L
FILESUBTYPE 0x0L
BEGIN
BLOCK "StringFileInfo"
BEGIN
BLOCK "041104b0"
BEGIN
VALUE "CompanyName", "SoftEther VPN Project at University of Tsukuba, Japan. (Open-source Customized Build)"
VALUE "FileDescription", "$PRODUCTNAME$ (Open-source Customized Build)"
VALUE "FileVersion", "$VER_MAJOR$, $VER_MINOR$, 0, $VER_BUILD$"
VALUE "InternalName", "$INTERNALNAME$ (Open-source Customized Build)"
VALUE "LegalCopyright", "Copyright (C) 2012-$YEAR$ SoftEther VPN Project. All Rights Reserved. (Open-source Customized Build)"
VALUE "LegalTrademarks", "SoftEther(R) is a registered trademark of SoftEther Corporation in Japan, United Status and People's Republic of China. SoftEther Corporation is a company founded at University of Tsukuba, Japan."
VALUE "OriginalFilename", "$FILENAME$"
VALUE "ProductName", "$PRODUCTNAME$ (Open-source Customized Build)"
VALUE "ProductVersion", "$VER_MAJOR$, $VER_MINOR$, 0, $VER_BUILD$"
END
END
BLOCK "VarFileInfo"
BEGIN
VALUE "Translation", 0x411, 1200
END
END

View File

@ -1,30 +0,0 @@
#pragma code_page(932)
1 VERSIONINFO
FILEVERSION $VER_MAJOR$,$VER_MINOR$,0,$VER_BUILD$
PRODUCTVERSION $VER_MAJOR$,$VER_MINOR$,0,$VER_BUILD$
FILEFLAGSMASK 0x17L
FILEOS 0x4L
FILETYPE 0x1L
FILESUBTYPE 0x0L
BEGIN
BLOCK "StringFileInfo"
BEGIN
BLOCK "041104b0"
BEGIN
VALUE "CompanyName", "University of Tsukuba"
VALUE "FileDescription", "VPN Gate Plug-in DLL for SoftEther VPN"
VALUE "FileVersion", "$VER_MAJOR$, $VER_MINOR$, 0, $VER_BUILD$"
VALUE "InternalName", "$INTERNALNAME$"
VALUE "LegalCopyright", "Copyright (C) 2012-$YEAR$ VPN Gate Project at University of Tsukuba. All Rights Reserved."
VALUE "LegalTrademarks", ""
VALUE "OriginalFilename", "$FILENAME$"
VALUE "ProductName", "VPN Gate Software"
VALUE "ProductVersion", "$VER_MAJOR$, $VER_MINOR$, 0, $VER_BUILD$"
END
END
BLOCK "VarFileInfo"
BEGIN
VALUE "Translation", 0x411, 1200
END
END

View File

@ -1,214 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="3.5" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProductVersion>9.0.30729</ProductVersion>
<SchemaVersion>2.0</SchemaVersion>
<ProjectGuid>{384815C3-333C-4CEC-9DCD-B6AB2602EBB9}</ProjectGuid>
<OutputType>Exe</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>BuildUtil</RootNamespace>
<AssemblyName>BuildUtilTmp</AssemblyName>
<TargetFrameworkVersion>v2.0</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<ApplicationIcon>BuildUtilIcon.ico</ApplicationIcon>
<IsWebBootstrapper>false</IsWebBootstrapper>
<StartupObject>BuildUtil.BuildUtilMain</StartupObject>
<NoWin32Manifest>true</NoWin32Manifest>
<PublishUrl>publish\</PublishUrl>
<Install>true</Install>
<InstallFrom>Disk</InstallFrom>
<UpdateEnabled>false</UpdateEnabled>
<UpdateMode>Foreground</UpdateMode>
<UpdateInterval>7</UpdateInterval>
<UpdateIntervalUnits>Days</UpdateIntervalUnits>
<UpdatePeriodically>false</UpdatePeriodically>
<UpdateRequired>false</UpdateRequired>
<MapFileExtensions>true</MapFileExtensions>
<ApplicationRevision>0</ApplicationRevision>
<ApplicationVersion>1.0.0.%2a</ApplicationVersion>
<UseApplicationTrust>false</UseApplicationTrust>
<BootstrapperEnabled>true</BootstrapperEnabled>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>..\bin\</OutputPath>
<DefineConstants>TRACE;DEBUG;BU_SOFTETHER;BU_OSS</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<PlatformTarget>AnyCPU</PlatformTarget>
<DocumentationFile>
</DocumentationFile>
<UseVSHostingProcess>false</UseVSHostingProcess>
</PropertyGroup>
<ItemGroup>
<Reference Include="System" />
<Reference Include="System.Configuration" />
<Reference Include="System.Data" />
<Reference Include="System.DirectoryServices" />
<Reference Include="System.Drawing" />
<Reference Include="System.EnterpriseServices" />
<Reference Include="System.Runtime.Serialization.Formatters.Soap" />
<Reference Include="System.Transactions" />
<Reference Include="System.Web" />
<Reference Include="System.Web.Services" />
<Reference Include="System.Windows.Forms" />
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="BuildUtilCommands.cs" />
<Compile Include="BuildUtilMain.cs" />
<Compile Include="CodeSign.cs" />
<Compile Include="CoreUtil\Bmp.cs" />
<Compile Include="CoreUtil\Buf.cs" />
<Compile Include="CoreUtil\Cache.cs" />
<Compile Include="CoreUtil\Compress.cs" />
<Compile Include="CoreUtil\Console.cs" />
<Compile Include="CoreUtil\Csv.cs" />
<Compile Include="CoreUtil\Env.cs" />
<Compile Include="CoreUtil\FileIO.cs" />
<Compile Include="CoreUtil\GZip.cs" />
<Compile Include="CoreUtil\Kernel.cs" />
<Compile Include="CoreUtil\MultiLang.cs" />
<Compile Include="CoreUtil\Packer.cs" />
<Compile Include="CoreUtil\RC4.cs" />
<Compile Include="CoreUtil\ReadIni.cs" />
<Compile Include="CoreUtil\Reg.cs" />
<Compile Include="CoreUtil\Secure.cs" />
<Compile Include="CoreUtil\Stb.cs" />
<Compile Include="CoreUtil\Str.cs" />
<Compile Include="CoreUtil\Tar.cs" />
<Compile Include="CoreUtil\Thread.cs" />
<Compile Include="CoreUtil\Time.cs" />
<Compile Include="CoreUtil\Util.cs" />
<Compile Include="CoreUtil\Win32.cs" />
<Compile Include="CoreUtil\Zip.cs" />
<Compile Include="CoreUtil\ZLib.cs" />
<Compile Include="PEUtil.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<Compile Include="Properties\Resources.Designer.cs">
<AutoGen>True</AutoGen>
<DesignTime>True</DesignTime>
<DependentUpon>Resources.resx</DependentUpon>
</Compile>
<Compile Include="Properties\Settings.Designer.cs">
<AutoGen>True</AutoGen>
<DesignTimeSharedInput>True</DesignTimeSharedInput>
<DependentUpon>Settings.settings</DependentUpon>
</Compile>
<Compile Include="Test.cs" />
<Compile Include="UnixBuildSoftwares.cs" />
<Compile Include="VpnBuilder.cs" />
<Compile Include="VpnBuilderConfig.cs" />
<Compile Include="VpnBuilderConfigTypes.cs" />
<Compile Include="Web References\HvSignService\Reference.cs">
<AutoGen>True</AutoGen>
<DesignTime>True</DesignTime>
<DependentUpon>Reference.map</DependentUpon>
</Compile>
<Compile Include="Web References\SignService\Reference.cs">
<AutoGen>True</AutoGen>
<DesignTime>True</DesignTime>
<DependentUpon>Reference.map</DependentUpon>
</Compile>
<Compile Include="Win32BuildSoftware.cs" />
<Compile Include="Win32BuildUtil.cs" />
</ItemGroup>
<ItemGroup>
<WebReferences Include="Web References\" />
</ItemGroup>
<ItemGroup>
<WebReferenceUrl Include="http://dv/Sign/Sign.asmx">
<UrlBehavior>Dynamic</UrlBehavior>
<RelPath>Web References\SignService\</RelPath>
<UpdateFromURL>http://dv/Sign/Sign.asmx</UpdateFromURL>
<ServiceLocationURL>
</ServiceLocationURL>
<CachedDynamicPropName>
</CachedDynamicPropName>
<CachedAppSettingsObjectName>Settings</CachedAppSettingsObjectName>
<CachedSettingsPropName>BuildUtil_SignService_Sign</CachedSettingsPropName>
</WebReferenceUrl>
<WebReferenceUrl Include="http://hvsigncode/Sign.asmx">
<UrlBehavior>Dynamic</UrlBehavior>
<RelPath>Web References\HvSignService\</RelPath>
<UpdateFromURL>http://hvsigncode/Sign.asmx</UpdateFromURL>
<ServiceLocationURL>
</ServiceLocationURL>
<CachedDynamicPropName>
</CachedDynamicPropName>
<CachedAppSettingsObjectName>Settings</CachedAppSettingsObjectName>
<CachedSettingsPropName>BuildUtilTmp_HvSignService_Sign</CachedSettingsPropName>
</WebReferenceUrl>
</ItemGroup>
<ItemGroup>
<None Include="app.config" />
<None Include="Properties\Settings.settings">
<Generator>SettingsSingleFileGenerator</Generator>
<LastGenOutput>Settings.Designer.cs</LastGenOutput>
</None>
<None Include="Web References\HvSignService\Sign.wsdl" />
<None Include="Web References\SignService\Reference.map">
<Generator>MSDiscoCodeGenerator</Generator>
<LastGenOutput>Reference.cs</LastGenOutput>
</None>
<None Include="Web References\SignService\Sign.disco" />
<None Include="Web References\SignService\Sign.wsdl" />
</ItemGroup>
<ItemGroup>
<Content Include="BuildUtilIcon.ico" />
<None Include="Web References\HvSignService\Reference.map">
<Generator>MSDiscoCodeGenerator</Generator>
<LastGenOutput>Reference.cs</LastGenOutput>
</None>
<None Include="Web References\HvSignService\Sign.disco" />
</ItemGroup>
<ItemGroup>
<BootstrapperPackage Include="Microsoft.Net.Client.3.5">
<Visible>False</Visible>
<ProductName>.NET Framework Client Profile</ProductName>
<Install>false</Install>
</BootstrapperPackage>
<BootstrapperPackage Include="Microsoft.Net.Framework.2.0">
<Visible>False</Visible>
<ProductName>.NET Framework 2.0 %28x86%29</ProductName>
<Install>true</Install>
</BootstrapperPackage>
<BootstrapperPackage Include="Microsoft.Net.Framework.3.0">
<Visible>False</Visible>
<ProductName>.NET Framework 3.0 %28x86%29</ProductName>
<Install>false</Install>
</BootstrapperPackage>
<BootstrapperPackage Include="Microsoft.Net.Framework.3.5">
<Visible>False</Visible>
<ProductName>.NET Framework 3.5</ProductName>
<Install>false</Install>
</BootstrapperPackage>
<BootstrapperPackage Include="Microsoft.Net.Framework.3.5.SP1">
<Visible>False</Visible>
<ProductName>.NET Framework 3.5 SP1</ProductName>
<Install>false</Install>
</BootstrapperPackage>
</ItemGroup>
<ItemGroup>
<EmbeddedResource Include="Properties\Resources.resx">
<Generator>ResXFileCodeGenerator</Generator>
<LastGenOutput>Resources.Designer.cs</LastGenOutput>
</EmbeddedResource>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->
<PropertyGroup>
<PostBuildEvent>$(ProjectDir)CopyBuildUtil.cmd</PostBuildEvent>
</PropertyGroup>
</Project>

File diff suppressed because it is too large Load Diff

Binary file not shown.

Before

Width:  |  Height:  |  Size: 30 KiB

View File

@ -1,210 +0,0 @@
// SoftEther VPN Source Code - Stable Edition Repository
// Build Utility
//
// SoftEther VPN Server, Client and Bridge are free software under the Apache License, Version 2.0.
//
// Copyright (c) Daiyuu Nobori.
// Copyright (c) SoftEther VPN Project, University of Tsukuba, Japan.
// Copyright (c) SoftEther Corporation.
// Copyright (c) all contributors on SoftEther VPN project in GitHub.
//
// All Rights Reserved.
//
// http://www.softether.org/
//
// This stable branch is officially managed by Daiyuu Nobori, the owner of SoftEther VPN Project.
// Pull requests should be sent to the Developer Edition Master Repository on https://github.com/SoftEtherVPN/SoftEtherVPN
//
// License: The Apache License, Version 2.0
// https://www.apache.org/licenses/LICENSE-2.0
//
// DISCLAIMER
// ==========
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
// SOFTWARE.
//
// THIS SOFTWARE IS DEVELOPED IN JAPAN, AND DISTRIBUTED FROM JAPAN, UNDER
// JAPANESE LAWS. YOU MUST AGREE IN ADVANCE TO USE, COPY, MODIFY, MERGE, PUBLISH,
// DISTRIBUTE, SUBLICENSE, AND/OR SELL COPIES OF THIS SOFTWARE, THAT ANY
// JURIDICAL DISPUTES WHICH ARE CONCERNED TO THIS SOFTWARE OR ITS CONTENTS,
// AGAINST US (SOFTETHER PROJECT, SOFTETHER CORPORATION, DAIYUU NOBORI OR OTHER
// SUPPLIERS), OR ANY JURIDICAL DISPUTES AGAINST US WHICH ARE CAUSED BY ANY KIND
// OF USING, COPYING, MODIFYING, MERGING, PUBLISHING, DISTRIBUTING, SUBLICENSING,
// AND/OR SELLING COPIES OF THIS SOFTWARE SHALL BE REGARDED AS BE CONSTRUED AND
// CONTROLLED BY JAPANESE LAWS, AND YOU MUST FURTHER CONSENT TO EXCLUSIVE
// JURISDICTION AND VENUE IN THE COURTS SITTING IN TOKYO, JAPAN. YOU MUST WAIVE
// ALL DEFENSES OF LACK OF PERSONAL JURISDICTION AND FORUM NON CONVENIENS.
// PROCESS MAY BE SERVED ON EITHER PARTY IN THE MANNER AUTHORIZED BY APPLICABLE
// LAW OR COURT RULE.
//
// USE ONLY IN JAPAN. DO NOT USE THIS SOFTWARE IN ANOTHER COUNTRY UNLESS YOU HAVE
// A CONFIRMATION THAT THIS SOFTWARE DOES NOT VIOLATE ANY CRIMINAL LAWS OR CIVIL
// RIGHTS IN THAT PARTICULAR COUNTRY. USING THIS SOFTWARE IN OTHER COUNTRIES IS
// COMPLETELY AT YOUR OWN RISK. THE SOFTETHER VPN PROJECT HAS DEVELOPED AND
// DISTRIBUTED THIS SOFTWARE TO COMPLY ONLY WITH THE JAPANESE LAWS AND EXISTING
// CIVIL RIGHTS INCLUDING PATENTS WHICH ARE SUBJECTS APPLY IN JAPAN. OTHER
// COUNTRIES' LAWS OR CIVIL RIGHTS ARE NONE OF OUR CONCERNS NOR RESPONSIBILITIES.
// WE HAVE NEVER INVESTIGATED ANY CRIMINAL REGULATIONS, CIVIL LAWS OR
// INTELLECTUAL PROPERTY RIGHTS INCLUDING PATENTS IN ANY OF OTHER 200+ COUNTRIES
// AND TERRITORIES. BY NATURE, THERE ARE 200+ REGIONS IN THE WORLD, WITH
// DIFFERENT LAWS. IT IS IMPOSSIBLE TO VERIFY EVERY COUNTRIES' LAWS, REGULATIONS
// AND CIVIL RIGHTS TO MAKE THE SOFTWARE COMPLY WITH ALL COUNTRIES' LAWS BY THE
// PROJECT. EVEN IF YOU WILL BE SUED BY A PRIVATE ENTITY OR BE DAMAGED BY A
// PUBLIC SERVANT IN YOUR COUNTRY, THE DEVELOPERS OF THIS SOFTWARE WILL NEVER BE
// LIABLE TO RECOVER OR COMPENSATE SUCH DAMAGES, CRIMINAL OR CIVIL
// RESPONSIBILITIES. NOTE THAT THIS LINE IS NOT LICENSE RESTRICTION BUT JUST A
// STATEMENT FOR WARNING AND DISCLAIMER.
//
// READ AND UNDERSTAND THE 'WARNING.TXT' FILE BEFORE USING THIS SOFTWARE.
// SOME SOFTWARE PROGRAMS FROM THIRD PARTIES ARE INCLUDED ON THIS SOFTWARE WITH
// LICENSE CONDITIONS WHICH ARE DESCRIBED ON THE 'THIRD_PARTY.TXT' FILE.
//
//
// SOURCE CODE CONTRIBUTION
// ------------------------
//
// Your contribution to SoftEther VPN Project is much appreciated.
// Please send patches to us through GitHub.
// Read the SoftEther VPN Patch Acceptance Policy in advance:
// http://www.softether.org/5-download/src/9.patch
//
//
// DEAR SECURITY EXPERTS
// ---------------------
//
// If you find a bug or a security vulnerability please kindly inform us
// about the problem immediately so that we can fix the security problem
// to protect a lot of users around the world as soon as possible.
//
// Our e-mail address for security reports is:
// softether-vpn-security [at] softether.org
//
// Please note that the above e-mail address is not a technical support
// inquiry address. If you need technical assistance, please visit
// http://www.softether.org/ and ask your question on the users forum.
//
// Thank you for your cooperation.
//
//
// NO MEMORY OR RESOURCE LEAKS
// ---------------------------
//
// The memory-leaks and resource-leaks verification under the stress
// test has been passed before release this source code.
using System;
using System.Threading;
using System.Text;
using System.Configuration;
using System.Collections;
using System.Collections.Generic;
using System.Collections.Specialized;
using System.Security.Cryptography;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.IO;
using System.Drawing;
using System.Drawing.Imaging;
using System.Drawing.Drawing2D;
using System.Diagnostics;
using System.Net;
using System.Net.Security;
using System.Security.Cryptography.X509Certificates;
using CoreUtil;
namespace BuildUtil
{
public class BuildUtilMain
{
public static bool pause = false;
// Main function
public static int Main(string[] args)
{
string errMsg = "";
int ret = 0;
ret = ConsoleService.EntryPoint("BuildUtil " + Env.CommandLine, "BuildUtil", typeof(BuildUtilMain), out errMsg);
if (ret != 0)
{
Con.WriteLine("{0}: fatal error C0001: {1}", Path.GetFileNameWithoutExtension(Env.ExeFileName), errMsg);
if (pause)
{
Console.Write("Press any key to exit...");
Console.ReadKey();
}
Environment.Exit(1);
}
return ret;
}
// Command execution
[ConsoleCommandMethod(
"VPN Build Utility",
"[/IN:infile] [/OUT:outfile] [/CSV] [/PAUSEIFERROR:yes|no] [/CMD command_line...]",
"VPN Build Utility",
"IN:This will specify the text file 'infile' that contains the list of commands that are automatically executed after the connection is completed. If the /IN parameter is specified, the vpncmd program will terminate automatically after the execution of all commands in the file are finished. If the file contains multiple-byte characters, the encoding must be Unicode (UTF-8). This cannot be specified together with /CMD (if /CMD is specified, /IN will be ignored).",
"OUT:You can specify the text file 'outfile' to write all strings such as onscreen prompts, message, error and execution results. Note that if the specified file already exists, the contents of the existing file will be overwritten. Output strings will be recorded using Unicode (UTF-8) encoding.",
"CMD:If the optional command 'command_line...' is included after /CMD, that command will be executed after the connection is complete and the vpncmd program will terminate after that. This cannot be specified together with /IN (if specified together with /IN, /IN will be ignored). Specify the /CMD parameter after all other vpncmd parameters.",
"CSV:Enable CSV Mode.",
"PAUSEIFERROR:Specify yes if you'd like to pause before exiting the process if there are any errors."
)]
public static int BuildUtil(ConsoleService c, string cmdName, string str)
{
Con.WriteLine("");
Con.WriteLine("Copyright (c) SoftEther VPN Project. All Rights Reserved.");
Con.WriteLine("");
ConsoleParam[] args =
{
new ConsoleParam("IN", null, null, null, null),
new ConsoleParam("OUT", null, null, null, null),
new ConsoleParam("CMD", null, null, null, null),
new ConsoleParam("CSV", null, null, null, null),
new ConsoleParam("PAUSEIFERROR", null, null, null, null),
new ConsoleParam("DT", null, null, null, null),
};
ConsoleParamValueList vl = c.ParseCommandList(cmdName, str, args);
pause = vl["PAUSEIFERROR"].BoolValue;
string cmdline = vl["CMD"].StrValue;
if (vl["DT"].IsEmpty == false)
{
BuildSoftwareList.ListCreatedDateTime = Str.StrToDateTime(vl["DT"].StrValue);
}
ConsoleService cs = c;
while (cs.DispatchCommand(cmdline, "BuildUtil>", typeof(BuildUtilCommands), null))
{
if (Str.IsEmptyStr(cmdline) == false)
{
break;
}
}
return cs.RetCode;
}
}
}

View File

@ -1,292 +0,0 @@
// SoftEther VPN Source Code - Stable Edition Repository
// Build Utility
//
// SoftEther VPN Server, Client and Bridge are free software under the Apache License, Version 2.0.
//
// Copyright (c) Daiyuu Nobori.
// Copyright (c) SoftEther VPN Project, University of Tsukuba, Japan.
// Copyright (c) SoftEther Corporation.
// Copyright (c) all contributors on SoftEther VPN project in GitHub.
//
// All Rights Reserved.
//
// http://www.softether.org/
//
// This stable branch is officially managed by Daiyuu Nobori, the owner of SoftEther VPN Project.
// Pull requests should be sent to the Developer Edition Master Repository on https://github.com/SoftEtherVPN/SoftEtherVPN
//
// License: The Apache License, Version 2.0
// https://www.apache.org/licenses/LICENSE-2.0
//
// DISCLAIMER
// ==========
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
// SOFTWARE.
//
// THIS SOFTWARE IS DEVELOPED IN JAPAN, AND DISTRIBUTED FROM JAPAN, UNDER
// JAPANESE LAWS. YOU MUST AGREE IN ADVANCE TO USE, COPY, MODIFY, MERGE, PUBLISH,
// DISTRIBUTE, SUBLICENSE, AND/OR SELL COPIES OF THIS SOFTWARE, THAT ANY
// JURIDICAL DISPUTES WHICH ARE CONCERNED TO THIS SOFTWARE OR ITS CONTENTS,
// AGAINST US (SOFTETHER PROJECT, SOFTETHER CORPORATION, DAIYUU NOBORI OR OTHER
// SUPPLIERS), OR ANY JURIDICAL DISPUTES AGAINST US WHICH ARE CAUSED BY ANY KIND
// OF USING, COPYING, MODIFYING, MERGING, PUBLISHING, DISTRIBUTING, SUBLICENSING,
// AND/OR SELLING COPIES OF THIS SOFTWARE SHALL BE REGARDED AS BE CONSTRUED AND
// CONTROLLED BY JAPANESE LAWS, AND YOU MUST FURTHER CONSENT TO EXCLUSIVE
// JURISDICTION AND VENUE IN THE COURTS SITTING IN TOKYO, JAPAN. YOU MUST WAIVE
// ALL DEFENSES OF LACK OF PERSONAL JURISDICTION AND FORUM NON CONVENIENS.
// PROCESS MAY BE SERVED ON EITHER PARTY IN THE MANNER AUTHORIZED BY APPLICABLE
// LAW OR COURT RULE.
//
// USE ONLY IN JAPAN. DO NOT USE THIS SOFTWARE IN ANOTHER COUNTRY UNLESS YOU HAVE
// A CONFIRMATION THAT THIS SOFTWARE DOES NOT VIOLATE ANY CRIMINAL LAWS OR CIVIL
// RIGHTS IN THAT PARTICULAR COUNTRY. USING THIS SOFTWARE IN OTHER COUNTRIES IS
// COMPLETELY AT YOUR OWN RISK. THE SOFTETHER VPN PROJECT HAS DEVELOPED AND
// DISTRIBUTED THIS SOFTWARE TO COMPLY ONLY WITH THE JAPANESE LAWS AND EXISTING
// CIVIL RIGHTS INCLUDING PATENTS WHICH ARE SUBJECTS APPLY IN JAPAN. OTHER
// COUNTRIES' LAWS OR CIVIL RIGHTS ARE NONE OF OUR CONCERNS NOR RESPONSIBILITIES.
// WE HAVE NEVER INVESTIGATED ANY CRIMINAL REGULATIONS, CIVIL LAWS OR
// INTELLECTUAL PROPERTY RIGHTS INCLUDING PATENTS IN ANY OF OTHER 200+ COUNTRIES
// AND TERRITORIES. BY NATURE, THERE ARE 200+ REGIONS IN THE WORLD, WITH
// DIFFERENT LAWS. IT IS IMPOSSIBLE TO VERIFY EVERY COUNTRIES' LAWS, REGULATIONS
// AND CIVIL RIGHTS TO MAKE THE SOFTWARE COMPLY WITH ALL COUNTRIES' LAWS BY THE
// PROJECT. EVEN IF YOU WILL BE SUED BY A PRIVATE ENTITY OR BE DAMAGED BY A
// PUBLIC SERVANT IN YOUR COUNTRY, THE DEVELOPERS OF THIS SOFTWARE WILL NEVER BE
// LIABLE TO RECOVER OR COMPENSATE SUCH DAMAGES, CRIMINAL OR CIVIL
// RESPONSIBILITIES. NOTE THAT THIS LINE IS NOT LICENSE RESTRICTION BUT JUST A
// STATEMENT FOR WARNING AND DISCLAIMER.
//
// READ AND UNDERSTAND THE 'WARNING.TXT' FILE BEFORE USING THIS SOFTWARE.
// SOME SOFTWARE PROGRAMS FROM THIRD PARTIES ARE INCLUDED ON THIS SOFTWARE WITH
// LICENSE CONDITIONS WHICH ARE DESCRIBED ON THE 'THIRD_PARTY.TXT' FILE.
//
//
// SOURCE CODE CONTRIBUTION
// ------------------------
//
// Your contribution to SoftEther VPN Project is much appreciated.
// Please send patches to us through GitHub.
// Read the SoftEther VPN Patch Acceptance Policy in advance:
// http://www.softether.org/5-download/src/9.patch
//
//
// DEAR SECURITY EXPERTS
// ---------------------
//
// If you find a bug or a security vulnerability please kindly inform us
// about the problem immediately so that we can fix the security problem
// to protect a lot of users around the world as soon as possible.
//
// Our e-mail address for security reports is:
// softether-vpn-security [at] softether.org
//
// Please note that the above e-mail address is not a technical support
// inquiry address. If you need technical assistance, please visit
// http://www.softether.org/ and ask your question on the users forum.
//
// Thank you for your cooperation.
//
//
// NO MEMORY OR RESOURCE LEAKS
// ---------------------------
//
// The memory-leaks and resource-leaks verification under the stress
// test has been passed before release this source code.
using System;
using System.Threading;
using System.Text;
using System.Configuration;
using System.Collections;
using System.Collections.Generic;
using System.Collections.Specialized;
using System.Security.Cryptography;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.IO;
using System.Drawing;
using System.Drawing.Imaging;
using System.Drawing.Drawing2D;
using System.Diagnostics;
using System.Net;
using System.Net.Security;
using System.Security.Cryptography.X509Certificates;
using CoreUtil;
using BuildUtil.HvSignService;
namespace BuildUtil
{
public static class CodeSign
{
public const int NumRetries = 1;
public const int RetryIntervals = 200;
public const int NumRetriesForCopy = 50;
public const int RetryIntervalsForCopy = 10;
const string in_dir = @"\\hvsigncode\SIGN\IN";
const string out_dir = @"\\hvsigncode\SIGN\OUT";
#if !BU_SOFTETHER
public static int UsingCertId = 1;
#else
public static int UsingCertId = 2;
#endif
static object lockObj = new object();
// Digital-sign the data on the memory
public static byte[] SignMemory(byte[] srcData, string comment, bool kernelModeDriver, int cert_id, int sha_mode)
{
#if !BU_OSS
int i;
string out_filename = null;
byte[] ret = null;
string in_tmp_filename = Path.Combine(in_dir,
Str.DateTimeToStrShortWithMilliSecs(DateTime.Now) + "_" +
Env.MachineName + "_" +
Secure.Rand63i().ToString() + ".dat");
IO.SaveFile(in_tmp_filename, srcData);
for (i = 0; i < NumRetries; i++)
{
Sign sign = new Sign();
sign.Proxy = new WebProxy();
try
{
out_filename = sign.ExecSignEx(Path.GetFileName(in_tmp_filename),
kernelModeDriver,
comment,
cert_id,
sha_mode);
break;
}
catch (Exception ex)
{
if (i != (NumRetries - 1))
{
Kernel.SleepThread(RetryIntervals);
}
else
{
throw ex;
}
}
}
for (i = 0; i < NumRetriesForCopy; i++)
{
try
{
ret = IO.ReadFile(Path.Combine(out_dir, out_filename));
}
catch (Exception ex)
{
if (i != (NumRetriesForCopy - 1))
{
Kernel.SleepThread(RetryIntervalsForCopy);
}
else
{
throw ex;
}
}
}
string tmpFileName = IO.CreateTempFileNameByExt(".exe");
try
{
File.Delete(tmpFileName);
}
catch
{
}
File.WriteAllBytes(tmpFileName, ret);
lock (lockObj)
{
if (ExeSignChecker.CheckFileDigitalSignature(tmpFileName) == false)
{
throw new ApplicationException("CheckFileDigitalSignature failed.");
}
if (kernelModeDriver)
{
if (ExeSignChecker.IsKernelModeSignedFile(tmpFileName) == false)
{
throw new ApplicationException("IsKernelModeSignedFile failed.");
}
}
}
try
{
}
catch
{
File.Delete(tmpFileName);
}
return ret;
#else // BU_OSS
return srcData;
#endif // BU_OSS
}
// Digital-sign the data on the file
public static void SignFile(string destFileName, string srcFileName, string comment, bool kernelModeDriver)
{
int cert_id = UsingCertId;
SignFile(destFileName, srcFileName, comment, kernelModeDriver, cert_id, 0);
}
public static void SignFile(string destFileName, string srcFileName, string comment, bool kernelModeDriver, int cert_id, int sha_mode)
{
#if !BU_OSS
if (cert_id == 0)
{
cert_id = UsingCertId;
}
Con.WriteLine("Signing for '{0}'...", Path.GetFileName(destFileName));
byte[] srcData = File.ReadAllBytes(srcFileName);
if (srcFileName.EndsWith(".msi", StringComparison.InvariantCultureIgnoreCase))
{
sha_mode = 1;
// todo: Set 2 in future !!!
}
byte[] destData = SignMemory(srcData, comment, kernelModeDriver, cert_id, sha_mode);
try
{
File.Delete(destFileName);
}
catch
{
}
File.WriteAllBytes(destFileName, destData);
Con.WriteLine("Done.");
#else // BU_OSS
Con.WriteLine("Skipping the code signing for '{0}' in the build process. You can insert your own authenticode sign process here.", srcFileName);
#endif // BU_OSS
}
}
}

View File

@ -1,2 +0,0 @@
copy %0\..\..\bin\BuildUtilTmp.exe %0\..\..\bin\BuildUtil.exe
exit /b 0

View File

@ -1,203 +0,0 @@
// CoreUtil
//
// Copyright (C) 2012-2014 Daiyuu Nobori. All Rights Reserved.
// Copyright (C) 2012-2014 SoftEther VPN Project at University of Tsukuba. All Rights Reserved.
//
// License: The Apache License, Version 2.0
// https://www.apache.org/licenses/LICENSE-2.0
//
// DISCLAIMER
// ==========
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
// SOFTWARE.
//
// THIS SOFTWARE IS DEVELOPED IN JAPAN, AND DISTRIBUTED FROM JAPAN, UNDER
// JAPANESE LAWS. YOU MUST AGREE IN ADVANCE TO USE, COPY, MODIFY, MERGE, PUBLISH,
// DISTRIBUTE, SUBLICENSE, AND/OR SELL COPIES OF THIS SOFTWARE, THAT ANY
// JURIDICAL DISPUTES WHICH ARE CONCERNED TO THIS SOFTWARE OR ITS CONTENTS,
// AGAINST US (SOFTETHER PROJECT, SOFTETHER CORPORATION, DAIYUU NOBORI OR OTHER
// SUPPLIERS), OR ANY JURIDICAL DISPUTES AGAINST US WHICH ARE CAUSED BY ANY KIND
// OF USING, COPYING, MODIFYING, MERGING, PUBLISHING, DISTRIBUTING, SUBLICENSING,
// AND/OR SELLING COPIES OF THIS SOFTWARE SHALL BE REGARDED AS BE CONSTRUED AND
// CONTROLLED BY JAPANESE LAWS, AND YOU MUST FURTHER CONSENT TO EXCLUSIVE
// JURISDICTION AND VENUE IN THE COURTS SITTING IN TOKYO, JAPAN. YOU MUST WAIVE
// ALL DEFENSES OF LACK OF PERSONAL JURISDICTION AND FORUM NON CONVENIENS.
// PROCESS MAY BE SERVED ON EITHER PARTY IN THE MANNER AUTHORIZED BY APPLICABLE
// LAW OR COURT RULE.
//
// USE ONLY IN JAPAN. DO NOT USE THIS SOFTWARE IN ANOTHER COUNTRY UNLESS YOU HAVE
// A CONFIRMATION THAT THIS SOFTWARE DOES NOT VIOLATE ANY CRIMINAL LAWS OR CIVIL
// RIGHTS IN THAT PARTICULAR COUNTRY. USING THIS SOFTWARE IN OTHER COUNTRIES IS
// COMPLETELY AT YOUR OWN RISK. THE SOFTETHER VPN PROJECT HAS DEVELOPED AND
// DISTRIBUTED THIS SOFTWARE TO COMPLY ONLY WITH THE JAPANESE LAWS AND EXISTING
// CIVIL RIGHTS INCLUDING PATENTS WHICH ARE SUBJECTS APPLY IN JAPAN. OTHER
// COUNTRIES' LAWS OR CIVIL RIGHTS ARE NONE OF OUR CONCERNS NOR RESPONSIBILITIES.
// WE HAVE NEVER INVESTIGATED ANY CRIMINAL REGULATIONS, CIVIL LAWS OR
// INTELLECTUAL PROPERTY RIGHTS INCLUDING PATENTS IN ANY OF OTHER 200+ COUNTRIES
// AND TERRITORIES. BY NATURE, THERE ARE 200+ REGIONS IN THE WORLD, WITH
// DIFFERENT LAWS. IT IS IMPOSSIBLE TO VERIFY EVERY COUNTRIES' LAWS, REGULATIONS
// AND CIVIL RIGHTS TO MAKE THE SOFTWARE COMPLY WITH ALL COUNTRIES' LAWS BY THE
// PROJECT. EVEN IF YOU WILL BE SUED BY A PRIVATE ENTITY OR BE DAMAGED BY A
// PUBLIC SERVANT IN YOUR COUNTRY, THE DEVELOPERS OF THIS SOFTWARE WILL NEVER BE
// LIABLE TO RECOVER OR COMPENSATE SUCH DAMAGES, CRIMINAL OR CIVIL
// RESPONSIBILITIES. NOTE THAT THIS LINE IS NOT LICENSE RESTRICTION BUT JUST A
// STATEMENT FOR WARNING AND DISCLAIMER.
//
// READ AND UNDERSTAND THE 'WARNING.TXT' FILE BEFORE USING THIS SOFTWARE.
// SOME SOFTWARE PROGRAMS FROM THIRD PARTIES ARE INCLUDED ON THIS SOFTWARE WITH
// LICENSE CONDITIONS WHICH ARE DESCRIBED ON THE 'THIRD_PARTY.TXT' FILE.
//
//
// SOURCE CODE CONTRIBUTION
// ------------------------
//
// Your contribution to SoftEther VPN Project is much appreciated.
// Please send patches to us through GitHub.
// Read the SoftEther VPN Patch Acceptance Policy in advance:
// http://www.softether.org/5-download/src/9.patch
//
//
// DEAR SECURITY EXPERTS
// ---------------------
//
// If you find a bug or a security vulnerability please kindly inform us
// about the problem immediately so that we can fix the security problem
// to protect a lot of users around the world as soon as possible.
//
// Our e-mail address for security reports is:
// softether-vpn-security [at] softether.org
//
// Please note that the above e-mail address is not a technical support
// inquiry address. If you need technical assistance, please visit
// http://www.softether.org/ and ask your question on the users forum.
//
// Thank you for your cooperation.
//
//
// NO MEMORY OR RESOURCE LEAKS
// ---------------------------
//
// The memory-leaks and resource-leaks verification under the stress
// test has been passed before release this source code.
using System;
using System.Threading;
using System.Data;
using System.Data.Sql;
using System.Data.SqlClient;
using System.Data.SqlTypes;
using System.Text;
using System.Configuration;
using System.Collections;
using System.Collections.Generic;
using System.Security.Cryptography;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.IO;
using System.Drawing;
using System.Drawing.Imaging;
using System.Drawing.Drawing2D;
using System.Diagnostics;
using System.Web.Mail;
using System.Net;
using System.Net.Sockets;
using System.Net.NetworkInformation;
using System.Runtime.InteropServices;
namespace CoreUtil
{
public static class Bmp
{
public static Bitmap Load(string filename)
{
return Load(IO.ReadFile(filename));
}
public static Bitmap Load(byte[] data)
{
MemoryStream ms = new MemoryStream();
ms.Write(data, 0, data.Length);
ms.Seek(0, SeekOrigin.Begin);
return new Bitmap(ms);
}
public static void SaveAsBitmap(Bitmap bmp, string filename)
{
IO.SaveFile(filename, SaveAsBitmap(bmp));
}
public static byte[] SaveAsBitmap(Bitmap bmp)
{
MemoryStream ms = new MemoryStream();
bmp.Save(ms, ImageFormat.Bmp);
return ms.ToArray();
}
public static void SaveAsJpeg(Bitmap bmp, string filename)
{
IO.SaveFile(filename, SaveAsJpeg(bmp));
}
public static byte[] SaveAsJpeg(Bitmap bmp)
{
return SaveAsJpeg(bmp, 100);
}
public static void SaveAsJpeg(Bitmap bmp, string filename, int quality)
{
IO.SaveFile(filename, SaveAsJpeg(bmp, quality));
}
public static byte[] SaveAsJpeg(Bitmap bmp, int quality)
{
EncoderParameters eps = new EncoderParameters(1);
EncoderParameter ep = new EncoderParameter(System.Drawing.Imaging.Encoder.Quality, quality);
eps.Param[0] = ep;
ImageCodecInfo info = getEncoderInfo("image/jpeg");
MemoryStream ms = new MemoryStream();
bmp.Save(ms, info, eps);
return ms.ToArray();
}
static ImageCodecInfo getEncoderInfo(string type)
{
ImageCodecInfo[] encs = ImageCodecInfo.GetImageEncoders();
foreach (ImageCodecInfo enc in encs)
{
if (Str.StrCmpi(enc.MimeType, type))
{
return enc;
}
}
return null;
}
public static Bitmap ResizeBitmap(Bitmap bmp, int width, int height)
{
Bitmap dst = new Bitmap(width, height, PixelFormat.Format24bppRgb);
Graphics g = Graphics.FromImage(dst);
g.SmoothingMode = SmoothingMode.HighQuality;
g.InterpolationMode = InterpolationMode.HighQualityBicubic;
Rectangle r = new Rectangle(0, 0, width, height);
g.DrawImage(bmp, r);
return dst;
}
}
}

View File

@ -1,688 +0,0 @@
// CoreUtil
//
// Copyright (C) 2012-2014 Daiyuu Nobori. All Rights Reserved.
// Copyright (C) 2012-2014 SoftEther VPN Project at University of Tsukuba. All Rights Reserved.
//
// License: The Apache License, Version 2.0
// https://www.apache.org/licenses/LICENSE-2.0
//
// DISCLAIMER
// ==========
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
// SOFTWARE.
//
// THIS SOFTWARE IS DEVELOPED IN JAPAN, AND DISTRIBUTED FROM JAPAN, UNDER
// JAPANESE LAWS. YOU MUST AGREE IN ADVANCE TO USE, COPY, MODIFY, MERGE, PUBLISH,
// DISTRIBUTE, SUBLICENSE, AND/OR SELL COPIES OF THIS SOFTWARE, THAT ANY
// JURIDICAL DISPUTES WHICH ARE CONCERNED TO THIS SOFTWARE OR ITS CONTENTS,
// AGAINST US (SOFTETHER PROJECT, SOFTETHER CORPORATION, DAIYUU NOBORI OR OTHER
// SUPPLIERS), OR ANY JURIDICAL DISPUTES AGAINST US WHICH ARE CAUSED BY ANY KIND
// OF USING, COPYING, MODIFYING, MERGING, PUBLISHING, DISTRIBUTING, SUBLICENSING,
// AND/OR SELLING COPIES OF THIS SOFTWARE SHALL BE REGARDED AS BE CONSTRUED AND
// CONTROLLED BY JAPANESE LAWS, AND YOU MUST FURTHER CONSENT TO EXCLUSIVE
// JURISDICTION AND VENUE IN THE COURTS SITTING IN TOKYO, JAPAN. YOU MUST WAIVE
// ALL DEFENSES OF LACK OF PERSONAL JURISDICTION AND FORUM NON CONVENIENS.
// PROCESS MAY BE SERVED ON EITHER PARTY IN THE MANNER AUTHORIZED BY APPLICABLE
// LAW OR COURT RULE.
//
// USE ONLY IN JAPAN. DO NOT USE THIS SOFTWARE IN ANOTHER COUNTRY UNLESS YOU HAVE
// A CONFIRMATION THAT THIS SOFTWARE DOES NOT VIOLATE ANY CRIMINAL LAWS OR CIVIL
// RIGHTS IN THAT PARTICULAR COUNTRY. USING THIS SOFTWARE IN OTHER COUNTRIES IS
// COMPLETELY AT YOUR OWN RISK. THE SOFTETHER VPN PROJECT HAS DEVELOPED AND
// DISTRIBUTED THIS SOFTWARE TO COMPLY ONLY WITH THE JAPANESE LAWS AND EXISTING
// CIVIL RIGHTS INCLUDING PATENTS WHICH ARE SUBJECTS APPLY IN JAPAN. OTHER
// COUNTRIES' LAWS OR CIVIL RIGHTS ARE NONE OF OUR CONCERNS NOR RESPONSIBILITIES.
// WE HAVE NEVER INVESTIGATED ANY CRIMINAL REGULATIONS, CIVIL LAWS OR
// INTELLECTUAL PROPERTY RIGHTS INCLUDING PATENTS IN ANY OF OTHER 200+ COUNTRIES
// AND TERRITORIES. BY NATURE, THERE ARE 200+ REGIONS IN THE WORLD, WITH
// DIFFERENT LAWS. IT IS IMPOSSIBLE TO VERIFY EVERY COUNTRIES' LAWS, REGULATIONS
// AND CIVIL RIGHTS TO MAKE THE SOFTWARE COMPLY WITH ALL COUNTRIES' LAWS BY THE
// PROJECT. EVEN IF YOU WILL BE SUED BY A PRIVATE ENTITY OR BE DAMAGED BY A
// PUBLIC SERVANT IN YOUR COUNTRY, THE DEVELOPERS OF THIS SOFTWARE WILL NEVER BE
// LIABLE TO RECOVER OR COMPENSATE SUCH DAMAGES, CRIMINAL OR CIVIL
// RESPONSIBILITIES. NOTE THAT THIS LINE IS NOT LICENSE RESTRICTION BUT JUST A
// STATEMENT FOR WARNING AND DISCLAIMER.
//
// READ AND UNDERSTAND THE 'WARNING.TXT' FILE BEFORE USING THIS SOFTWARE.
// SOME SOFTWARE PROGRAMS FROM THIRD PARTIES ARE INCLUDED ON THIS SOFTWARE WITH
// LICENSE CONDITIONS WHICH ARE DESCRIBED ON THE 'THIRD_PARTY.TXT' FILE.
//
//
// SOURCE CODE CONTRIBUTION
// ------------------------
//
// Your contribution to SoftEther VPN Project is much appreciated.
// Please send patches to us through GitHub.
// Read the SoftEther VPN Patch Acceptance Policy in advance:
// http://www.softether.org/5-download/src/9.patch
//
//
// DEAR SECURITY EXPERTS
// ---------------------
//
// If you find a bug or a security vulnerability please kindly inform us
// about the problem immediately so that we can fix the security problem
// to protect a lot of users around the world as soon as possible.
//
// Our e-mail address for security reports is:
// softether-vpn-security [at] softether.org
//
// Please note that the above e-mail address is not a technical support
// inquiry address. If you need technical assistance, please visit
// http://www.softether.org/ and ask your question on the users forum.
//
// Thank you for your cooperation.
//
//
// NO MEMORY OR RESOURCE LEAKS
// ---------------------------
//
// The memory-leaks and resource-leaks verification under the stress
// test has been passed before release this source code.
using System;
using System.Threading;
using System.Data;
using System.Data.Sql;
using System.Data.SqlClient;
using System.Data.SqlTypes;
using System.Text;
using System.Configuration;
using System.Collections;
using System.Collections.Generic;
using System.Security.Cryptography;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.IO;
using System.Drawing;
using System.Drawing.Imaging;
using System.Drawing.Drawing2D;
using System.Web.Mail;
namespace CoreUtil
{
// FIFO
public class Fifo
{
byte[] p;
int pos, size;
public int Size
{
get { return size; }
}
public byte[] Data
{
get
{
return this.p;
}
}
public int DataOffset
{
get
{
return this.pos;
}
}
public int PhysicalSize
{
get
{
return p.Length;
}
}
int reallocMemSize;
public const int FifoInitMemSize = 4096;
public const int FifoReallocMemSize = 65536;
public const int FifoReallocMemSizeSmall = 65536;
long totalWriteSize = 0, totalReadSize = 0;
public long TotalReadSize
{
get { return totalReadSize; }
}
public long TotalWriteSize
{
get { return totalWriteSize; }
}
public Fifo()
{
init(0);
}
public Fifo(int reallocMemSize)
{
init(reallocMemSize);
}
void init(int reallocMemSize)
{
if (reallocMemSize == 0)
{
reallocMemSize = FifoReallocMemSize;
}
this.size = this.pos = 0;
this.reallocMemSize = reallocMemSize;
this.p = new byte[FifoInitMemSize];
}
public void Write(Buf buf)
{
Write(buf.ByteData);
}
public void Write(byte[] src)
{
Write(src, src.Length);
}
public void SkipWrite(int size)
{
Write(null, size);
}
public void Write(byte[] src, int size)
{
Write(src, 0, size);
}
public void Write(byte[] src, int offset, int size)
{
int i, need_size;
bool realloc_flag;
i = this.size;
this.size += size;
need_size = this.pos + this.size;
realloc_flag = false;
int memsize = p.Length;
while (need_size > memsize)
{
memsize = Math.Max(memsize, FifoInitMemSize) * 3;
realloc_flag = true;
}
if (realloc_flag)
{
byte[] new_p = new byte[memsize];
Util.CopyByte(new_p, 0, this.p, 0, this.p.Length);
this.p = new_p;
}
if (src != null)
{
Util.CopyByte(this.p, this.pos + i, src, offset, size);
}
totalWriteSize += size;
}
public byte[] Read()
{
return Read(this.Size);
}
public void ReadToBuf(Buf buf, int size)
{
byte[] data = Read(size);
buf.Write(data);
}
public Buf ReadToBuf(int size)
{
byte[] data = Read(size);
return new Buf(data);
}
public byte[] Read(int size)
{
byte[] ret = new byte[size];
int read_size = Read(ret);
Array.Resize<byte>(ref ret, read_size);
return ret;
}
public int Read(byte[] dst)
{
return Read(dst, dst.Length);
}
public int SkipRead(int size)
{
return Read(null, size);
}
public int Read(byte[] dst, int size)
{
return Read(dst, 0, size);
}
public int Read(byte[] dst, int offset, int size)
{
int read_size;
read_size = Math.Min(size, this.size);
if (read_size == 0)
{
return 0;
}
if (dst != null)
{
Util.CopyByte(dst, offset, this.p, this.pos, size);
}
this.pos += read_size;
this.size -= read_size;
if (this.size == 0)
{
this.pos = 0;
}
if (this.pos >= FifoInitMemSize &&
this.p.Length >= this.reallocMemSize &&
(this.p.Length / 2) > this.size)
{
byte[] new_p;
int new_size;
new_size = Math.Max(this.p.Length / 2, FifoInitMemSize);
new_p = new byte[new_size];
Util.CopyByte(new_p, 0, this.p, this.pos, this.size);
this.p = new_p;
this.pos = 0;
}
totalReadSize += read_size;
return read_size;
}
}
public class Buf
{
MemoryStream buf;
public Buf()
{
init(new byte[0]);
}
public Buf(byte[] data)
{
init(data);
}
void init(byte[] data)
{
buf = new MemoryStream();
Write(data);
SeekToBegin();
}
public void Clear()
{
buf.SetLength(0);
}
public void WriteByte(byte data)
{
byte[] a = new byte[1] { data };
Write(a);
}
public void Write(byte[] data)
{
buf.Write(data, 0, data.Length);
}
public void Write(byte[] data, int pos, int len)
{
buf.Write(data, pos, len);
}
public uint Size
{
get
{
return (uint)buf.Length;
}
}
public uint Pos
{
get
{
return (uint)buf.Position;
}
}
public byte[] ByteData
{
get
{
return buf.ToArray();
}
}
public byte this[uint i]
{
get
{
return buf.GetBuffer()[i];
}
set
{
buf.GetBuffer()[i] = value;
}
}
public byte[] Read()
{
return Read(this.Size);
}
public byte[] Read(uint size)
{
byte[] tmp = new byte[size];
int i = buf.Read(tmp, 0, (int)size);
byte[] ret = new byte[i];
Array.Copy(tmp, 0, ret, 0, i);
return ret;
}
public byte ReadByte()
{
byte[] a = Read(1);
return a[0];
}
public void SeekToBegin()
{
Seek(0);
}
public void SeekToEnd()
{
Seek(0, SeekOrigin.End);
}
public void Seek(uint offset)
{
Seek(offset, SeekOrigin.Begin);
}
public void Seek(uint offset, SeekOrigin mode)
{
buf.Seek(offset, mode);
}
public ushort ReadShort()
{
byte[] data = Read(2);
if (data.Length != 2)
{
return 0;
}
if (Env.IsLittleEndian)
{
Array.Reverse(data);
}
return BitConverter.ToUInt16(data, 0);
}
public ushort RawReadShort()
{
byte[] data = Read(2);
if (data.Length != 2)
{
return 0;
}
return BitConverter.ToUInt16(data, 0);
}
public uint ReadInt()
{
byte[] data = Read(4);
if (data.Length != 4)
{
return 0;
}
if (Env.IsLittleEndian)
{
Array.Reverse(data);
}
return BitConverter.ToUInt32(data, 0);
}
public uint RawReadInt()
{
byte[] data = Read(4);
if (data.Length != 4)
{
return 0;
}
return BitConverter.ToUInt32(data, 0);
}
public ulong ReadInt64()
{
byte[] data = Read(8);
if (data.Length != 8)
{
return 0;
}
if (Env.IsLittleEndian)
{
Array.Reverse(data);
}
return BitConverter.ToUInt64(data, 0);
}
public ulong RawReadInt64()
{
byte[] data = Read(8);
if (data.Length != 8)
{
return 0;
}
return BitConverter.ToUInt64(data, 0);
}
public string ReadStr()
{
return ReadStr(false);
}
public string ReadStr(bool include_null)
{
uint len = ReadInt();
byte[] data = Read(len - (uint)(include_null ? 1 : 0));
return Str.ShiftJisEncoding.GetString(data);
}
public string ReadUniStr()
{
return ReadUniStr(false);
}
public string ReadUniStr(bool include_null)
{
uint len = ReadInt();
if (len == 0)
{
return null;
}
byte[] data = Read(len - (uint)(include_null ? 2 : 0));
return Str.Utf8Encoding.GetString(data);
}
public void WriteShort(ushort shortValue)
{
byte[] data = BitConverter.GetBytes(shortValue);
if (Env.IsLittleEndian)
{
Array.Reverse(data);
}
Write(data);
}
public void RawWriteShort(ushort shortValue)
{
byte[] data = BitConverter.GetBytes(shortValue);
Write(data);
}
public void WriteInt(uint intValue)
{
byte[] data = BitConverter.GetBytes(intValue);
if (Env.IsLittleEndian)
{
Array.Reverse(data);
}
Write(data);
}
public void RawWriteInt(uint intValue)
{
byte[] data = BitConverter.GetBytes(intValue);
Write(data);
}
public void WriteInt64(ulong int64Value)
{
byte[] data = BitConverter.GetBytes(int64Value);
if (Env.IsLittleEndian)
{
Array.Reverse(data);
}
Write(data);
}
public void RawWriteInt64(ulong int64Value)
{
byte[] data = BitConverter.GetBytes(int64Value);
Write(data);
}
public string ReadNextLineAsString()
{
return ReadNextLineAsString(Str.Utf8Encoding);
}
public string ReadNextLineAsString(Encoding encoding)
{
byte[] ret = ReadNextLineAsData();
if (ret == null)
{
return null;
}
return encoding.GetString(ret);
}
public byte[] ReadNextLineAsData()
{
if (this.Size <= this.Pos)
{
return null;
}
long pos = buf.Position;
long i;
byte[] tmp = new byte[1];
for (i = pos; i < buf.Length; i++)
{
buf.Read(tmp, 0, 1);
if (tmp[0] == 13 || tmp[0] == 10)
{
if (tmp[0] == 13)
{
if ((i + 2) < buf.Length)
{
i++;
}
}
break;
}
}
long len = i - pos;
buf.Position = pos;
byte[] ret = Read((uint)((int)len));
try
{
Seek(1, SeekOrigin.Current);
}
catch
{
}
if (ret.Length >= 1 && ret[ret.Length - 1] == 13)
{
Array.Resize<byte>(ref ret, ret.Length - 1);
}
return ret;
}
public void WriteStr(string strValue)
{
WriteStr(strValue, false);
}
public void WriteStr(string strValue, bool include_null)
{
byte[] data = Str.ShiftJisEncoding.GetBytes(strValue);
WriteInt((uint)data.Length + (uint)(include_null ? 1 : 0));
Write(data);
}
public void WriteUniStr(string strValue)
{
WriteUniStr(strValue, false);
}
public void WriteUniStr(string strValue, bool include_null)
{
byte[] data = Str.Utf8Encoding.GetBytes(strValue);
WriteInt((uint)data.Length + (uint)(include_null ? 2 : 0));
Write(data);
}
public static Buf ReadFromFile(string filename)
{
return new Buf(IO.ReadFile(filename));
}
public void WriteToFile(string filename)
{
IO.SaveFile(filename, this.ByteData);
}
public static Buf ReadFromStream(Stream st)
{
Buf ret = new Buf();
int size = 32767;
while (true)
{
byte[] tmp = new byte[size];
int i = st.Read(tmp, 0, tmp.Length);
if (i <= 0)
{
break;
}
Array.Resize<byte>(ref tmp, i);
ret.Write(tmp);
}
ret.SeekToBegin();
return ret;
}
}
}

View File

@ -1,335 +0,0 @@
// CoreUtil
//
// Copyright (C) 2012-2014 Daiyuu Nobori. All Rights Reserved.
// Copyright (C) 2012-2014 SoftEther VPN Project at University of Tsukuba. All Rights Reserved.
//
// License: The Apache License, Version 2.0
// https://www.apache.org/licenses/LICENSE-2.0
//
// DISCLAIMER
// ==========
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
// SOFTWARE.
//
// THIS SOFTWARE IS DEVELOPED IN JAPAN, AND DISTRIBUTED FROM JAPAN, UNDER
// JAPANESE LAWS. YOU MUST AGREE IN ADVANCE TO USE, COPY, MODIFY, MERGE, PUBLISH,
// DISTRIBUTE, SUBLICENSE, AND/OR SELL COPIES OF THIS SOFTWARE, THAT ANY
// JURIDICAL DISPUTES WHICH ARE CONCERNED TO THIS SOFTWARE OR ITS CONTENTS,
// AGAINST US (SOFTETHER PROJECT, SOFTETHER CORPORATION, DAIYUU NOBORI OR OTHER
// SUPPLIERS), OR ANY JURIDICAL DISPUTES AGAINST US WHICH ARE CAUSED BY ANY KIND
// OF USING, COPYING, MODIFYING, MERGING, PUBLISHING, DISTRIBUTING, SUBLICENSING,
// AND/OR SELLING COPIES OF THIS SOFTWARE SHALL BE REGARDED AS BE CONSTRUED AND
// CONTROLLED BY JAPANESE LAWS, AND YOU MUST FURTHER CONSENT TO EXCLUSIVE
// JURISDICTION AND VENUE IN THE COURTS SITTING IN TOKYO, JAPAN. YOU MUST WAIVE
// ALL DEFENSES OF LACK OF PERSONAL JURISDICTION AND FORUM NON CONVENIENS.
// PROCESS MAY BE SERVED ON EITHER PARTY IN THE MANNER AUTHORIZED BY APPLICABLE
// LAW OR COURT RULE.
//
// USE ONLY IN JAPAN. DO NOT USE THIS SOFTWARE IN ANOTHER COUNTRY UNLESS YOU HAVE
// A CONFIRMATION THAT THIS SOFTWARE DOES NOT VIOLATE ANY CRIMINAL LAWS OR CIVIL
// RIGHTS IN THAT PARTICULAR COUNTRY. USING THIS SOFTWARE IN OTHER COUNTRIES IS
// COMPLETELY AT YOUR OWN RISK. THE SOFTETHER VPN PROJECT HAS DEVELOPED AND
// DISTRIBUTED THIS SOFTWARE TO COMPLY ONLY WITH THE JAPANESE LAWS AND EXISTING
// CIVIL RIGHTS INCLUDING PATENTS WHICH ARE SUBJECTS APPLY IN JAPAN. OTHER
// COUNTRIES' LAWS OR CIVIL RIGHTS ARE NONE OF OUR CONCERNS NOR RESPONSIBILITIES.
// WE HAVE NEVER INVESTIGATED ANY CRIMINAL REGULATIONS, CIVIL LAWS OR
// INTELLECTUAL PROPERTY RIGHTS INCLUDING PATENTS IN ANY OF OTHER 200+ COUNTRIES
// AND TERRITORIES. BY NATURE, THERE ARE 200+ REGIONS IN THE WORLD, WITH
// DIFFERENT LAWS. IT IS IMPOSSIBLE TO VERIFY EVERY COUNTRIES' LAWS, REGULATIONS
// AND CIVIL RIGHTS TO MAKE THE SOFTWARE COMPLY WITH ALL COUNTRIES' LAWS BY THE
// PROJECT. EVEN IF YOU WILL BE SUED BY A PRIVATE ENTITY OR BE DAMAGED BY A
// PUBLIC SERVANT IN YOUR COUNTRY, THE DEVELOPERS OF THIS SOFTWARE WILL NEVER BE
// LIABLE TO RECOVER OR COMPENSATE SUCH DAMAGES, CRIMINAL OR CIVIL
// RESPONSIBILITIES. NOTE THAT THIS LINE IS NOT LICENSE RESTRICTION BUT JUST A
// STATEMENT FOR WARNING AND DISCLAIMER.
//
// READ AND UNDERSTAND THE 'WARNING.TXT' FILE BEFORE USING THIS SOFTWARE.
// SOME SOFTWARE PROGRAMS FROM THIRD PARTIES ARE INCLUDED ON THIS SOFTWARE WITH
// LICENSE CONDITIONS WHICH ARE DESCRIBED ON THE 'THIRD_PARTY.TXT' FILE.
//
//
// SOURCE CODE CONTRIBUTION
// ------------------------
//
// Your contribution to SoftEther VPN Project is much appreciated.
// Please send patches to us through GitHub.
// Read the SoftEther VPN Patch Acceptance Policy in advance:
// http://www.softether.org/5-download/src/9.patch
//
//
// DEAR SECURITY EXPERTS
// ---------------------
//
// If you find a bug or a security vulnerability please kindly inform us
// about the problem immediately so that we can fix the security problem
// to protect a lot of users around the world as soon as possible.
//
// Our e-mail address for security reports is:
// softether-vpn-security [at] softether.org
//
// Please note that the above e-mail address is not a technical support
// inquiry address. If you need technical assistance, please visit
// http://www.softether.org/ and ask your question on the users forum.
//
// Thank you for your cooperation.
//
//
// NO MEMORY OR RESOURCE LEAKS
// ---------------------------
//
// The memory-leaks and resource-leaks verification under the stress
// test has been passed before release this source code.
using System;
using System.Threading;
using System.Data;
using System.Data.Sql;
using System.Data.SqlClient;
using System.Data.SqlTypes;
using System.Text;
using System.Configuration;
using System.Collections;
using System.Collections.Generic;
using System.Security.Cryptography;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.IO;
using System.Drawing;
using System.Drawing.Imaging;
using System.Drawing.Drawing2D;
using System.Diagnostics;
using System.Web.Mail;
using System.Net;
using System.Net.Sockets;
using System.Net.NetworkInformation;
namespace CoreUtil
{
public enum CacheType
{
UpdateExpiresWhenAccess = 0,
DoNotUpdateExpiresWhenAccess = 1,
}
public class Cache<TKey, TValue>
{
class Entry
{
DateTime createdDateTime;
public DateTime CreatedDateTime
{
get { return createdDateTime; }
}
DateTime updatedDateTime;
public DateTime UpdatedDateTime
{
get { return updatedDateTime; }
}
DateTime lastAccessedDateTime;
public DateTime LastAccessedDateTime
{
get { return lastAccessedDateTime; }
}
TKey key;
public TKey Key
{
get
{
return key;
}
}
TValue value;
public TValue Value
{
get
{
lastAccessedDateTime = Time.NowDateTime;
return this.value;
}
set
{
this.value = value;
updatedDateTime = Time.NowDateTime;
lastAccessedDateTime = Time.NowDateTime;
}
}
public Entry(TKey key, TValue value)
{
this.key = key;
this.value = value;
lastAccessedDateTime = updatedDateTime = createdDateTime = Time.NowDateTime;
}
public override int GetHashCode()
{
return key.GetHashCode();
}
public override string ToString()
{
return key.ToString() + "," + value.ToString();
}
}
public static readonly TimeSpan DefaultExpireSpan = new TimeSpan(0, 5, 0);
public const CacheType DefaultCacheType = CacheType.UpdateExpiresWhenAccess;
TimeSpan expireSpan;
public TimeSpan ExpireSpan
{
get { return expireSpan; }
}
CacheType type;
public CacheType Type
{
get { return type; }
}
Dictionary<TKey, Entry> list;
object lockObj;
public Cache()
{
init(DefaultExpireSpan, DefaultCacheType);
}
public Cache(CacheType type)
{
init(DefaultExpireSpan, type);
}
public Cache(TimeSpan expireSpan)
{
init(expireSpan, DefaultCacheType);
}
public Cache(TimeSpan expireSpan, CacheType type)
{
init(expireSpan, type);
}
void init(TimeSpan expireSpan, CacheType type)
{
this.expireSpan = expireSpan;
this.type = type;
list = new Dictionary<TKey, Entry>();
lockObj = new object();
}
public void Add(TKey key, TValue value)
{
lock (lockObj)
{
Entry e;
deleteExpired();
if (list.ContainsKey(key) == false)
{
e = new Entry(key, value);
list.Add(e.Key, e);
deleteExpired();
}
else
{
e = list[key];
e.Value = value;
}
}
}
public void Delete(TKey key)
{
lock (lockObj)
{
if (list.ContainsKey(key))
{
list.Remove(key);
}
}
}
public TValue this[TKey key]
{
get
{
lock (lockObj)
{
deleteExpired();
if (list.ContainsKey(key) == false)
{
return default(TValue);
}
return list[key].Value;
}
}
}
static long last_deleted = 0;
void deleteExpired()
{
bool do_delete = false;
long now = Tick64.Value;
long delete_inveral = expireSpan.Milliseconds / 10;
lock (lockObj)
{
if (last_deleted == 0 || now > (last_deleted + delete_inveral))
{
last_deleted = now;
do_delete = true;
}
}
if (do_delete == false)
{
return;
}
lock (lockObj)
{
List<Entry> o = new List<Entry>();
DateTime expire = Time.NowDateTime - this.expireSpan;
foreach (Entry e in list.Values)
{
if (this.type == CacheType.UpdateExpiresWhenAccess)
{
if (e.LastAccessedDateTime < expire)
{
o.Add(e);
}
}
else
{
if (e.UpdatedDateTime < expire)
{
o.Add(e);
}
}
}
foreach (Entry e in o)
{
list.Remove(e.Key);
}
}
}
}
}

View File

@ -1,197 +0,0 @@
// CoreUtil
//
// Copyright (C) 2012-2014 Daiyuu Nobori. All Rights Reserved.
// Copyright (C) 2012-2014 SoftEther VPN Project at University of Tsukuba. All Rights Reserved.
//
// License: The Apache License, Version 2.0
// https://www.apache.org/licenses/LICENSE-2.0
//
// DISCLAIMER
// ==========
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
// SOFTWARE.
//
// THIS SOFTWARE IS DEVELOPED IN JAPAN, AND DISTRIBUTED FROM JAPAN, UNDER
// JAPANESE LAWS. YOU MUST AGREE IN ADVANCE TO USE, COPY, MODIFY, MERGE, PUBLISH,
// DISTRIBUTE, SUBLICENSE, AND/OR SELL COPIES OF THIS SOFTWARE, THAT ANY
// JURIDICAL DISPUTES WHICH ARE CONCERNED TO THIS SOFTWARE OR ITS CONTENTS,
// AGAINST US (SOFTETHER PROJECT, SOFTETHER CORPORATION, DAIYUU NOBORI OR OTHER
// SUPPLIERS), OR ANY JURIDICAL DISPUTES AGAINST US WHICH ARE CAUSED BY ANY KIND
// OF USING, COPYING, MODIFYING, MERGING, PUBLISHING, DISTRIBUTING, SUBLICENSING,
// AND/OR SELLING COPIES OF THIS SOFTWARE SHALL BE REGARDED AS BE CONSTRUED AND
// CONTROLLED BY JAPANESE LAWS, AND YOU MUST FURTHER CONSENT TO EXCLUSIVE
// JURISDICTION AND VENUE IN THE COURTS SITTING IN TOKYO, JAPAN. YOU MUST WAIVE
// ALL DEFENSES OF LACK OF PERSONAL JURISDICTION AND FORUM NON CONVENIENS.
// PROCESS MAY BE SERVED ON EITHER PARTY IN THE MANNER AUTHORIZED BY APPLICABLE
// LAW OR COURT RULE.
//
// USE ONLY IN JAPAN. DO NOT USE THIS SOFTWARE IN ANOTHER COUNTRY UNLESS YOU HAVE
// A CONFIRMATION THAT THIS SOFTWARE DOES NOT VIOLATE ANY CRIMINAL LAWS OR CIVIL
// RIGHTS IN THAT PARTICULAR COUNTRY. USING THIS SOFTWARE IN OTHER COUNTRIES IS
// COMPLETELY AT YOUR OWN RISK. THE SOFTETHER VPN PROJECT HAS DEVELOPED AND
// DISTRIBUTED THIS SOFTWARE TO COMPLY ONLY WITH THE JAPANESE LAWS AND EXISTING
// CIVIL RIGHTS INCLUDING PATENTS WHICH ARE SUBJECTS APPLY IN JAPAN. OTHER
// COUNTRIES' LAWS OR CIVIL RIGHTS ARE NONE OF OUR CONCERNS NOR RESPONSIBILITIES.
// WE HAVE NEVER INVESTIGATED ANY CRIMINAL REGULATIONS, CIVIL LAWS OR
// INTELLECTUAL PROPERTY RIGHTS INCLUDING PATENTS IN ANY OF OTHER 200+ COUNTRIES
// AND TERRITORIES. BY NATURE, THERE ARE 200+ REGIONS IN THE WORLD, WITH
// DIFFERENT LAWS. IT IS IMPOSSIBLE TO VERIFY EVERY COUNTRIES' LAWS, REGULATIONS
// AND CIVIL RIGHTS TO MAKE THE SOFTWARE COMPLY WITH ALL COUNTRIES' LAWS BY THE
// PROJECT. EVEN IF YOU WILL BE SUED BY A PRIVATE ENTITY OR BE DAMAGED BY A
// PUBLIC SERVANT IN YOUR COUNTRY, THE DEVELOPERS OF THIS SOFTWARE WILL NEVER BE
// LIABLE TO RECOVER OR COMPENSATE SUCH DAMAGES, CRIMINAL OR CIVIL
// RESPONSIBILITIES. NOTE THAT THIS LINE IS NOT LICENSE RESTRICTION BUT JUST A
// STATEMENT FOR WARNING AND DISCLAIMER.
//
// READ AND UNDERSTAND THE 'WARNING.TXT' FILE BEFORE USING THIS SOFTWARE.
// SOME SOFTWARE PROGRAMS FROM THIRD PARTIES ARE INCLUDED ON THIS SOFTWARE WITH
// LICENSE CONDITIONS WHICH ARE DESCRIBED ON THE 'THIRD_PARTY.TXT' FILE.
//
//
// SOURCE CODE CONTRIBUTION
// ------------------------
//
// Your contribution to SoftEther VPN Project is much appreciated.
// Please send patches to us through GitHub.
// Read the SoftEther VPN Patch Acceptance Policy in advance:
// http://www.softether.org/5-download/src/9.patch
//
//
// DEAR SECURITY EXPERTS
// ---------------------
//
// If you find a bug or a security vulnerability please kindly inform us
// about the problem immediately so that we can fix the security problem
// to protect a lot of users around the world as soon as possible.
//
// Our e-mail address for security reports is:
// softether-vpn-security [at] softether.org
//
// Please note that the above e-mail address is not a technical support
// inquiry address. If you need technical assistance, please visit
// http://www.softether.org/ and ask your question on the users forum.
//
// Thank you for your cooperation.
//
//
// NO MEMORY OR RESOURCE LEAKS
// ---------------------------
//
// The memory-leaks and resource-leaks verification under the stress
// test has been passed before release this source code.
using System;
using System.Threading;
using System.Data;
using System.Data.Sql;
using System.Data.SqlClient;
using System.Data.SqlTypes;
using System.Text;
using System.Configuration;
using System.Collections;
using System.Collections.Generic;
using System.Security.Cryptography;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.IO;
using System.Drawing;
using System.Drawing.Imaging;
using System.Drawing.Drawing2D;
using System.Web.Mail;
using CoreUtil.Internal;
namespace CoreUtil
{
public static class ZLib
{
public static byte[] Compress(byte[] src)
{
return Compress(src, zlibConst.Z_DEFAULT_COMPRESSION);
}
public static byte[] Compress(byte[] src, int level)
{
return Compress(src, level, false);
}
public static byte[] Compress(byte[] src, int level, bool noHeader)
{
int dstSize = src.Length * 2 + 100;
byte[] dst = new byte[dstSize];
compress2(ref dst, src, level, noHeader);
return dst;
}
public static byte[] Uncompress(byte[] src, int originalSize)
{
byte[] dst = new byte[originalSize];
uncompress(ref dst, src);
return dst;
}
static void compress2(ref byte[] dest, byte[] src, int level, bool noHeader)
{
ZStream stream = new ZStream();
stream.next_in = src;
stream.avail_in = src.Length;
stream.next_out = dest;
stream.avail_out = dest.Length;
if (noHeader == false)
{
stream.deflateInit(level);
}
else
{
stream.deflateInit(level, -15);
}
stream.deflate(zlibConst.Z_FINISH);
Array.Resize<byte>(ref dest, (int)stream.total_out);
}
static void uncompress(ref byte[] dest, byte[] src)
{
ZStream stream = new ZStream();
stream.next_in = src;
stream.avail_in = src.Length;
stream.next_out = dest;
stream.avail_out = dest.Length;
stream.inflateInit();
int err = stream.inflate(zlibConst.Z_FINISH);
if (err != zlibConst.Z_STREAM_END)
{
stream.inflateEnd();
throw new ApplicationException();
}
Array.Resize<byte>(ref dest, (int)stream.total_out);
err = stream.inflateEnd();
if (err != zlibConst.Z_OK)
{
throw new ApplicationException();
}
}
}
}

File diff suppressed because it is too large Load Diff

View File

@ -1,512 +0,0 @@
// CoreUtil
//
// Copyright (C) 2012-2014 Daiyuu Nobori. All Rights Reserved.
// Copyright (C) 2012-2014 SoftEther VPN Project at University of Tsukuba. All Rights Reserved.
//
// License: The Apache License, Version 2.0
// https://www.apache.org/licenses/LICENSE-2.0
//
// DISCLAIMER
// ==========
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
// SOFTWARE.
//
// THIS SOFTWARE IS DEVELOPED IN JAPAN, AND DISTRIBUTED FROM JAPAN, UNDER
// JAPANESE LAWS. YOU MUST AGREE IN ADVANCE TO USE, COPY, MODIFY, MERGE, PUBLISH,
// DISTRIBUTE, SUBLICENSE, AND/OR SELL COPIES OF THIS SOFTWARE, THAT ANY
// JURIDICAL DISPUTES WHICH ARE CONCERNED TO THIS SOFTWARE OR ITS CONTENTS,
// AGAINST US (SOFTETHER PROJECT, SOFTETHER CORPORATION, DAIYUU NOBORI OR OTHER
// SUPPLIERS), OR ANY JURIDICAL DISPUTES AGAINST US WHICH ARE CAUSED BY ANY KIND
// OF USING, COPYING, MODIFYING, MERGING, PUBLISHING, DISTRIBUTING, SUBLICENSING,
// AND/OR SELLING COPIES OF THIS SOFTWARE SHALL BE REGARDED AS BE CONSTRUED AND
// CONTROLLED BY JAPANESE LAWS, AND YOU MUST FURTHER CONSENT TO EXCLUSIVE
// JURISDICTION AND VENUE IN THE COURTS SITTING IN TOKYO, JAPAN. YOU MUST WAIVE
// ALL DEFENSES OF LACK OF PERSONAL JURISDICTION AND FORUM NON CONVENIENS.
// PROCESS MAY BE SERVED ON EITHER PARTY IN THE MANNER AUTHORIZED BY APPLICABLE
// LAW OR COURT RULE.
//
// USE ONLY IN JAPAN. DO NOT USE THIS SOFTWARE IN ANOTHER COUNTRY UNLESS YOU HAVE
// A CONFIRMATION THAT THIS SOFTWARE DOES NOT VIOLATE ANY CRIMINAL LAWS OR CIVIL
// RIGHTS IN THAT PARTICULAR COUNTRY. USING THIS SOFTWARE IN OTHER COUNTRIES IS
// COMPLETELY AT YOUR OWN RISK. THE SOFTETHER VPN PROJECT HAS DEVELOPED AND
// DISTRIBUTED THIS SOFTWARE TO COMPLY ONLY WITH THE JAPANESE LAWS AND EXISTING
// CIVIL RIGHTS INCLUDING PATENTS WHICH ARE SUBJECTS APPLY IN JAPAN. OTHER
// COUNTRIES' LAWS OR CIVIL RIGHTS ARE NONE OF OUR CONCERNS NOR RESPONSIBILITIES.
// WE HAVE NEVER INVESTIGATED ANY CRIMINAL REGULATIONS, CIVIL LAWS OR
// INTELLECTUAL PROPERTY RIGHTS INCLUDING PATENTS IN ANY OF OTHER 200+ COUNTRIES
// AND TERRITORIES. BY NATURE, THERE ARE 200+ REGIONS IN THE WORLD, WITH
// DIFFERENT LAWS. IT IS IMPOSSIBLE TO VERIFY EVERY COUNTRIES' LAWS, REGULATIONS
// AND CIVIL RIGHTS TO MAKE THE SOFTWARE COMPLY WITH ALL COUNTRIES' LAWS BY THE
// PROJECT. EVEN IF YOU WILL BE SUED BY A PRIVATE ENTITY OR BE DAMAGED BY A
// PUBLIC SERVANT IN YOUR COUNTRY, THE DEVELOPERS OF THIS SOFTWARE WILL NEVER BE
// LIABLE TO RECOVER OR COMPENSATE SUCH DAMAGES, CRIMINAL OR CIVIL
// RESPONSIBILITIES. NOTE THAT THIS LINE IS NOT LICENSE RESTRICTION BUT JUST A
// STATEMENT FOR WARNING AND DISCLAIMER.
//
// READ AND UNDERSTAND THE 'WARNING.TXT' FILE BEFORE USING THIS SOFTWARE.
// SOME SOFTWARE PROGRAMS FROM THIRD PARTIES ARE INCLUDED ON THIS SOFTWARE WITH
// LICENSE CONDITIONS WHICH ARE DESCRIBED ON THE 'THIRD_PARTY.TXT' FILE.
//
//
// SOURCE CODE CONTRIBUTION
// ------------------------
//
// Your contribution to SoftEther VPN Project is much appreciated.
// Please send patches to us through GitHub.
// Read the SoftEther VPN Patch Acceptance Policy in advance:
// http://www.softether.org/5-download/src/9.patch
//
//
// DEAR SECURITY EXPERTS
// ---------------------
//
// If you find a bug or a security vulnerability please kindly inform us
// about the problem immediately so that we can fix the security problem
// to protect a lot of users around the world as soon as possible.
//
// Our e-mail address for security reports is:
// softether-vpn-security [at] softether.org
//
// Please note that the above e-mail address is not a technical support
// inquiry address. If you need technical assistance, please visit
// http://www.softether.org/ and ask your question on the users forum.
//
// Thank you for your cooperation.
//
//
// NO MEMORY OR RESOURCE LEAKS
// ---------------------------
//
// The memory-leaks and resource-leaks verification under the stress
// test has been passed before release this source code.
using System;
using System.Threading;
using System.Data;
using System.Data.Sql;
using System.Data.SqlClient;
using System.Data.SqlTypes;
using System.Text;
using System.Configuration;
using System.Collections;
using System.Collections.Generic;
using System.Security.Cryptography;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.IO;
using System.Drawing;
using System.Drawing.Imaging;
using System.Drawing.Drawing2D;
using System.Web.Mail;
namespace CoreUtil
{
class CsvTimeSpan
{
public DateTime StartDateTime;
public DateTime EndDateTime;
public int StartIndex;
public int NumIndex;
public CsvTimeSpan(DateTime startDateTime, DateTime endDateTime, int startIndex, int numIndex)
{
StartDateTime = startDateTime;
EndDateTime = endDateTime;
StartIndex = startIndex;
NumIndex = numIndex;
}
}
public class Csv
{
List<CsvEntry> entryList;
Encoding encoding;
static Encoding defaultEncoding = Str.ShiftJisEncoding;
public Encoding Encoding
{
get
{
return encoding;
}
set
{
this.encoding = value;
}
}
public CsvEntry First
{
get
{
return entryList[0];
}
}
public CsvEntry Last
{
get
{
return entryList[entryList.Count - 1];
}
}
public Csv()
: this(defaultEncoding)
{
}
public Csv(Encoding encoding)
{
init(null, encoding);
}
public Csv(string filename)
: this(filename, defaultEncoding)
{
}
public Csv(string filename, Encoding encoding)
{
init(Buf.ReadFromFile(filename), encoding);
}
public Csv(Buf data)
{
byte[] src = data.ByteData;
int bomSize;
Encoding enc = Str.CheckBOM(src, out bomSize);
if (bomSize >= 1)
{
src = Util.RemoveStartByteArray(src, bomSize);
}
init(new Buf(src), enc);
}
public Csv(Buf data, Encoding encoding)
{
init(data, encoding);
}
void init(Buf data, Encoding encoding)
{
if (encoding == null)
{
encoding = defaultEncoding;
}
int bomSize = 0;
Encoding enc2 = null;
if (data != null)
{
enc2 = Str.CheckBOM(data.ByteData, out bomSize);
}
if (bomSize >= 1)
{
data = new Buf(Util.RemoveStartByteArray(data.ByteData, bomSize));
}
if (enc2 != null)
{
encoding = enc2;
}
this.encoding = encoding;
entryList = new List<CsvEntry>();
if (data != null)
{
MemoryStream ms = new MemoryStream(data.ByteData);
StreamReader sr = new StreamReader(ms, this.encoding);
while (true)
{
string s = sr.ReadLine();
if (s == null)
{
break;
}
char[] sep = { ',' };
string[] strings = s.Trim().Split(sep, StringSplitOptions.None);
CsvEntry e = new CsvEntry(strings);
Add(e);
}
}
}
public override string ToString()
{
StringBuilder b = new StringBuilder();
foreach (CsvEntry e in entryList)
{
b.AppendLine(e.ToString());
}
return b.ToString();
}
public Buf ToBuf()
{
string s = ToString();
Buf b = new Buf();
byte[] bom = Str.GetBOM(this.Encoding);
if (bom != null)
{
b.Write(bom);
}
b.Write(encoding.GetBytes(s));
b.SeekToBegin();
return b;
}
public void SaveToFile(string filename)
{
File.WriteAllBytes(filename, ToBuf().ByteData);
}
public void Add(CsvEntry e)
{
entryList.Add(e);
}
public int Count
{
get
{
return entryList.Count;
}
}
public CsvEntry this[int index]
{
get
{
return entryList[index];
}
}
public IEnumerable Items
{
get
{
int i;
for (i = 0; i < entryList.Count; i++)
{
yield return entryList[i];
}
}
}
CsvCompare csvCompareMethod;
int csvCompareIndex;
Type csvCompareType;
bool csvCompareReverse;
int sortInternal(CsvEntry e1, CsvEntry e2)
{
if (csvCompareMethod != null)
{
object o1 = e1.Convert(csvCompareType, csvCompareIndex);
object o2 = e2.Convert(csvCompareType, csvCompareIndex);
return csvCompareMethod(o1, o2) * (csvCompareReverse ? -1 : 1);
}
else
{
IComparable o1 = (IComparable)e1.Convert(csvCompareType, csvCompareIndex);
IComparable o2 = (IComparable)e2.Convert(csvCompareType, csvCompareIndex);
return o1.CompareTo(o2) * (csvCompareReverse ? -1 : 1);
}
}
public void Sort(Type type)
{
Sort(null, type);
}
public void Sort(CsvCompare cmp, Type type)
{
Sort(cmp, type, false);
}
public void Sort(Type type, bool reverse)
{
Sort(null, type, reverse);
}
public void Sort(CsvCompare cmp, Type type, bool reverse)
{
Sort(cmp, 0, type, reverse);
}
public void Sort(int index, Type type)
{
Sort(null, index, type);
}
public void Sort(CsvCompare cmp, int index, Type type)
{
Sort(cmp, 0, type, false);
}
public void Sort(int index, Type type, bool reverse)
{
Sort(null, index, type, reverse);
}
public void Sort(CsvCompare cmp, int index, Type type, bool reverse)
{
csvCompareMethod = cmp;
csvCompareIndex = index;
csvCompareType = type;
csvCompareReverse = reverse;
entryList.Sort(new Comparison<CsvEntry>(sortInternal));
}
public static int CompareString(object o1, object o2)
{
string s1 = (string)o1;
string s2 = (string)o2;
return s1.CompareTo(s2);
}
public static int CompareDatetime(object o1, object o2)
{
DateTime d1 = (DateTime)o1;
DateTime d2 = (DateTime)o2;
return d1.CompareTo(d2);
}
public void SetEncoding(Encoding e)
{
this.encoding = e;
}
public Csv Clone()
{
Csv csv = new Csv(this.encoding);
foreach (CsvEntry e in entryList)
{
csv.Add(e.Clone());
}
return csv;
}
}
public delegate int CsvCompare(object o1, object o2);
public class CsvEntry
{
List<string> strings;
public CsvEntry Clone()
{
string[] array = (string[])strings.ToArray().Clone();
CsvEntry e = new CsvEntry(array);
return e;
}
public CsvEntry(params string[] elements)
{
strings = new List<string>();
foreach (string s in elements)
{
string str = s;
if (str.StartsWith("\"") && str.EndsWith("\"") && str.Length >= 2)
{
str = str.Substring(1, str.Length - 2);
}
strings.Add(str);
}
}
public string this[int index]
{
get
{
return strings[index];
}
}
public int Count
{
get
{
return strings.Count;
}
}
public override string ToString()
{
int i, num;
string ret = "";
num = strings.Count;
for (i = 0; i < num; i++)
{
string s = strings[i];
s = Str.ReplaceStr(s, ",", ".", false);
s = Str.ReplaceStr(s, "\r\n", " ", false);
s = Str.ReplaceStr(s, "\r", " ", false);
s = Str.ReplaceStr(s, "\n", " ", false);
ret += s;
if ((i + 1) < num)
{
ret += ",";
}
}
return ret;
}
Type lastType = null;
object lastObject = null;
int lastIndex = -1;
public object Convert(Type type, int index)
{
if (lastType == type && lastIndex == index)
{
return lastObject;
}
lastType = type;
lastIndex = index;
lastObject = System.Convert.ChangeType(strings[index], type);
return lastObject;
}
public DateTime ToDateTime(int index)
{
return (DateTime)Convert(typeof(DateTime), index);
}
}
}

View File

@ -1,587 +0,0 @@
// CoreUtil
//
// Copyright (C) 2012-2014 Daiyuu Nobori. All Rights Reserved.
// Copyright (C) 2012-2014 SoftEther VPN Project at University of Tsukuba. All Rights Reserved.
//
// License: The Apache License, Version 2.0
// https://www.apache.org/licenses/LICENSE-2.0
//
// DISCLAIMER
// ==========
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
// SOFTWARE.
//
// THIS SOFTWARE IS DEVELOPED IN JAPAN, AND DISTRIBUTED FROM JAPAN, UNDER
// JAPANESE LAWS. YOU MUST AGREE IN ADVANCE TO USE, COPY, MODIFY, MERGE, PUBLISH,
// DISTRIBUTE, SUBLICENSE, AND/OR SELL COPIES OF THIS SOFTWARE, THAT ANY
// JURIDICAL DISPUTES WHICH ARE CONCERNED TO THIS SOFTWARE OR ITS CONTENTS,
// AGAINST US (SOFTETHER PROJECT, SOFTETHER CORPORATION, DAIYUU NOBORI OR OTHER
// SUPPLIERS), OR ANY JURIDICAL DISPUTES AGAINST US WHICH ARE CAUSED BY ANY KIND
// OF USING, COPYING, MODIFYING, MERGING, PUBLISHING, DISTRIBUTING, SUBLICENSING,
// AND/OR SELLING COPIES OF THIS SOFTWARE SHALL BE REGARDED AS BE CONSTRUED AND
// CONTROLLED BY JAPANESE LAWS, AND YOU MUST FURTHER CONSENT TO EXCLUSIVE
// JURISDICTION AND VENUE IN THE COURTS SITTING IN TOKYO, JAPAN. YOU MUST WAIVE
// ALL DEFENSES OF LACK OF PERSONAL JURISDICTION AND FORUM NON CONVENIENS.
// PROCESS MAY BE SERVED ON EITHER PARTY IN THE MANNER AUTHORIZED BY APPLICABLE
// LAW OR COURT RULE.
//
// USE ONLY IN JAPAN. DO NOT USE THIS SOFTWARE IN ANOTHER COUNTRY UNLESS YOU HAVE
// A CONFIRMATION THAT THIS SOFTWARE DOES NOT VIOLATE ANY CRIMINAL LAWS OR CIVIL
// RIGHTS IN THAT PARTICULAR COUNTRY. USING THIS SOFTWARE IN OTHER COUNTRIES IS
// COMPLETELY AT YOUR OWN RISK. THE SOFTETHER VPN PROJECT HAS DEVELOPED AND
// DISTRIBUTED THIS SOFTWARE TO COMPLY ONLY WITH THE JAPANESE LAWS AND EXISTING
// CIVIL RIGHTS INCLUDING PATENTS WHICH ARE SUBJECTS APPLY IN JAPAN. OTHER
// COUNTRIES' LAWS OR CIVIL RIGHTS ARE NONE OF OUR CONCERNS NOR RESPONSIBILITIES.
// WE HAVE NEVER INVESTIGATED ANY CRIMINAL REGULATIONS, CIVIL LAWS OR
// INTELLECTUAL PROPERTY RIGHTS INCLUDING PATENTS IN ANY OF OTHER 200+ COUNTRIES
// AND TERRITORIES. BY NATURE, THERE ARE 200+ REGIONS IN THE WORLD, WITH
// DIFFERENT LAWS. IT IS IMPOSSIBLE TO VERIFY EVERY COUNTRIES' LAWS, REGULATIONS
// AND CIVIL RIGHTS TO MAKE THE SOFTWARE COMPLY WITH ALL COUNTRIES' LAWS BY THE
// PROJECT. EVEN IF YOU WILL BE SUED BY A PRIVATE ENTITY OR BE DAMAGED BY A
// PUBLIC SERVANT IN YOUR COUNTRY, THE DEVELOPERS OF THIS SOFTWARE WILL NEVER BE
// LIABLE TO RECOVER OR COMPENSATE SUCH DAMAGES, CRIMINAL OR CIVIL
// RESPONSIBILITIES. NOTE THAT THIS LINE IS NOT LICENSE RESTRICTION BUT JUST A
// STATEMENT FOR WARNING AND DISCLAIMER.
//
// READ AND UNDERSTAND THE 'WARNING.TXT' FILE BEFORE USING THIS SOFTWARE.
// SOME SOFTWARE PROGRAMS FROM THIRD PARTIES ARE INCLUDED ON THIS SOFTWARE WITH
// LICENSE CONDITIONS WHICH ARE DESCRIBED ON THE 'THIRD_PARTY.TXT' FILE.
//
//
// SOURCE CODE CONTRIBUTION
// ------------------------
//
// Your contribution to SoftEther VPN Project is much appreciated.
// Please send patches to us through GitHub.
// Read the SoftEther VPN Patch Acceptance Policy in advance:
// http://www.softether.org/5-download/src/9.patch
//
//
// DEAR SECURITY EXPERTS
// ---------------------
//
// If you find a bug or a security vulnerability please kindly inform us
// about the problem immediately so that we can fix the security problem
// to protect a lot of users around the world as soon as possible.
//
// Our e-mail address for security reports is:
// softether-vpn-security [at] softether.org
//
// Please note that the above e-mail address is not a technical support
// inquiry address. If you need technical assistance, please visit
// http://www.softether.org/ and ask your question on the users forum.
//
// Thank you for your cooperation.
//
//
// NO MEMORY OR RESOURCE LEAKS
// ---------------------------
//
// The memory-leaks and resource-leaks verification under the stress
// test has been passed before release this source code.
using System;
using System.Threading;
using System.Data;
using System.Data.Sql;
using System.Data.SqlClient;
using System.Data.SqlTypes;
using System.Text;
using System.Configuration;
using System.Collections;
using System.Collections.Generic;
using System.Security.Cryptography;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.IO;
using System.Drawing;
using System.Drawing.Imaging;
using System.Drawing.Drawing2D;
using System.Diagnostics;
using System.Web.Mail;
using System.Net;
using System.Net.Sockets;
using System.Net.NetworkInformation;
using System.Net.Mail;
using System.Net.Mime;
using System.Reflection;
using CoreUtil;
namespace CoreUtil
{
public static class Env
{
static object lockObj = new object();
static bool inited = false;
static Env()
{
initCache();
}
static void initCache()
{
lock (lockObj)
{
if (inited == false)
{
initValues();
inited = true;
}
}
}
static string homeDir;
static public string HomeDir
{
get { return homeDir; }
}
static string exeFileName;
static public string ExeFileName
{
get { return exeFileName; }
}
static string exeFileDir;
static public string ExeFileDir
{
get { return exeFileDir; }
}
static string windowsDir;
static public string WindowsDir
{
get { return windowsDir; }
}
static string systemDir;
static public string SystemDir
{
get { return systemDir; }
}
static string tempDir;
static public string TempDir
{
get { return tempDir; }
}
static string winTempDir;
static public string WinTempDir
{
get { return winTempDir; }
}
static string windowsDrive;
static public string WindowsDrive
{
get { return windowsDrive; }
}
static string programFilesDir;
static public string ProgramFilesDir
{
get { return programFilesDir; }
}
static string personalStartMenuDir;
static public string PersonalStartMenuDir
{
get { return personalStartMenuDir; }
}
static string personalProgramsDir;
static public string PersonalProgramsDir
{
get { return personalProgramsDir; }
}
static string personalStartupDir;
static public string PersonalStartupDir
{
get { return personalStartupDir; }
}
static string personalAppDataDir;
static public string PersonalAppDataDir
{
get { return personalAppDataDir; }
}
static string personalDesktopDir;
static public string PersonalDesktopDir
{
get { return personalDesktopDir; }
}
static string myDocumentsDir;
static public string MyDocumentsDir
{
get { return myDocumentsDir; }
}
static string localAppDataDir;
static public string LocalAppDataDir
{
get { return localAppDataDir; }
}
static string userName;
static public string UserName
{
get { return userName; }
}
static string userNameEx;
static public string UserNameEx
{
get { return userNameEx; }
}
static string machineName;
static public string MachineName
{
get { return machineName; }
}
static string commandLine;
public static string CommandLine
{
get { return commandLine; }
}
public static StrToken CommandLineList
{
get
{
return new StrToken(CommandLine);
}
}
static OperatingSystem osInfo;
public static OperatingSystem OsInfo
{
get { return osInfo; }
}
static bool isNt;
public static bool IsNt
{
get { return isNt; }
}
static bool is9x;
public static bool Is9x
{
get { return is9x; }
}
static bool isCe;
public static bool IsCe
{
get { return isCe; }
}
static bool isLittleEndian;
public static bool IsLittleEndian
{
get { return Env.isLittleEndian; }
}
public static bool IsBigEndian
{
get { return !IsLittleEndian; }
}
static bool isAdmin;
public static bool IsAdmin
{
get { return Env.isAdmin; }
}
static int processId;
public static int ProcessId
{
get { return Env.processId; }
}
static string myTempDir;
public static string MyTempDir
{
get { return myTempDir; }
}
static IO lockFile;
public static bool Is64BitProcess
{
get
{
return (IntPtr.Size == 8);
}
}
public static bool Is64BitWindows
{
get
{
return Is64BitProcess || Kernel.InternalCheckIsWow64();
}
}
public static bool IsWow64
{
get
{
return Kernel.InternalCheckIsWow64();
}
}
static void initValues()
{
exeFileName = IO.RemoteLastEnMark(getMyExeFileName());
if (Str.IsEmptyStr(exeFileName) == false)
{
exeFileDir = IO.RemoteLastEnMark(Path.GetDirectoryName(exeFileName));
}
else
{
exeFileDir = "";
}
homeDir = IO.RemoteLastEnMark(Kernel.GetEnvStr("HOME"));
if (Str.IsEmptyStr(homeDir))
{
homeDir = IO.RemoteLastEnMark(Kernel.GetEnvStr("HOMEDRIVE") + Kernel.GetEnvStr("HOMEPATH"));
}
if (Str.IsEmptyStr(homeDir))
{
homeDir = CurrentDir;
}
systemDir = IO.RemoteLastEnMark(Environment.GetFolderPath(Environment.SpecialFolder.System));
windowsDir = IO.RemoteLastEnMark(Path.GetDirectoryName(systemDir));
tempDir = IO.RemoteLastEnMark(Path.GetTempPath());
winTempDir = IO.RemoteLastEnMark(Path.Combine(windowsDir, "Temp"));
IO.MakeDir(winTempDir);
if (windowsDir.Length >= 2 && windowsDir[1] == ':')
{
windowsDrive = windowsDir.Substring(0, 2).ToUpper();
}
else
{
windowsDrive = "C:";
}
programFilesDir = IO.RemoteLastEnMark(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles));
personalStartMenuDir = IO.RemoteLastEnMark(Environment.GetFolderPath(Environment.SpecialFolder.StartMenu));
personalProgramsDir = IO.RemoteLastEnMark(Environment.GetFolderPath(Environment.SpecialFolder.Programs));
personalStartupDir = IO.RemoteLastEnMark(Environment.GetFolderPath(Environment.SpecialFolder.Startup));
personalAppDataDir = IO.RemoteLastEnMark(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData));
personalDesktopDir = IO.RemoteLastEnMark(Environment.GetFolderPath(Environment.SpecialFolder.DesktopDirectory));
myDocumentsDir = IO.RemoteLastEnMark(Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments));
localAppDataDir = IO.RemoteLastEnMark(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData));
userName = Environment.UserName;
try
{
userNameEx = Environment.UserDomainName + "\\" + userName;
}
catch
{
userNameEx = userName;
}
machineName = Environment.MachineName;
commandLine = initCommandLine(Environment.CommandLine);
osInfo = Environment.OSVersion;
isNt = (osInfo.Platform == PlatformID.Win32NT);
isCe = (osInfo.Platform == PlatformID.WinCE);
is9x = !(isNt || isCe);
isLittleEndian = BitConverter.IsLittleEndian;
processId = System.Diagnostics.Process.GetCurrentProcess().Id;
isAdmin = checkIsAdmin();
initMyTempDir();
}
static void deleteUnusedTempDir()
{
DirEntry[] files;
files = IO.EnumDir(Env.tempDir);
foreach (DirEntry e in files)
{
if (e.IsFolder)
{
if (e.FileName.StartsWith("NET_", StringComparison.CurrentCultureIgnoreCase) && e.FileName.Length == 8)
{
string dirFullName = Path.Combine(Env.tempDir, e.fileName);
string lockFileName = Path.Combine(dirFullName, "LockFile.dat");
bool deleteNow = false;
try
{
IO io = IO.FileOpen(lockFileName);
io.Close();
try
{
io = IO.FileOpen(lockFileName, true);
deleteNow = true;
io.Close();
}
catch
{
}
}
catch
{
DirEntry[] files2;
deleteNow = true;
try
{
files2 = IO.EnumDir(dirFullName);
foreach (DirEntry e2 in files2)
{
if (e2.IsFolder == false)
{
string fullPath = Path.Combine(dirFullName, e2.fileName);
try
{
IO io2 = IO.FileOpen(fullPath, true);
io2.Close();
}
catch
{
deleteNow = false;
}
}
}
}
catch
{
deleteNow = false;
}
}
if (deleteNow)
{
IO.DeleteDir(dirFullName, true);
}
}
}
}
}
static void initMyTempDir()
{
try
{
deleteUnusedTempDir();
}
catch
{
}
int num = 0;
while (true)
{
byte[] rand = Secure.Rand(2);
string tmp2 = Str.ByteToStr(rand);
string tmp = Path.Combine(Env.tempDir, "NET_" + tmp2);
if (IO.IsDirExists(tmp) == false && IO.MakeDir(tmp))
{
Env.myTempDir = tmp;
break;
}
if ((num++) >= 100)
{
throw new SystemException();
}
}
string lockFileName = Path.Combine(Env.myTempDir, "LockFile.dat");
lockFile = IO.FileCreate(lockFileName);
}
static bool checkIsAdmin()
{
try
{
string name = "Vpn_Check_Admin_Key_NET_" + processId.ToString();
string teststr = Str.GenRandStr();
if (Reg.WriteStr(RegRoot.LocalMachine, "", name, teststr) == false)
{
return false;
}
try
{
string ret = Reg.ReadStr(RegRoot.LocalMachine, "", name);
if (ret == teststr)
{
return true;
}
return false;
}
finally
{
Reg.DeleteValue(RegRoot.LocalMachine, "", name);
}
}
catch
{
return false;
}
}
static string initCommandLine(string src)
{
try
{
int i;
if (src.Length >= 1 && src[0] == '\"')
{
i = src.IndexOf('\"', 1);
}
else
{
i = src.IndexOf(' ');
}
if (i == -1)
{
return "";
}
else
{
return src.Substring(i + 1).TrimStart(' ');
}
}
catch
{
return "";
}
}
static string getMyExeFileName()
{
try
{
Assembly mainAssembly = Assembly.GetEntryAssembly();
Module[] modules = mainAssembly.GetModules();
return modules[0].FullyQualifiedName;
}
catch
{
return "";
}
}
static public string CurrentDir
{
get
{
return IO.RemoteLastEnMark(Environment.CurrentDirectory);
}
}
static public string NewLine
{
get
{
return Environment.NewLine;
}
}
}
}

File diff suppressed because it is too large Load Diff

View File

@ -1,248 +0,0 @@
// CoreUtil
//
// Copyright (C) 2012-2014 Daiyuu Nobori. All Rights Reserved.
// Copyright (C) 2012-2014 SoftEther VPN Project at University of Tsukuba. All Rights Reserved.
//
// License: The Apache License, Version 2.0
// https://www.apache.org/licenses/LICENSE-2.0
//
// DISCLAIMER
// ==========
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
// SOFTWARE.
//
// THIS SOFTWARE IS DEVELOPED IN JAPAN, AND DISTRIBUTED FROM JAPAN, UNDER
// JAPANESE LAWS. YOU MUST AGREE IN ADVANCE TO USE, COPY, MODIFY, MERGE, PUBLISH,
// DISTRIBUTE, SUBLICENSE, AND/OR SELL COPIES OF THIS SOFTWARE, THAT ANY
// JURIDICAL DISPUTES WHICH ARE CONCERNED TO THIS SOFTWARE OR ITS CONTENTS,
// AGAINST US (SOFTETHER PROJECT, SOFTETHER CORPORATION, DAIYUU NOBORI OR OTHER
// SUPPLIERS), OR ANY JURIDICAL DISPUTES AGAINST US WHICH ARE CAUSED BY ANY KIND
// OF USING, COPYING, MODIFYING, MERGING, PUBLISHING, DISTRIBUTING, SUBLICENSING,
// AND/OR SELLING COPIES OF THIS SOFTWARE SHALL BE REGARDED AS BE CONSTRUED AND
// CONTROLLED BY JAPANESE LAWS, AND YOU MUST FURTHER CONSENT TO EXCLUSIVE
// JURISDICTION AND VENUE IN THE COURTS SITTING IN TOKYO, JAPAN. YOU MUST WAIVE
// ALL DEFENSES OF LACK OF PERSONAL JURISDICTION AND FORUM NON CONVENIENS.
// PROCESS MAY BE SERVED ON EITHER PARTY IN THE MANNER AUTHORIZED BY APPLICABLE
// LAW OR COURT RULE.
//
// USE ONLY IN JAPAN. DO NOT USE THIS SOFTWARE IN ANOTHER COUNTRY UNLESS YOU HAVE
// A CONFIRMATION THAT THIS SOFTWARE DOES NOT VIOLATE ANY CRIMINAL LAWS OR CIVIL
// RIGHTS IN THAT PARTICULAR COUNTRY. USING THIS SOFTWARE IN OTHER COUNTRIES IS
// COMPLETELY AT YOUR OWN RISK. THE SOFTETHER VPN PROJECT HAS DEVELOPED AND
// DISTRIBUTED THIS SOFTWARE TO COMPLY ONLY WITH THE JAPANESE LAWS AND EXISTING
// CIVIL RIGHTS INCLUDING PATENTS WHICH ARE SUBJECTS APPLY IN JAPAN. OTHER
// COUNTRIES' LAWS OR CIVIL RIGHTS ARE NONE OF OUR CONCERNS NOR RESPONSIBILITIES.
// WE HAVE NEVER INVESTIGATED ANY CRIMINAL REGULATIONS, CIVIL LAWS OR
// INTELLECTUAL PROPERTY RIGHTS INCLUDING PATENTS IN ANY OF OTHER 200+ COUNTRIES
// AND TERRITORIES. BY NATURE, THERE ARE 200+ REGIONS IN THE WORLD, WITH
// DIFFERENT LAWS. IT IS IMPOSSIBLE TO VERIFY EVERY COUNTRIES' LAWS, REGULATIONS
// AND CIVIL RIGHTS TO MAKE THE SOFTWARE COMPLY WITH ALL COUNTRIES' LAWS BY THE
// PROJECT. EVEN IF YOU WILL BE SUED BY A PRIVATE ENTITY OR BE DAMAGED BY A
// PUBLIC SERVANT IN YOUR COUNTRY, THE DEVELOPERS OF THIS SOFTWARE WILL NEVER BE
// LIABLE TO RECOVER OR COMPENSATE SUCH DAMAGES, CRIMINAL OR CIVIL
// RESPONSIBILITIES. NOTE THAT THIS LINE IS NOT LICENSE RESTRICTION BUT JUST A
// STATEMENT FOR WARNING AND DISCLAIMER.
//
// READ AND UNDERSTAND THE 'WARNING.TXT' FILE BEFORE USING THIS SOFTWARE.
// SOME SOFTWARE PROGRAMS FROM THIRD PARTIES ARE INCLUDED ON THIS SOFTWARE WITH
// LICENSE CONDITIONS WHICH ARE DESCRIBED ON THE 'THIRD_PARTY.TXT' FILE.
//
//
// SOURCE CODE CONTRIBUTION
// ------------------------
//
// Your contribution to SoftEther VPN Project is much appreciated.
// Please send patches to us through GitHub.
// Read the SoftEther VPN Patch Acceptance Policy in advance:
// http://www.softether.org/5-download/src/9.patch
//
//
// DEAR SECURITY EXPERTS
// ---------------------
//
// If you find a bug or a security vulnerability please kindly inform us
// about the problem immediately so that we can fix the security problem
// to protect a lot of users around the world as soon as possible.
//
// Our e-mail address for security reports is:
// softether-vpn-security [at] softether.org
//
// Please note that the above e-mail address is not a technical support
// inquiry address. If you need technical assistance, please visit
// http://www.softether.org/ and ask your question on the users forum.
//
// Thank you for your cooperation.
//
//
// NO MEMORY OR RESOURCE LEAKS
// ---------------------------
//
// The memory-leaks and resource-leaks verification under the stress
// test has been passed before release this source code.
using System;
using System.Threading;
using System.Data;
using System.Data.Sql;
using System.Data.SqlClient;
using System.Data.SqlTypes;
using System.Text;
using System.Configuration;
using System.Collections;
using System.Collections.Generic;
using System.Security.Cryptography;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.IO;
using System.IO.Compression;
using System.Drawing;
using System.Drawing.Imaging;
using System.Drawing.Drawing2D;
using System.Runtime.InteropServices;
using CoreUtil.Internal;
namespace CoreUtil
{
[StructLayout(LayoutKind.Sequential, Pack = 1)]
public struct GZipHeader
{
public byte ID1, ID2, CM, FLG;
public uint MTIME;
public byte XFL, OS;
}
[StructLayout(LayoutKind.Sequential, Pack = 1)]
public struct GZipFooter
{
public uint CRC32;
public uint ISIZE;
}
public static class GZipUtil
{
public static byte[] Decompress(byte[] gzip)
{
using (GZipStream stream = new GZipStream(new MemoryStream(gzip), CompressionMode.Decompress))
{
const int size = 4096;
byte[] buffer = new byte[size];
using (MemoryStream memory = new MemoryStream())
{
int count = 0;
do
{
count = stream.Read(buffer, 0, size);
if (count > 0)
{
memory.Write(buffer, 0, count);
}
}
while (count > 0);
return memory.ToArray();
}
}
}
}
public class GZipPacker
{
Fifo fifo;
ZStream zs;
long currentSize;
uint crc32;
bool finished;
public bool Finished
{
get { return finished; }
}
public Fifo GeneratedData
{
get
{
return this.fifo;
}
}
public GZipPacker()
{
fifo = new Fifo();
zs = new ZStream();
zs.deflateInit(-1, -15);
this.currentSize = 0;
this.crc32 = 0xffffffff;
this.finished = false;
GZipHeader h = new GZipHeader();
h.ID1 = 0x1f;
h.ID2 = 0x8b;
h.FLG = 0;
h.MTIME = Util.DateTimeToUnixTime(DateTime.Now.ToUniversalTime());
h.XFL = 0;
h.OS = 3;
h.CM = 8;
fifo.Write(Util.StructToByte(h));
}
public void Write(byte[] data, int pos, int len, bool finish)
{
byte[] srcData = Util.ExtractByteArray(data, pos, len);
byte[] dstData = new byte[srcData.Length * 2 + 100];
if (this.finished)
{
throw new ApplicationException("already finished");
}
zs.next_in = srcData;
zs.avail_in = srcData.Length;
zs.next_in_index = 0;
zs.next_out = dstData;
zs.avail_out = dstData.Length;
zs.next_out_index = 0;
if (finish)
{
zs.deflate(zlibConst.Z_FINISH);
}
else
{
zs.deflate(zlibConst.Z_SYNC_FLUSH);
}
fifo.Write(dstData, 0, dstData.Length - zs.avail_out);
currentSize += len;
this.crc32 = ZipUtil.Crc32Next(data, pos, len, this.crc32);
if (finish)
{
this.finished = true;
this.crc32 = ~this.crc32;
GZipFooter f = new GZipFooter();
f.CRC32 = this.crc32;
f.ISIZE = (uint)(this.currentSize % 0x100000000);
fifo.Write(Util.StructToByte(f));
}
}
}
}

View File

@ -1,185 +0,0 @@
// CoreUtil
//
// Copyright (C) 2012-2014 Daiyuu Nobori. All Rights Reserved.
// Copyright (C) 2012-2014 SoftEther VPN Project at University of Tsukuba. All Rights Reserved.
//
// License: The Apache License, Version 2.0
// https://www.apache.org/licenses/LICENSE-2.0
//
// DISCLAIMER
// ==========
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
// SOFTWARE.
//
// THIS SOFTWARE IS DEVELOPED IN JAPAN, AND DISTRIBUTED FROM JAPAN, UNDER
// JAPANESE LAWS. YOU MUST AGREE IN ADVANCE TO USE, COPY, MODIFY, MERGE, PUBLISH,
// DISTRIBUTE, SUBLICENSE, AND/OR SELL COPIES OF THIS SOFTWARE, THAT ANY
// JURIDICAL DISPUTES WHICH ARE CONCERNED TO THIS SOFTWARE OR ITS CONTENTS,
// AGAINST US (SOFTETHER PROJECT, SOFTETHER CORPORATION, DAIYUU NOBORI OR OTHER
// SUPPLIERS), OR ANY JURIDICAL DISPUTES AGAINST US WHICH ARE CAUSED BY ANY KIND
// OF USING, COPYING, MODIFYING, MERGING, PUBLISHING, DISTRIBUTING, SUBLICENSING,
// AND/OR SELLING COPIES OF THIS SOFTWARE SHALL BE REGARDED AS BE CONSTRUED AND
// CONTROLLED BY JAPANESE LAWS, AND YOU MUST FURTHER CONSENT TO EXCLUSIVE
// JURISDICTION AND VENUE IN THE COURTS SITTING IN TOKYO, JAPAN. YOU MUST WAIVE
// ALL DEFENSES OF LACK OF PERSONAL JURISDICTION AND FORUM NON CONVENIENS.
// PROCESS MAY BE SERVED ON EITHER PARTY IN THE MANNER AUTHORIZED BY APPLICABLE
// LAW OR COURT RULE.
//
// USE ONLY IN JAPAN. DO NOT USE THIS SOFTWARE IN ANOTHER COUNTRY UNLESS YOU HAVE
// A CONFIRMATION THAT THIS SOFTWARE DOES NOT VIOLATE ANY CRIMINAL LAWS OR CIVIL
// RIGHTS IN THAT PARTICULAR COUNTRY. USING THIS SOFTWARE IN OTHER COUNTRIES IS
// COMPLETELY AT YOUR OWN RISK. THE SOFTETHER VPN PROJECT HAS DEVELOPED AND
// DISTRIBUTED THIS SOFTWARE TO COMPLY ONLY WITH THE JAPANESE LAWS AND EXISTING
// CIVIL RIGHTS INCLUDING PATENTS WHICH ARE SUBJECTS APPLY IN JAPAN. OTHER
// COUNTRIES' LAWS OR CIVIL RIGHTS ARE NONE OF OUR CONCERNS NOR RESPONSIBILITIES.
// WE HAVE NEVER INVESTIGATED ANY CRIMINAL REGULATIONS, CIVIL LAWS OR
// INTELLECTUAL PROPERTY RIGHTS INCLUDING PATENTS IN ANY OF OTHER 200+ COUNTRIES
// AND TERRITORIES. BY NATURE, THERE ARE 200+ REGIONS IN THE WORLD, WITH
// DIFFERENT LAWS. IT IS IMPOSSIBLE TO VERIFY EVERY COUNTRIES' LAWS, REGULATIONS
// AND CIVIL RIGHTS TO MAKE THE SOFTWARE COMPLY WITH ALL COUNTRIES' LAWS BY THE
// PROJECT. EVEN IF YOU WILL BE SUED BY A PRIVATE ENTITY OR BE DAMAGED BY A
// PUBLIC SERVANT IN YOUR COUNTRY, THE DEVELOPERS OF THIS SOFTWARE WILL NEVER BE
// LIABLE TO RECOVER OR COMPENSATE SUCH DAMAGES, CRIMINAL OR CIVIL
// RESPONSIBILITIES. NOTE THAT THIS LINE IS NOT LICENSE RESTRICTION BUT JUST A
// STATEMENT FOR WARNING AND DISCLAIMER.
//
// READ AND UNDERSTAND THE 'WARNING.TXT' FILE BEFORE USING THIS SOFTWARE.
// SOME SOFTWARE PROGRAMS FROM THIRD PARTIES ARE INCLUDED ON THIS SOFTWARE WITH
// LICENSE CONDITIONS WHICH ARE DESCRIBED ON THE 'THIRD_PARTY.TXT' FILE.
//
//
// SOURCE CODE CONTRIBUTION
// ------------------------
//
// Your contribution to SoftEther VPN Project is much appreciated.
// Please send patches to us through GitHub.
// Read the SoftEther VPN Patch Acceptance Policy in advance:
// http://www.softether.org/5-download/src/9.patch
//
//
// DEAR SECURITY EXPERTS
// ---------------------
//
// If you find a bug or a security vulnerability please kindly inform us
// about the problem immediately so that we can fix the security problem
// to protect a lot of users around the world as soon as possible.
//
// Our e-mail address for security reports is:
// softether-vpn-security [at] softether.org
//
// Please note that the above e-mail address is not a technical support
// inquiry address. If you need technical assistance, please visit
// http://www.softether.org/ and ask your question on the users forum.
//
// Thank you for your cooperation.
//
//
// NO MEMORY OR RESOURCE LEAKS
// ---------------------------
//
// The memory-leaks and resource-leaks verification under the stress
// test has been passed before release this source code.
using System;
using System.Threading;
using System.Data;
using System.Data.Sql;
using System.Data.SqlClient;
using System.Data.SqlTypes;
using System.Text;
using System.Configuration;
using System.Collections;
using System.Collections.Generic;
using System.Security.Cryptography;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.IO;
using System.Drawing;
using System.Drawing.Imaging;
using System.Drawing.Drawing2D;
using System.Diagnostics;
using System.Web.Mail;
using System.Net;
using System.Net.Sockets;
using System.Net.NetworkInformation;
using System.Net.Mail;
using System.Net.Mime;
using System.Runtime.InteropServices;
namespace CoreUtil
{
public static class Kernel
{
[DllImport("kernel32.dll", SetLastError = true, CallingConvention = CallingConvention.Winapi)]
[return: MarshalAs(UnmanagedType.Bool)]
private static extern bool IsWow64Process(
[In] IntPtr hProcess,
[Out] out bool wow64Process
);
public static bool InternalCheckIsWow64()
{
if ((Environment.OSVersion.Version.Major == 5 && Environment.OSVersion.Version.Minor >= 1) ||
Environment.OSVersion.Version.Major >= 6)
{
using (Process p = Process.GetCurrentProcess())
{
bool retVal;
if (!IsWow64Process(p.Handle, out retVal))
{
return false;
}
return retVal;
}
}
else
{
return false;
}
}
public static void SleepThread(int millisec)
{
ThreadObj.Sleep(millisec);
}
public static string GetEnvStr(string name)
{
string ret = Environment.GetEnvironmentVariable(name);
if (ret == null)
{
ret = "";
}
return ret;
}
static public void SelfKill()
{
System.Diagnostics.Process.GetCurrentProcess().Kill();
}
public static Process Run(string exeName, string args)
{
Process p = new Process();
p.StartInfo.FileName = IO.InnerFilePath(exeName);
p.StartInfo.Arguments = args;
p.Start();
return p;
}
}
}

View File

@ -1,954 +0,0 @@
// CoreUtil
//
// Copyright (C) 2012-2014 Daiyuu Nobori. All Rights Reserved.
// Copyright (C) 2012-2014 SoftEther VPN Project at University of Tsukuba. All Rights Reserved.
//
// License: The Apache License, Version 2.0
// https://www.apache.org/licenses/LICENSE-2.0
//
// DISCLAIMER
// ==========
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
// SOFTWARE.
//
// THIS SOFTWARE IS DEVELOPED IN JAPAN, AND DISTRIBUTED FROM JAPAN, UNDER
// JAPANESE LAWS. YOU MUST AGREE IN ADVANCE TO USE, COPY, MODIFY, MERGE, PUBLISH,
// DISTRIBUTE, SUBLICENSE, AND/OR SELL COPIES OF THIS SOFTWARE, THAT ANY
// JURIDICAL DISPUTES WHICH ARE CONCERNED TO THIS SOFTWARE OR ITS CONTENTS,
// AGAINST US (SOFTETHER PROJECT, SOFTETHER CORPORATION, DAIYUU NOBORI OR OTHER
// SUPPLIERS), OR ANY JURIDICAL DISPUTES AGAINST US WHICH ARE CAUSED BY ANY KIND
// OF USING, COPYING, MODIFYING, MERGING, PUBLISHING, DISTRIBUTING, SUBLICENSING,
// AND/OR SELLING COPIES OF THIS SOFTWARE SHALL BE REGARDED AS BE CONSTRUED AND
// CONTROLLED BY JAPANESE LAWS, AND YOU MUST FURTHER CONSENT TO EXCLUSIVE
// JURISDICTION AND VENUE IN THE COURTS SITTING IN TOKYO, JAPAN. YOU MUST WAIVE
// ALL DEFENSES OF LACK OF PERSONAL JURISDICTION AND FORUM NON CONVENIENS.
// PROCESS MAY BE SERVED ON EITHER PARTY IN THE MANNER AUTHORIZED BY APPLICABLE
// LAW OR COURT RULE.
//
// USE ONLY IN JAPAN. DO NOT USE THIS SOFTWARE IN ANOTHER COUNTRY UNLESS YOU HAVE
// A CONFIRMATION THAT THIS SOFTWARE DOES NOT VIOLATE ANY CRIMINAL LAWS OR CIVIL
// RIGHTS IN THAT PARTICULAR COUNTRY. USING THIS SOFTWARE IN OTHER COUNTRIES IS
// COMPLETELY AT YOUR OWN RISK. THE SOFTETHER VPN PROJECT HAS DEVELOPED AND
// DISTRIBUTED THIS SOFTWARE TO COMPLY ONLY WITH THE JAPANESE LAWS AND EXISTING
// CIVIL RIGHTS INCLUDING PATENTS WHICH ARE SUBJECTS APPLY IN JAPAN. OTHER
// COUNTRIES' LAWS OR CIVIL RIGHTS ARE NONE OF OUR CONCERNS NOR RESPONSIBILITIES.
// WE HAVE NEVER INVESTIGATED ANY CRIMINAL REGULATIONS, CIVIL LAWS OR
// INTELLECTUAL PROPERTY RIGHTS INCLUDING PATENTS IN ANY OF OTHER 200+ COUNTRIES
// AND TERRITORIES. BY NATURE, THERE ARE 200+ REGIONS IN THE WORLD, WITH
// DIFFERENT LAWS. IT IS IMPOSSIBLE TO VERIFY EVERY COUNTRIES' LAWS, REGULATIONS
// AND CIVIL RIGHTS TO MAKE THE SOFTWARE COMPLY WITH ALL COUNTRIES' LAWS BY THE
// PROJECT. EVEN IF YOU WILL BE SUED BY A PRIVATE ENTITY OR BE DAMAGED BY A
// PUBLIC SERVANT IN YOUR COUNTRY, THE DEVELOPERS OF THIS SOFTWARE WILL NEVER BE
// LIABLE TO RECOVER OR COMPENSATE SUCH DAMAGES, CRIMINAL OR CIVIL
// RESPONSIBILITIES. NOTE THAT THIS LINE IS NOT LICENSE RESTRICTION BUT JUST A
// STATEMENT FOR WARNING AND DISCLAIMER.
//
// READ AND UNDERSTAND THE 'WARNING.TXT' FILE BEFORE USING THIS SOFTWARE.
// SOME SOFTWARE PROGRAMS FROM THIRD PARTIES ARE INCLUDED ON THIS SOFTWARE WITH
// LICENSE CONDITIONS WHICH ARE DESCRIBED ON THE 'THIRD_PARTY.TXT' FILE.
//
//
// SOURCE CODE CONTRIBUTION
// ------------------------
//
// Your contribution to SoftEther VPN Project is much appreciated.
// Please send patches to us through GitHub.
// Read the SoftEther VPN Patch Acceptance Policy in advance:
// http://www.softether.org/5-download/src/9.patch
//
//
// DEAR SECURITY EXPERTS
// ---------------------
//
// If you find a bug or a security vulnerability please kindly inform us
// about the problem immediately so that we can fix the security problem
// to protect a lot of users around the world as soon as possible.
//
// Our e-mail address for security reports is:
// softether-vpn-security [at] softether.org
//
// Please note that the above e-mail address is not a technical support
// inquiry address. If you need technical assistance, please visit
// http://www.softether.org/ and ask your question on the users forum.
//
// Thank you for your cooperation.
//
//
// NO MEMORY OR RESOURCE LEAKS
// ---------------------------
//
// The memory-leaks and resource-leaks verification under the stress
// test has been passed before release this source code.
using System;
using System.Data;
using System.Data.Sql;
using System.Data.SqlClient;
using System.Data.SqlTypes;
using System.Text;
using System.Configuration;
using System.Collections;
using System.Collections.Generic;
using System.Security.Cryptography;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.IO;
using System.Drawing;
using System.Drawing.Imaging;
using System.Drawing.Drawing2D;
using System.Web.Mail;
using System.Threading;
using System.Xml;
using System.Xml.Schema;
using System.Xml.Serialization;
using CoreUtil;
public static class AspUtil
{
public static void Redirect(Page page, string url)
{
Redirect(page, url, true);
}
public static void Redirect(Page page, string url, bool endSession)
{
MultiLang ml = new MultiLang(page, true);
ml.Redirect(url, true);
}
public static string GetCurrentRequestUrl(Page page)
{
string s = (string)page.Request.Headers["SEISAPI_PHYSICAL_URL"];
if (Str.IsEmptyStr(s) == false)
{
string[] tokens = s.Split('?');
return tokens[0];
}
return page.Request.Path;
}
public static string GetCurrentPhysicalFilePathForUser(Page page)
{
string s = (string)page.Request.Headers["SEISAPI_ORIGINAL_FILEPATH"];
if (Str.IsEmptyStr(s) == false)
{
return s;
}
return page.Request.PhysicalPath;
}
public static string RemoveDefaultHtml(string url)
{
string tmp = url.ToLower();
if (tmp.EndsWith("/default.asp") || tmp.EndsWith("/default.aspx") || tmp.EndsWith("/default.htm") || tmp.EndsWith("/default.html"))
{
return GetUrlDirNameFromPath(url);
}
else
{
return url;
}
}
public static string GetUrlDirNameFromPath(string url)
{
string ret = "";
string[] strs = url.Split('/');
int i;
if (strs.Length >= 1)
{
for (i = 0; i < strs.Length - 1; i++)
{
ret += strs[i] + "/";
}
}
return ret;
}
public static string WebPathToFilePath(System.Web.UI.Page page, string path)
{
string appRootFilePath = page.Request.PhysicalApplicationPath;
string appRootVirtualPath = page.Request.ApplicationPath;
string ret;
path = RemoveDefaultHtml(path);
if (path.ToUpper().StartsWith(appRootVirtualPath.ToUpper()) == false)
{
return null;
}
path = path.Substring(appRootVirtualPath.Length).Replace("/", "\\");
if (path.StartsWith("\\"))
{
path = path.Substring(1);
}
ret = appRootFilePath + path;
if (ret.IndexOf("..") != -1)
{
return null;
}
if (ret.EndsWith("\\"))
{
ret = GetDefaultDocumentIfExists(ret);
}
return ret;
}
public static string GetDefaultDocumentIfExists(string dir)
{
string[] targets =
{
"default.aspx",
"default.asp",
"default.html",
"default.htm",
"index.html",
"index.htm",
};
foreach (string s in targets)
{
string name = dir + s;
if (IsFileExists(name))
{
return name;
}
}
return null;
}
public static bool IsFileExists(string name)
{
return File.Exists(name);
}
}
public class MultiLang
{
public readonly Page Page;
public readonly HttpRequest Request;
public readonly HttpResponse Response;
public readonly bool IsUrlModefied;
public readonly string OriginalUrl;
public readonly string PhysicalUrl;
public readonly bool IsFilenameModified;
public readonly string OriginalFileName;
public readonly string OriginalFilePath;
public readonly string Args;
public readonly CoreLanguageClass CurrentLanguage;
public readonly CoreLanguageClass ContentsPrintLanguage;
public readonly string CurrentLanguageCode;
public readonly bool IsCurrentLanguageSupported;
public readonly string GoogleTranslateUrl;
public readonly string OriginalFullUrl;
public readonly bool IsSSL;
public readonly string Host;
public readonly string BasicHostName;
MultiLanguageFilterStream mfs;
public readonly List<KeyValuePair<string, string>> ReplaceList;
public bool DisableFilter
{
get
{
return mfs.DisableFilter;
}
set
{
mfs.DisableFilter = value;
}
}
public readonly string HtmlBody = "";
public readonly string HtmlFileName = "";
static MultiLang()
{
CoreLanguageList.RegardsJapanAsJP = true;
}
public bool IsJapanese
{
get
{
if (this.CurrentLanguage == CoreLanguageList.Japanese)
{
return true;
}
return false;
}
}
public bool IsJapanesePrinting
{
get
{
if (this.ContentsPrintLanguage == CoreLanguageList.Japanese)
{
return true;
}
return false;
}
}
public void Redirect(string url, bool endSession)
{
url = ConvertPath(url);
if (url.StartsWith("http://") || url.StartsWith("https://") || url.StartsWith("ftp://") ||
url.StartsWith("/"))
{
}
else
{
string originalUrl = OriginalUrl;
if (originalUrl.EndsWith("/"))
{
}
else
{
int i;
for (i = originalUrl.Length - 1; i >= 0; i--)
{
if (originalUrl[i] == '/' || originalUrl[i] == '\\')
{
originalUrl = originalUrl.Substring(0, i + 1);
break;
}
}
}
url = originalUrl + url;
}
Response.Redirect(url, endSession);
}
public MultiLang(Page currentPage)
: this(currentPage, false)
{
}
public MultiLang(Page currentPage, bool fast) : this(currentPage, fast, null)
{
}
public MultiLang(Page currentPage, bool fast, string basicHostName)
: this(currentPage, fast, basicHostName, new List<KeyValuePair<string, string>>())
{
}
public MultiLang(Page currentPage, bool fast, string basicHostName, List<KeyValuePair<string, string>> replaceList)
{
this.Page = currentPage;
this.Request = Page.Request;
this.Response = Page.Response;
this.BasicHostName = basicHostName;
string tmp = Page.Request.ServerVariables["HTTPS"];
string hostRaw = Page.Request.Headers["Host"];
this.ReplaceList = replaceList;
bool isSsl = false;
string[] tokens;
string host = "";
tokens = hostRaw.Split(':');
if (tokens.Length >= 1)
{
host = tokens[0];
}
host = host.ToLower();
if (tmp != null)
{
if (tmp.Equals("on", StringComparison.InvariantCultureIgnoreCase))
{
isSsl = true;
}
}
this.IsSSL = isSsl;
this.Host = host;
this.IsUrlModefied = Str.StrToBool((string)Request.Headers["SEISAPI_MODIFIED_URL"]);
this.OriginalUrl = (string)Request.Headers["SEISAPI_ORIGINAL_URL"];
int i;
i = this.OriginalUrl.IndexOf("?");
if (i != -1)
{
this.OriginalUrl = this.OriginalUrl.Substring(0, i);
}
if (Str.IsEmptyStr(this.OriginalUrl) || this.IsUrlModefied == false)
{
this.OriginalUrl = AspUtil.RemoveDefaultHtml(AspUtil.GetCurrentRequestUrl(Page));
}
string s = (string)Request.Headers["SEISAPI_ORIGINAL_FILENAME"];
if (Str.IsEmptyStr(s) == false)
{
this.IsFilenameModified = true;
this.OriginalFileName = s;
this.OriginalFilePath = (string)Request.Headers["SEISAPI_ORIGINAL_FILEPATH"];
}
string langCode = GetCurrentLangCodeFromPath(this.OriginalUrl);
this.CurrentLanguage = CoreLanguageList.GetLanguageClassByName(langCode);
this.CurrentLanguageCode = CurrentLanguage.Name;
try
{
HtmlFileName = AspUtil.WebPathToFilePath(currentPage, AspUtil.GetCurrentRequestUrl(currentPage));
}
catch
{
}
if (this.IsFilenameModified)
{
HtmlFileName = Path.Combine(Path.GetDirectoryName(HtmlFileName), Path.GetFileName(OriginalFilePath));
}
try
{
if (fast == false)
{
HtmlBody = File.ReadAllText(HtmlFileName, Str.Utf8Encoding);
}
}
catch
{
}
PhysicalUrl = AspUtil.RemoveDefaultHtml(AspUtil.GetCurrentRequestUrl((currentPage)));
Args = currentPage.Request.ServerVariables["QUERY_STRING"];
if (CurrentLanguage == CoreLanguageList.Japanese)
{
IsCurrentLanguageSupported = true;
}
else
{
IsCurrentLanguageSupported = Str.SearchStr(HtmlBody, string.Format("<!-- ml:{0} -->", CurrentLanguage.Name), 0, false) != -1;
}
GoogleTranslateUrl = string.Format("http://translate.google.com/translate?js=n&prev=_t&hl=en&ie=UTF-8&layout=2&eotf=1&sl=ja&tl={1}&u={0}",
HttpUtility.UrlEncode((isSsl ? "https://" : "http://") + host + this.OriginalUrl, Str.Utf8Encoding),
this.CurrentLanguageCode);
OriginalFullUrl = (isSsl ? "https://" : "http://") + host + this.OriginalUrl;
ContentsPrintLanguage = this.CurrentLanguage;
if (IsCurrentLanguageSupported == false)
{
ContentsPrintLanguage = CoreLanguageList.Japanese;
}
if (fast == false)
{
mfs = new MultiLanguageFilterStream(Response.Filter, ContentsPrintLanguage, this.CurrentLanguage, this.BasicHostName, this.ReplaceList);
mfs.Page = Page;
Response.Filter = mfs;
}
}
public string ConvertPath(string url)
{
return ConvertPath(url, this.CurrentLanguage);
}
public string ConvertPath(string url, CoreLanguageClass lang)
{
string ja = CoreLanguageList.Japanese.Name;
if (url.StartsWith("/" + ja, StringComparison.InvariantCultureIgnoreCase))
{
url = "/" + lang.Name + url.Substring(ja.Length + 1);
}
return url;
}
public string GetPathForLanguage(CoreLanguageClass lang)
{
string url = PhysicalUrl;
return ConvertPath(url, lang);
}
public string GetFullUrlForLanguage(CoreLanguageClass lang)
{
string url = (IsSSL ? "https://" : "http://") + Host + GetPathForLanguage(lang);
if (Str.IsEmptyStr(Args) == false)
{
url += "?" + Args;
}
return url;
}
public string ProcStr(string str)
{
return ProcStr(str, ContentsPrintLanguage);
}
public static string ProcStrDefault(string str)
{
return ProcStr(str, CoreLanguageClass.CurrentThreadLanguageClass);
}
public static string ProcStr(string str, CoreLanguageClass lang)
{
return ProcStr(str, lang, lang);
}
public static string ProcStr(string str, CoreLanguageClass lang, CoreLanguageClass langPure)
{
MultiLanguageFilterStream st = new MultiLanguageFilterStream(null, lang, langPure, null, null);
return st.FilterString(str);
}
public static string GetCurrentLangCodeFromPath(string str)
{
char[] sps =
{
'/', '?',
};
string[] tokens = str.Split(sps, StringSplitOptions.RemoveEmptyEntries);
if (tokens.Length >= 1)
{
return tokens[0].ToLower();
}
return CoreLanguageList.Japanese.Name;
}
}
public static class MultiString
{
public const string ChangeLanguage = "[j]Select Language[e]Select Language[/]";
public const string LanguageNotSupported = "[j]申し訳ございませんが、以下のコンテンツは現在日本語で公開されていません。[e]Unfortunately, following contents are not published in English yet. [/]";
public const string ThisIsTranslatedByMachine = "Following contents are translated automatically by Google Translate.";
public const string GoogleTranslate = "[j]Google で翻訳[e]Click here to translate the contents into English by Google Now[/]";
public const string ShowSrc = "Show the original page";
public static string GetStr(string srcStr, CoreLanguageClass lang)
{
return MultiLang.ProcStr(srcStr, lang);
}
}
public class MultiLanguageFilterStream : Stream
{
public static readonly List<KeyValuePair<string, CoreLanguageClass>> langKeys = new List<KeyValuePair<string, CoreLanguageClass>>();
public readonly List<KeyValuePair<string, string>> ReplaceList = null;
public const string TagPure = "<!-- ml:pure -->";
public const string TagEndPure = "<!-- ml:endpure -->";
public bool DisableFilter = false;
public Page Page;
static MultiLanguageFilterStream()
{
langKeys.Add(new KeyValuePair<string, CoreLanguageClass>("[j]", CoreLanguageList.Japanese));
langKeys.Add(new KeyValuePair<string, CoreLanguageClass>("[e]", CoreLanguageList.English));
langKeys.Add(new KeyValuePair<string, CoreLanguageClass>("[/]", null));
}
Stack<CoreLanguageClass> stack = new Stack<CoreLanguageClass>();
CoreLanguageClass currentBodyLanguage
{
get
{
if (stack.Count == 0)
{
return null;
}
else
{
return stack.ToArray()[0];
}
}
}
bool isLang(CoreLanguageClass lang)
{
CoreLanguageClass[] langList = stack.ToArray();
foreach (CoreLanguageClass c in langList)
{
if (c != lang)
{
return false;
}
}
return true;
}
CoreLanguageClass lastBodyLanguage
{
get
{
if (stack.Count == 0)
{
return null;
}
else
{
return stack.Peek();
}
}
}
public string FilterString(string src)
{
string[] strList = Str.DivideStringMulti(src, true,
TagPure, TagEndPure);
bool b = false;
StringBuilder ret = new StringBuilder();
foreach (string str in strList)
{
if (str == TagPure)
{
b = true;
}
else if (str == TagEndPure)
{
b = false;
}
ret.Append(filterStringInner(str, b ? this.currentLanguagePure : this.currentLanguage, this.currentLanguagePure));
}
return ret.ToString();
}
string filterStringInner(string src, CoreLanguageClass useLang, CoreLanguageClass useLangPure)
{
int i;
string ret = src;
if (Str.IsEmptyStr(basicHostName) == false)
{
ret = Str.ReplaceStr(ret, "=\"/\"", "=\"http://" + basicHostName + "/\"", false);
ret = Str.ReplaceStr(ret, "=\'/\'", "=\'http://" + basicHostName + "/\'", false);
ret = Str.ReplaceStr(ret, "=\"/" + CoreLanguageList.Japanese.Name + "/\"", "=\"http://" + basicHostName + "/" + useLangPure.Name + "/\"", false);
ret = Str.ReplaceStr(ret, "=\'/" + CoreLanguageList.Japanese.Name + "/\'", "=\'http://" + basicHostName + "/" + useLangPure.Name + "/\'", false);
}
ret = Str.ReplaceStr(ret, "=\"/" + CoreLanguageList.Japanese.Name + "/", "=\"/" + useLangPure.Name + "/", false);
ret = Str.ReplaceStr(ret, "=\'/" + CoreLanguageList.Japanese.Name + "/", "=\'/" + useLangPure.Name + "/", false);
ret = Str.ReplaceStr(ret, "_lm_" + CoreLanguageList.Japanese.Name, "_lm_" + useLang.Name, false);
if (this.ReplaceList != null)
{
foreach (KeyValuePair<string, string> p in this.ReplaceList)
{
ret = Str.ReplaceStr(ret, p.Key, p.Value, false);
}
}
StringBuilder ret2 = new StringBuilder();
int next = 0;
while (true)
{
int min = int.MaxValue;
int j = -1;
for (i = 0; i < langKeys.Count; i++)
{
int r = Str.SearchStr(ret, langKeys[i].Key, next, false);
if (r != -1)
{
if (r < min)
{
j = i;
min = r;
}
}
}
if (j != -1)
{
KeyValuePair<string, CoreLanguageClass> v = langKeys[j];
if (currentBodyLanguage == null || isLang(useLang))
{
ret2.Append(ret.Substring(next, min - next));
}
if (v.Value != null)
{
if (lastBodyLanguage == null || v.Value.Id <= lastBodyLanguage.Id)
{
stack.Push(v.Value);
}
else
{
stack.Pop();
stack.Push(v.Value);
}
}
else
{
stack.Pop();
}
next = min + v.Key.Length;
}
else
{
if (currentBodyLanguage == null || isLang(useLang))
{
ret2.Append(ret.Substring(next, ret.Length - next));
}
break;
}
}
ret = ret2.ToString();
string lang = useLangPure != CoreLanguageList.Japanese ? useLangPure.Name : "ja";
if (useLangPure != CoreLanguageList.Japanese)
{
ret = Str.ReplaceStr(ret, "<meta http-equiv=\"Content-Language\" content=\"ja\" />",
string.Format("<meta http-equiv=\"Content-Language\" content=\"{0}\" />", lang), false);
}
ret = Str.ReplaceStr(ret, "<html>", string.Format("<html lang=\"{0}\">", lang), false);
next = 0;
while (true)
{
i = Str.SearchStr(ret, "<link rel=\"stylesheet\" href=\"", next, false);
if (i == -1)
{
break;
}
next = i + 1;
int j = Str.SearchStr(ret, "/>", next, false);
if (j == -1)
{
break;
}
string linkStr = ret.Substring(i, j - i + 2 - 1);
int k = Str.SearchStr(linkStr, "href=\"", 0, false);
if (k != -1)
{
int m = Str.SearchStr(linkStr, "\"", k + 6, false);
if (m != -1)
{
string fileName = linkStr.Substring(k + 6, m - k - 6);
fileName = Str.ReplaceStr(fileName, ".css", "_" + lang + ".css", false);
string linkStr2 = string.Format("<link rel=\"stylesheet\" href=\"{0}\" type=\"text/css\" />", fileName);
ret = ret.Substring(0, j + 2) + linkStr2 + ret.Substring(j + 2);
next = j + 2 + linkStr2.Length;
}
}
}
return ret;
}
Stream baseStream;
long position;
CoreLanguageClass currentLanguage;
CoreLanguageClass currentLanguagePure;
string basicHostName;
public override bool CanRead
{
get { return true; }
}
public override bool CanSeek
{
get { return true; }
}
public override bool CanWrite
{
get { return true; }
}
public override void Flush()
{
baseStream.Flush();
}
public override long Length
{
get { return 0; }
}
public override long Position
{
get
{
return position;
}
set
{
position = value;
}
}
public override long Seek(long offset, SeekOrigin origin)
{
return baseStream.Seek(offset, origin);
}
public override void SetLength(long value)
{
baseStream.SetLength(value);
}
public MultiLanguageFilterStream(Stream baseStream, CoreLanguageClass currentLanguage, CoreLanguageClass currentLanguagePure, string basicHostName, List<KeyValuePair<string, string>> replaceList)
{
this.baseStream = baseStream;
this.currentLanguage = currentLanguage;
this.currentLanguagePure = currentLanguagePure;
this.basicHostName = basicHostName;
this.ReplaceList = replaceList;
}
public override int Read(byte[] buffer, int offset, int count)
{
return baseStream.Read(buffer, offset, count);
}
string savedString = "";
public override void Write(byte[] buffer, int offset, int count)
{
if (DisableFilter)
{
baseStream.Write(buffer, offset, count);
return;
}
byte[] data = new byte[count];
Buffer.BlockCopy(buffer, offset, data, 0, count);
string inSrc = savedString + ByteDataToString(data);// Str.Utf8Encoding.GetString(data);
savedString = "";
if (inSrc.Length >= 2)
{
int len = inSrc.Length;
string last2 = inSrc.Substring(len - 2, 2);
string last1 = inSrc.Substring(len - 1, 1);
if (last1 == "[")
{
inSrc = inSrc.Substring(0, len - 1);
savedString = last1;
}
else if (Str.InStr(last2, "["))
{
inSrc = inSrc.Substring(0, len - 2);
savedString = last2;
}
}
string inStr = FilterString(inSrc);
data = StringToByteData(inStr);// Str.Utf8Encoding.GetBytes(inStr);
if (data.Length >= 1)
{
baseStream.Write(data, 0, data.Length);
//byte[] t = Str.Utf8Encoding.GetBytes("" + count.ToString() + "");
//baseStream.Write(t, 0, t.Length);
}
}
public static string ByteDataToString(byte[] data)
{
StringBuilder sb = new StringBuilder();
foreach (byte b in data)
{
if (b <= 0x7f && b != (byte)('\\'))
{
sb.Append((char)b);
}
else
{
sb.Append("\\" + ((uint)b).ToString("X2"));
}
}
return sb.ToString();
}
public byte[] StringToByteData(string str)
{
int i, len;
len = str.Length;
Buf b = new Buf();
for (i = 0; i < len; i++)
{
char c = str[i];
if (c == '\\')
{
string tmp = "";
//try
{
tmp = "" + str[i + 1] + str[i + 2];
}
/*catch (Exception ex)
{
tmp += "|err=" + ex.Message + ",len=" + len + ",i=" + i + "|src=" + str + "|";
byte[] aa = Str.Utf8Encoding.GetBytes(tmp);
b.Write(aa);
}*/
i += 2;
//try
{
b.WriteByte(byte.Parse(tmp, System.Globalization.NumberStyles.HexNumber));
}
//catch
{
}
}
else
{
b.WriteByte((byte)c);
}
}
return b.ByteData;
}
}

View File

@ -1,217 +0,0 @@
// CoreUtil
//
// Copyright (C) 2012-2014 Daiyuu Nobori. All Rights Reserved.
// Copyright (C) 2012-2014 SoftEther VPN Project at University of Tsukuba. All Rights Reserved.
//
// License: The Apache License, Version 2.0
// https://www.apache.org/licenses/LICENSE-2.0
//
// DISCLAIMER
// ==========
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
// SOFTWARE.
//
// THIS SOFTWARE IS DEVELOPED IN JAPAN, AND DISTRIBUTED FROM JAPAN, UNDER
// JAPANESE LAWS. YOU MUST AGREE IN ADVANCE TO USE, COPY, MODIFY, MERGE, PUBLISH,
// DISTRIBUTE, SUBLICENSE, AND/OR SELL COPIES OF THIS SOFTWARE, THAT ANY
// JURIDICAL DISPUTES WHICH ARE CONCERNED TO THIS SOFTWARE OR ITS CONTENTS,
// AGAINST US (SOFTETHER PROJECT, SOFTETHER CORPORATION, DAIYUU NOBORI OR OTHER
// SUPPLIERS), OR ANY JURIDICAL DISPUTES AGAINST US WHICH ARE CAUSED BY ANY KIND
// OF USING, COPYING, MODIFYING, MERGING, PUBLISHING, DISTRIBUTING, SUBLICENSING,
// AND/OR SELLING COPIES OF THIS SOFTWARE SHALL BE REGARDED AS BE CONSTRUED AND
// CONTROLLED BY JAPANESE LAWS, AND YOU MUST FURTHER CONSENT TO EXCLUSIVE
// JURISDICTION AND VENUE IN THE COURTS SITTING IN TOKYO, JAPAN. YOU MUST WAIVE
// ALL DEFENSES OF LACK OF PERSONAL JURISDICTION AND FORUM NON CONVENIENS.
// PROCESS MAY BE SERVED ON EITHER PARTY IN THE MANNER AUTHORIZED BY APPLICABLE
// LAW OR COURT RULE.
//
// USE ONLY IN JAPAN. DO NOT USE THIS SOFTWARE IN ANOTHER COUNTRY UNLESS YOU HAVE
// A CONFIRMATION THAT THIS SOFTWARE DOES NOT VIOLATE ANY CRIMINAL LAWS OR CIVIL
// RIGHTS IN THAT PARTICULAR COUNTRY. USING THIS SOFTWARE IN OTHER COUNTRIES IS
// COMPLETELY AT YOUR OWN RISK. THE SOFTETHER VPN PROJECT HAS DEVELOPED AND
// DISTRIBUTED THIS SOFTWARE TO COMPLY ONLY WITH THE JAPANESE LAWS AND EXISTING
// CIVIL RIGHTS INCLUDING PATENTS WHICH ARE SUBJECTS APPLY IN JAPAN. OTHER
// COUNTRIES' LAWS OR CIVIL RIGHTS ARE NONE OF OUR CONCERNS NOR RESPONSIBILITIES.
// WE HAVE NEVER INVESTIGATED ANY CRIMINAL REGULATIONS, CIVIL LAWS OR
// INTELLECTUAL PROPERTY RIGHTS INCLUDING PATENTS IN ANY OF OTHER 200+ COUNTRIES
// AND TERRITORIES. BY NATURE, THERE ARE 200+ REGIONS IN THE WORLD, WITH
// DIFFERENT LAWS. IT IS IMPOSSIBLE TO VERIFY EVERY COUNTRIES' LAWS, REGULATIONS
// AND CIVIL RIGHTS TO MAKE THE SOFTWARE COMPLY WITH ALL COUNTRIES' LAWS BY THE
// PROJECT. EVEN IF YOU WILL BE SUED BY A PRIVATE ENTITY OR BE DAMAGED BY A
// PUBLIC SERVANT IN YOUR COUNTRY, THE DEVELOPERS OF THIS SOFTWARE WILL NEVER BE
// LIABLE TO RECOVER OR COMPENSATE SUCH DAMAGES, CRIMINAL OR CIVIL
// RESPONSIBILITIES. NOTE THAT THIS LINE IS NOT LICENSE RESTRICTION BUT JUST A
// STATEMENT FOR WARNING AND DISCLAIMER.
//
// READ AND UNDERSTAND THE 'WARNING.TXT' FILE BEFORE USING THIS SOFTWARE.
// SOME SOFTWARE PROGRAMS FROM THIRD PARTIES ARE INCLUDED ON THIS SOFTWARE WITH
// LICENSE CONDITIONS WHICH ARE DESCRIBED ON THE 'THIRD_PARTY.TXT' FILE.
//
//
// SOURCE CODE CONTRIBUTION
// ------------------------
//
// Your contribution to SoftEther VPN Project is much appreciated.
// Please send patches to us through GitHub.
// Read the SoftEther VPN Patch Acceptance Policy in advance:
// http://www.softether.org/5-download/src/9.patch
//
//
// DEAR SECURITY EXPERTS
// ---------------------
//
// If you find a bug or a security vulnerability please kindly inform us
// about the problem immediately so that we can fix the security problem
// to protect a lot of users around the world as soon as possible.
//
// Our e-mail address for security reports is:
// softether-vpn-security [at] softether.org
//
// Please note that the above e-mail address is not a technical support
// inquiry address. If you need technical assistance, please visit
// http://www.softether.org/ and ask your question on the users forum.
//
// Thank you for your cooperation.
//
//
// NO MEMORY OR RESOURCE LEAKS
// ---------------------------
//
// The memory-leaks and resource-leaks verification under the stress
// test has been passed before release this source code.
using System;
using System.Threading;
using System.Data;
using System.Data.Sql;
using System.Data.SqlClient;
using System.Data.SqlTypes;
using System.Text;
using System.Configuration;
using System.Collections;
using System.Collections.Generic;
using System.Security.Cryptography;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.IO;
using System.Drawing;
using System.Drawing.Imaging;
using System.Drawing.Drawing2D;
using System.Runtime.InteropServices;
namespace CoreUtil
{
public enum PackerFileFormat
{
ZipRaw,
ZipCompressed,
Tar,
TarGZip,
}
public delegate bool ProgressDelegate(string fileNameFullPath, string fileNameRelative, int currentFileNum, int totalFileNum);
public static class Packer
{
public static byte[] PackDir(PackerFileFormat format, string rootDirPath, string appendPrefixDirName)
{
return PackDir(format, rootDirPath, appendPrefixDirName, null);
}
public static byte[] PackDir(PackerFileFormat format, string topDirPath, string appendPrefixDirName, ProgressDelegate proc)
{
string[] fileList = Directory.GetFiles(topDirPath, "*", SearchOption.AllDirectories);
List<string> relativeFileList = new List<string>();
foreach (string fileName in fileList)
{
string relativePath = IO.GetRelativeFileName(fileName, topDirPath);
if (Str.IsEmptyStr(appendPrefixDirName) == false)
{
relativePath = IO.RemoteLastEnMark(appendPrefixDirName) + "\\" + relativePath;
}
relativeFileList.Add(relativePath);
}
return PackFiles(format, fileList, relativeFileList.ToArray(), proc);
}
public static byte[] PackFiles(PackerFileFormat format, string[] srcFileNameList, string[] relativeNameList)
{
return PackFiles(format, srcFileNameList, relativeNameList, null);
}
public static byte[] PackFiles(PackerFileFormat format, string[] srcFileNameList, string[] relativeNameList, ProgressDelegate proc)
{
if (srcFileNameList.Length != relativeNameList.Length)
{
throw new ApplicationException("srcFileNameList.Length != relativeNameList.Length");
}
int num = srcFileNameList.Length;
int i;
ZipPacker zip = new ZipPacker();
TarPacker tar = new TarPacker();
for (i = 0; i < num; i++)
{
if (proc != null)
{
bool ret = proc(srcFileNameList[i], relativeNameList[i], i, num);
if (ret == false)
{
continue;
}
}
byte[] srcData = File.ReadAllBytes(srcFileNameList[i]);
DateTime date = File.GetLastWriteTime(srcFileNameList[i]);
switch (format)
{
case PackerFileFormat.Tar:
case PackerFileFormat.TarGZip:
tar.AddFileSimple(relativeNameList[i], srcData, 0, srcData.Length, date);
break;
case PackerFileFormat.ZipRaw:
case PackerFileFormat.ZipCompressed:
zip.AddFileSimple(relativeNameList[i], date, FileAttributes.Normal, srcData, (format == PackerFileFormat.ZipCompressed));
break;
}
}
switch (format)
{
case PackerFileFormat.Tar:
tar.Finish();
return tar.GeneratedData.Read();
case PackerFileFormat.TarGZip:
tar.Finish();
return tar.CompressToGZip();
case PackerFileFormat.ZipCompressed:
case PackerFileFormat.ZipRaw:
zip.Finish();
return zip.GeneratedData.Read();
default:
throw new ApplicationException("format");
}
}
}
}

View File

@ -1,240 +0,0 @@
// CoreUtil
//
// Copyright (C) 2012-2014 Daiyuu Nobori. All Rights Reserved.
// Copyright (C) 2012-2014 SoftEther VPN Project at University of Tsukuba. All Rights Reserved.
//
// License: The Apache License, Version 2.0
// https://www.apache.org/licenses/LICENSE-2.0
//
// DISCLAIMER
// ==========
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
// SOFTWARE.
//
// THIS SOFTWARE IS DEVELOPED IN JAPAN, AND DISTRIBUTED FROM JAPAN, UNDER
// JAPANESE LAWS. YOU MUST AGREE IN ADVANCE TO USE, COPY, MODIFY, MERGE, PUBLISH,
// DISTRIBUTE, SUBLICENSE, AND/OR SELL COPIES OF THIS SOFTWARE, THAT ANY
// JURIDICAL DISPUTES WHICH ARE CONCERNED TO THIS SOFTWARE OR ITS CONTENTS,
// AGAINST US (SOFTETHER PROJECT, SOFTETHER CORPORATION, DAIYUU NOBORI OR OTHER
// SUPPLIERS), OR ANY JURIDICAL DISPUTES AGAINST US WHICH ARE CAUSED BY ANY KIND
// OF USING, COPYING, MODIFYING, MERGING, PUBLISHING, DISTRIBUTING, SUBLICENSING,
// AND/OR SELLING COPIES OF THIS SOFTWARE SHALL BE REGARDED AS BE CONSTRUED AND
// CONTROLLED BY JAPANESE LAWS, AND YOU MUST FURTHER CONSENT TO EXCLUSIVE
// JURISDICTION AND VENUE IN THE COURTS SITTING IN TOKYO, JAPAN. YOU MUST WAIVE
// ALL DEFENSES OF LACK OF PERSONAL JURISDICTION AND FORUM NON CONVENIENS.
// PROCESS MAY BE SERVED ON EITHER PARTY IN THE MANNER AUTHORIZED BY APPLICABLE
// LAW OR COURT RULE.
//
// USE ONLY IN JAPAN. DO NOT USE THIS SOFTWARE IN ANOTHER COUNTRY UNLESS YOU HAVE
// A CONFIRMATION THAT THIS SOFTWARE DOES NOT VIOLATE ANY CRIMINAL LAWS OR CIVIL
// RIGHTS IN THAT PARTICULAR COUNTRY. USING THIS SOFTWARE IN OTHER COUNTRIES IS
// COMPLETELY AT YOUR OWN RISK. THE SOFTETHER VPN PROJECT HAS DEVELOPED AND
// DISTRIBUTED THIS SOFTWARE TO COMPLY ONLY WITH THE JAPANESE LAWS AND EXISTING
// CIVIL RIGHTS INCLUDING PATENTS WHICH ARE SUBJECTS APPLY IN JAPAN. OTHER
// COUNTRIES' LAWS OR CIVIL RIGHTS ARE NONE OF OUR CONCERNS NOR RESPONSIBILITIES.
// WE HAVE NEVER INVESTIGATED ANY CRIMINAL REGULATIONS, CIVIL LAWS OR
// INTELLECTUAL PROPERTY RIGHTS INCLUDING PATENTS IN ANY OF OTHER 200+ COUNTRIES
// AND TERRITORIES. BY NATURE, THERE ARE 200+ REGIONS IN THE WORLD, WITH
// DIFFERENT LAWS. IT IS IMPOSSIBLE TO VERIFY EVERY COUNTRIES' LAWS, REGULATIONS
// AND CIVIL RIGHTS TO MAKE THE SOFTWARE COMPLY WITH ALL COUNTRIES' LAWS BY THE
// PROJECT. EVEN IF YOU WILL BE SUED BY A PRIVATE ENTITY OR BE DAMAGED BY A
// PUBLIC SERVANT IN YOUR COUNTRY, THE DEVELOPERS OF THIS SOFTWARE WILL NEVER BE
// LIABLE TO RECOVER OR COMPENSATE SUCH DAMAGES, CRIMINAL OR CIVIL
// RESPONSIBILITIES. NOTE THAT THIS LINE IS NOT LICENSE RESTRICTION BUT JUST A
// STATEMENT FOR WARNING AND DISCLAIMER.
//
// READ AND UNDERSTAND THE 'WARNING.TXT' FILE BEFORE USING THIS SOFTWARE.
// SOME SOFTWARE PROGRAMS FROM THIRD PARTIES ARE INCLUDED ON THIS SOFTWARE WITH
// LICENSE CONDITIONS WHICH ARE DESCRIBED ON THE 'THIRD_PARTY.TXT' FILE.
//
//
// SOURCE CODE CONTRIBUTION
// ------------------------
//
// Your contribution to SoftEther VPN Project is much appreciated.
// Please send patches to us through GitHub.
// Read the SoftEther VPN Patch Acceptance Policy in advance:
// http://www.softether.org/5-download/src/9.patch
//
//
// DEAR SECURITY EXPERTS
// ---------------------
//
// If you find a bug or a security vulnerability please kindly inform us
// about the problem immediately so that we can fix the security problem
// to protect a lot of users around the world as soon as possible.
//
// Our e-mail address for security reports is:
// softether-vpn-security [at] softether.org
//
// Please note that the above e-mail address is not a technical support
// inquiry address. If you need technical assistance, please visit
// http://www.softether.org/ and ask your question on the users forum.
//
// Thank you for your cooperation.
//
//
// NO MEMORY OR RESOURCE LEAKS
// ---------------------------
//
// The memory-leaks and resource-leaks verification under the stress
// test has been passed before release this source code.
using System;
using System.Threading;
using System.Data;
using System.Data.Sql;
using System.Data.SqlClient;
using System.Data.SqlTypes;
using System.Text;
using System.Configuration;
using System.Collections;
using System.Collections.Generic;
using System.Security.Cryptography;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.IO;
using System.Drawing;
using System.Drawing.Imaging;
using System.Drawing.Drawing2D;
using System.Diagnostics;
using System.Web.Mail;
using System.Net;
using System.Net.Sockets;
using System.Net.NetworkInformation;
namespace CoreUtil
{
public class RC4 : ICloneable
{
uint x, y;
uint[] state;
public RC4(byte[] key)
{
state = new uint[256];
uint i, t, u, ki, si;
x = 0;
y = 0;
for (i = 0; i < 256; i++)
{
state[i] = i;
}
ki = si = 0;
for (i = 0; i < 256; i++)
{
t = state[i];
si = (si + key[ki] + t) & 0xff;
u = state[si];
state[si] = t;
state[i] = u;
if (++ki >= key.Length)
{
ki = 0;
}
}
}
private RC4()
{
}
public object Clone()
{
RC4 rc4 = new RC4();
rc4.x = this.x;
rc4.y = this.y;
rc4.state = (uint[])this.state.Clone();
return rc4;
}
public byte[] Encrypt(byte[] src)
{
return Encrypt(src, src.Length);
}
public byte[] Encrypt(byte[] src, int len)
{
return Encrypt(src, 0, len);
}
public byte[] Encrypt(byte[] src, int offset, int len)
{
byte[] dst = new byte[len];
uint x, y, sx, sy;
x = this.x;
y = this.y;
int src_i = 0, dst_i = 0, end_src_i;
for (end_src_i = src_i + len; src_i != end_src_i; src_i++, dst_i++)
{
x = (x + 1) & 0xff;
sx = state[x];
y = (sx + y) & 0xff;
state[x] = sy = state[y];
state[y] = sx;
dst[dst_i] = (byte)(src[src_i + offset] ^ state[(sx + sy) & 0xff]);
}
this.x = x;
this.y = y;
return dst;
}
public void SkipDecrypt(int len)
{
SkipEncrypt(len);
}
public void SkipEncrypt(int len)
{
uint x, y, sx, sy;
x = this.x;
y = this.y;
int src_i = 0, dst_i = 0, end_src_i;
for (end_src_i = src_i + len; src_i != end_src_i; src_i++, dst_i++)
{
x = (x + 1) & 0xff;
sx = state[x];
y = (sx + y) & 0xff;
state[x] = sy = state[y];
state[y] = sx;
}
this.x = x;
this.y = y;
}
public byte[] Decrypt(byte[] src)
{
return Decrypt(src, src.Length);
}
public byte[] Decrypt(byte[] src, int len)
{
return Decrypt(src, 0, len);
}
public byte[] Decrypt(byte[] src, int offset, int len)
{
return Encrypt(src, offset, len);
}
}
}

View File

@ -1,321 +0,0 @@
// CoreUtil
//
// Copyright (C) 2012-2014 Daiyuu Nobori. All Rights Reserved.
// Copyright (C) 2012-2014 SoftEther VPN Project at University of Tsukuba. All Rights Reserved.
//
// License: The Apache License, Version 2.0
// https://www.apache.org/licenses/LICENSE-2.0
//
// DISCLAIMER
// ==========
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
// SOFTWARE.
//
// THIS SOFTWARE IS DEVELOPED IN JAPAN, AND DISTRIBUTED FROM JAPAN, UNDER
// JAPANESE LAWS. YOU MUST AGREE IN ADVANCE TO USE, COPY, MODIFY, MERGE, PUBLISH,
// DISTRIBUTE, SUBLICENSE, AND/OR SELL COPIES OF THIS SOFTWARE, THAT ANY
// JURIDICAL DISPUTES WHICH ARE CONCERNED TO THIS SOFTWARE OR ITS CONTENTS,
// AGAINST US (SOFTETHER PROJECT, SOFTETHER CORPORATION, DAIYUU NOBORI OR OTHER
// SUPPLIERS), OR ANY JURIDICAL DISPUTES AGAINST US WHICH ARE CAUSED BY ANY KIND
// OF USING, COPYING, MODIFYING, MERGING, PUBLISHING, DISTRIBUTING, SUBLICENSING,
// AND/OR SELLING COPIES OF THIS SOFTWARE SHALL BE REGARDED AS BE CONSTRUED AND
// CONTROLLED BY JAPANESE LAWS, AND YOU MUST FURTHER CONSENT TO EXCLUSIVE
// JURISDICTION AND VENUE IN THE COURTS SITTING IN TOKYO, JAPAN. YOU MUST WAIVE
// ALL DEFENSES OF LACK OF PERSONAL JURISDICTION AND FORUM NON CONVENIENS.
// PROCESS MAY BE SERVED ON EITHER PARTY IN THE MANNER AUTHORIZED BY APPLICABLE
// LAW OR COURT RULE.
//
// USE ONLY IN JAPAN. DO NOT USE THIS SOFTWARE IN ANOTHER COUNTRY UNLESS YOU HAVE
// A CONFIRMATION THAT THIS SOFTWARE DOES NOT VIOLATE ANY CRIMINAL LAWS OR CIVIL
// RIGHTS IN THAT PARTICULAR COUNTRY. USING THIS SOFTWARE IN OTHER COUNTRIES IS
// COMPLETELY AT YOUR OWN RISK. THE SOFTETHER VPN PROJECT HAS DEVELOPED AND
// DISTRIBUTED THIS SOFTWARE TO COMPLY ONLY WITH THE JAPANESE LAWS AND EXISTING
// CIVIL RIGHTS INCLUDING PATENTS WHICH ARE SUBJECTS APPLY IN JAPAN. OTHER
// COUNTRIES' LAWS OR CIVIL RIGHTS ARE NONE OF OUR CONCERNS NOR RESPONSIBILITIES.
// WE HAVE NEVER INVESTIGATED ANY CRIMINAL REGULATIONS, CIVIL LAWS OR
// INTELLECTUAL PROPERTY RIGHTS INCLUDING PATENTS IN ANY OF OTHER 200+ COUNTRIES
// AND TERRITORIES. BY NATURE, THERE ARE 200+ REGIONS IN THE WORLD, WITH
// DIFFERENT LAWS. IT IS IMPOSSIBLE TO VERIFY EVERY COUNTRIES' LAWS, REGULATIONS
// AND CIVIL RIGHTS TO MAKE THE SOFTWARE COMPLY WITH ALL COUNTRIES' LAWS BY THE
// PROJECT. EVEN IF YOU WILL BE SUED BY A PRIVATE ENTITY OR BE DAMAGED BY A
// PUBLIC SERVANT IN YOUR COUNTRY, THE DEVELOPERS OF THIS SOFTWARE WILL NEVER BE
// LIABLE TO RECOVER OR COMPENSATE SUCH DAMAGES, CRIMINAL OR CIVIL
// RESPONSIBILITIES. NOTE THAT THIS LINE IS NOT LICENSE RESTRICTION BUT JUST A
// STATEMENT FOR WARNING AND DISCLAIMER.
//
// READ AND UNDERSTAND THE 'WARNING.TXT' FILE BEFORE USING THIS SOFTWARE.
// SOME SOFTWARE PROGRAMS FROM THIRD PARTIES ARE INCLUDED ON THIS SOFTWARE WITH
// LICENSE CONDITIONS WHICH ARE DESCRIBED ON THE 'THIRD_PARTY.TXT' FILE.
//
//
// SOURCE CODE CONTRIBUTION
// ------------------------
//
// Your contribution to SoftEther VPN Project is much appreciated.
// Please send patches to us through GitHub.
// Read the SoftEther VPN Patch Acceptance Policy in advance:
// http://www.softether.org/5-download/src/9.patch
//
//
// DEAR SECURITY EXPERTS
// ---------------------
//
// If you find a bug or a security vulnerability please kindly inform us
// about the problem immediately so that we can fix the security problem
// to protect a lot of users around the world as soon as possible.
//
// Our e-mail address for security reports is:
// softether-vpn-security [at] softether.org
//
// Please note that the above e-mail address is not a technical support
// inquiry address. If you need technical assistance, please visit
// http://www.softether.org/ and ask your question on the users forum.
//
// Thank you for your cooperation.
//
//
// NO MEMORY OR RESOURCE LEAKS
// ---------------------------
//
// The memory-leaks and resource-leaks verification under the stress
// test has been passed before release this source code.
using System;
using System.Threading;
using System.Data;
using System.Data.Sql;
using System.Data.SqlClient;
using System.Data.SqlTypes;
using System.Text;
using System.Configuration;
using System.Collections;
using System.Collections.Generic;
using System.Security.Cryptography;
using System.Security.Cryptography.X509Certificates;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.IO;
using System.Drawing;
using System.Drawing.Imaging;
using System.Drawing.Drawing2D;
using System.Web.Mail;
namespace CoreUtil
{
class IniCache
{
static Dictionary<string, IniCacheEntry> caches = new Dictionary<string, IniCacheEntry>();
class IniCacheEntry
{
DateTime lastUpdate;
public DateTime LastUpdate
{
get { return lastUpdate; }
}
Dictionary<string, string> datas;
public Dictionary<string, string> Datas
{
get { return datas; }
}
public IniCacheEntry(DateTime lastUpdate, Dictionary<string, string> datas)
{
this.lastUpdate = lastUpdate;
this.datas = datas;
}
}
public static Dictionary<string, string> GetCache(string filename, DateTime lastUpdate)
{
lock (caches)
{
try
{
IniCacheEntry e = caches[filename];
if (e.LastUpdate == lastUpdate || lastUpdate.Ticks == 0)
{
return e.Datas;
}
else
{
return null;
}
}
catch
{
return null;
}
}
}
public static void AddCache(string filename, DateTime lastUpdate, Dictionary<string, string> datas)
{
lock (caches)
{
if (caches.ContainsKey(filename))
{
caches.Remove(filename);
}
caches.Add(filename, new IniCacheEntry(lastUpdate, datas));
}
}
}
public class ReadIni
{
Dictionary<string, string> datas;
bool updated;
public bool Updated
{
get
{
return updated;
}
}
public StrData this[string key]
{
get
{
string s;
try
{
s = datas[key.ToUpper()];
}
catch
{
s = null;
}
return new StrData(s);
}
}
public string[] GetKeys()
{
List<string> ret = new List<string>();
foreach (string s in datas.Keys)
{
ret.Add(s);
}
return ret.ToArray();
}
public ReadIni(string filename)
{
init(null, filename);
}
void init(byte[] data)
{
init(data, null);
}
void init(byte[] data, string filename)
{
updated = false;
lock (typeof(ReadIni))
{
string[] lines;
string srcstr;
DateTime lastUpdate = new DateTime(0);
if (filename != null)
{
lastUpdate = IO.GetLastWriteTimeUtc(filename);
datas = IniCache.GetCache(filename, lastUpdate);
}
if (datas == null)
{
if (data == null)
{
try
{
data = Buf.ReadFromFile(filename).ByteData;
}
catch
{
data = new byte[0];
datas = IniCache.GetCache(filename, new DateTime());
}
}
if (datas == null)
{
datas = new Dictionary<string, string>();
Encoding currentEncoding = Str.Utf8Encoding;
srcstr = currentEncoding.GetString(data);
lines = Str.GetLines(srcstr);
foreach (string s in lines)
{
string line = s.Trim();
if (Str.IsEmptyStr(line) == false)
{
if (line.StartsWith("#") == false &&
line.StartsWith("//") == false &&
line.StartsWith(";") == false)
{
string key, value;
if (Str.GetKeyAndValue(line, out key, out value))
{
key = key.ToUpper();
if (datas.ContainsKey(key) == false)
{
datas.Add(key, value);
}
else
{
int i;
for (i = 1; ; i++)
{
string key2 = string.Format("{0}({1})", key, i).ToUpper();
if (datas.ContainsKey(key2) == false)
{
datas.Add(key2, value);
break;
}
}
}
}
}
}
}
if (filename != null)
{
IniCache.AddCache(filename, lastUpdate, datas);
}
updated = true;
}
}
}
}
}
}

Some files were not shown because too many files have changed in this diff Show More