1
0
mirror of https://github.com/SoftEtherVPN/SoftEtherVPN.git synced 2024-09-20 02:30:40 +03:00
Commit Graph

136 Commits

Author SHA1 Message Date
Max Miroshnikov
e6d94dfca9 [vpncmd] Added DISABLEUDP option into AccountDetailSet command. This allows to change "Disable UDP acceleration" via vpncmd. #308 (#389) 2018-05-14 10:08:58 +02:00
Ilya Shipitsin
f5645fe3fd resolve several issues found by cppcheck (#483)
[src/Cedar/Connection.c:1090] -> [src/Cedar/Connection.c:1086]:
(warning) Either the condition 's!=NULL' is redundant or there is possible null pointer dereference: s.

macros IS_SEND_TCP_SOCK expands into "s" dereferencing, so check for NULL should go before that macros

[src/Cedar/Protocol.c:2951] -> [src/Cedar/Protocol.c:2892]:
(warning) Either the condition 'policy!=NULL' is redundant or there is possible null pointer dereference: policy.
[src/Cedar/Protocol.c:2951] -> [src/Cedar/Protocol.c:2901]:
(warning) Either the condition 'policy!=NULL' is redundant or there is possible null pointer dereference: policy.
[src/Cedar/Protocol.c:3151] -> [src/Cedar/Protocol.c:3082]:
(warning) Either the condition 'policy!=NULL' is redundant or there is possible null pointer dereference: policy.
[src/Cedar/Protocol.c:3151] -> [src/Cedar/Protocol.c:3083]:
(warning) Either the condition 'policy!=NULL' is redundant or there is possible null pointer dereference: policy.

as we already have a check

			if (policy == NULL)
			{
				// Use the default policy
				policy = ClonePolicy(GetDefaultPolicy());
                        }

no need to compare policy with NULL anymore
2018-05-14 10:00:25 +02:00
Michael Clausen
e6099abe40 Peer info optional in OvsParseKeyMethod2() (#355)
* Peer info optional in OvsParseKeyMethod2()

Some OpenVPN clients (MikroTik router for example) do not send the peer info along with the key exchange. This patch makes the peer info string optional on the SoftEtherVPN side.

* Fixed indentation
2018-05-03 23:31:07 +02:00
Davide Beatrici
59c817e0fc OpenVPN: don't generate dummy certificates (#521)
* Cedar: don't generate dummy certificate

* hamcore: comment out <cert> and <key> in openvpn_sample.ovpn
2018-05-03 13:44:51 +02:00
Tim Schneider
bc2efe9efd SMB Winbind NT Authentication (Password/MsCHAPv2) (#49)
Added Linux NT Authentication functionality to SoftEther through samba ntlm_auth.

Pre requirements
+ samba-winbind -> Domain Member
+ winbind-seperator \ -> used for group check in ntlm_auth

username from client: fqdn domain\username
username in SoftEther: username
timeout: from security policy
optional: set groupname in servermanager
2018-05-02 23:42:04 +02:00
tonychung00
8ddd328762 initial fix for clang warnings (#84) 2018-04-20 23:03:26 +02:00
Moataz Elmasry
12a30cbbe2
remove msvc compiling errors (#499) 2018-04-20 01:19:32 +02:00
Maks Naumov
3f553abf1d Use correct sizeof value (#426)
* Use correct sizeof() value

* Use correct size for Zero()
2018-04-11 22:53:59 +02:00
Ilya Shipitsin
596493e1a1 resolve several issues identified by cppcheck (#465)
[src/Cedar/Admin.c:13452] -> [src/Cedar/Admin.c:13492]: (warning) Either the condition 'cedar!=NULL' is redundant or there is possible null pointer dereference: cedar.
[src/Cedar/SM.c:18455] -> [src/Cedar/SM.c:18379]: (warning) Either the condition 'p!=NULL' is redundant or there is possible null pointer dereference: p.
[src/Cedar/SM.c:18455] -> [src/Cedar/SM.c:18491]: (warning) Either the condition 'p!=NULL' is redundant or there is possible null pointer dereference: p.
[src/Cedar/SM.c:18455] -> [src/Cedar/SM.c:18506]: (warning) Either the condition 'p!=NULL' is redundant or there is possible null pointer dereference: p.
[src/Cedar/Protocol.c:5190] -> [src/Cedar/Protocol.c:5115]: (warning) Either the condition 's!=NULL' is redundant or there is possible null pointer dereference: s.
[src/Cedar/Protocol.c:5190] -> [src/Cedar/Protocol.c:5145]: (warning) Either the condition 's!=NULL' is redundant or there is possible null pointer dereference: s.
[src/Cedar/Hub.c:5517] -> [src/Cedar/Hub.c:5553]: (warning) Either the condition 'dest!=NULL' is redundant or there is possible null pointer dereference: dest.
[src/Cedar/Hub.c:5517] -> [src/Cedar/Hub.c:5556]: (warning) Either the condition 'dest!=NULL' is redundant or there is possible null pointer dereference: dest.
2018-04-11 00:08:31 +02:00
Alexey Kryuchkov
83295bb736 OpenVPN client certificate authentication (Individual Certificate Authentication) (#327)
* Implement OpenVPN certificate authentication, fixes #55

* fixup! Implement OpenVPN certificate authentication, fixes #55
2018-04-05 23:04:58 +02:00
Moataz Elmasry
9ad254115f Merge PR #154 Add Traditional Chinese language translation into master 2018-02-15 22:10:02 +01:00
Moataz Elmasry
e04ec3b203 Incrementing Version of SoftEther to 5.1. Preparing for release 2018-02-14 23:26:05 +01:00
Ilya Shipitsin
79c06146a4 remove unused functions (identified by cppcheck)
[src/Cedar/Account.c:854]: (style) The function 'AddGroupTraffic' is never used.
[src/Mayaqua/Secure.c:1455]: (style) The function 'AddSecObjToEnumCache' is never used.
[src/Mayaqua/Network.c:18445]: (style) The function 'AddSockList' is never used.
[src/Cedar/Account.c:870]: (style) The function 'AddUserTraffic' is never used.
[src/Cedar/Server.c:1045]: (style) The function 'AdjoinEnumLogFile' is never used.
[src/Cedar/Admin.c:13780]: (style) The function 'AdminConnect' is never used.
[src/Mayaqua/Encrypt.c:855]: (style) The function 'BigNumToStr' is never used.
[src/Mayaqua/Str.c:2113]: (style) The function 'Bit128ToStr' is never used.
[src/Mayaqua/Encrypt.c:898]: (style) The function 'BufToBigNum' is never used.
[src/Mayaqua/Internat.c:1874]: (style) The function 'CalcStrToUtf8' is never used.
[src/Cedar/Hub.c:6689]: (style) The function 'CalcTrafficDiff' is never used.
[src/Mayaqua/Internat.c:1819]: (style) The function 'CalcUtf8ToStr' is never used.
[src/Mayaqua/Network.c:6495]: (style) The function 'CanGetTcpProcessId' is never used.
[src/Cedar/WinUi.c:7226]: (style) The function 'CbInsertStrA' is never used.
[src/Cedar/Client.c:3035]: (style) The function 'CcEnumObjectInSecure' is never used.
[src/Cedar/Client.c:2826]: (style) The function 'CcGetCommonProxySetting' is never used.
[src/Cedar/Client.c:2857]: (style) The function 'CcSetCommonProxySetting' is never used.
[src/Cedar/Cedar.c:575]: (style) The function 'CedarLog' is never used.
[src/Cedar/WinUi.c:9841]: (style) The function 'Center2' is never used.
[src/Mayaqua/Encrypt.c:814]: (style) The function 'CertTest' is never used.
[src/Mayaqua/Encrypt.c:809]: (style) The function 'CertTest2' is never used.
[src/Mayaqua/Encrypt.c:819]: (style) The function 'CertTest_' is never used.
[src/Mayaqua/Cfg.c:1705]: (style) The function 'CfgIsFolder' is never used.
2018-02-08 00:20:07 +01:00
Guanzhong Chen
56c4582da8 Allow specifying cipher suites instead of single ciphers (#343)
* Allow specifying cipher suites instead of single ciphers.

CipherName now specifies all cipher suites instead of the
preferred cipher. This allows insecure ciphers like RC4 to
be permanently disabled, instead of being the default fallback
when the preferred cipher is unsupported.

CipherName is now left for OpenSSL to verify. Should it be
invalid, a secure default is used. The default CipherName setting
for new servers is one such invalid string: "~DEFAULT~". This
allows for future updates to change the default and the servers
can stay secure.

* Remove unused temporary variable.
2018-02-08 00:13:41 +01:00
Moataz Elmasry
a5fa265811
Merge pull request #275 from chipitsine/master
cppcheck findings
2018-02-01 00:06:08 +01:00
Moataz Elmasry
93d9ade990 Merge PR #129 into master. 2018-01-25 02:55:11 +01:00
Maks Naumov
ea4bb811ef Fix log msg for IKE with agressive exchange mode (#425) 2018-01-23 17:42:20 +01:00
Daiyuu Nobori
7de986dcca 7 missing memory boundaries checks and similar memory problems. There are no risk of arbitrary code execution or intrusion on these bugs in my analysis. However, these problems may lead to crash the running server process. So these bugs must be fixed.
Buffer overread in ParseL2TPPacket()
Memory corruption in IcmpParseResult
Missing bounds check in ParseUDP() can lead to invalid memory access
Out-of-bounds read in IPsec_PPP.c (unterminated string buffer)
Overlapping parameters to memcpy() via StrToIp6()
PACK ReadValue() crash vulnerability
Potential use of uninitialized memory via IPToInAddr6()

4 memory leaks. While the amount of leakage is very small per time, these bugs can finally cause process crash by out of memory. So these bugs must be fixed.

Memory leak in NnReadDnsRecord
Memory leak in RadiusLogin()
Memory leak via ParsePacketIPv4WithDummyMacHeader
Remote memory leak in OpenVPN server code

1 coding improvement. This is not a bug, however, I fixed the code to avoid furture misunderstanding.

RecvAll can return success on failure (leading to use of uninitialized memory)

Contributors for this bugfix:

- Max Planck Institute for Molecular Genetics
- Guido Vranken
2018-01-15 10:25:10 +09:00
macvk
ab4b27ab3c Add parameter "ListenIP" to server configuration (vpn_server.config) (#202)
* Added parameter "ListenIP" to server configuration (vpn_server.config)

* Fixed bug in VPN client
2018-01-11 23:53:38 +01:00
Daiyuu Nobori
bb30535bb6 Fix the function name: RFC3164 -> RFC3339 2017-12-21 23:24:06 +09:00
Daiyuu Nobori
97e7a82be2 Added the function to save the DNS query log on the packet logs. 2017-12-21 23:23:17 +09:00
Daiyuu Nobori
4a01c41d09 Fixed the bug which occurs the L2TP/IPsec connection error with Android Oreo. 2017-12-21 23:21:31 +09:00
holoreimu
b8f0dd9e80 align the code and update some translations
*align the code to have same amout of space
*update some translation to latest version
2017-12-02 06:04:57 +08:00
Holoreimu
39c1081d38
Merge pull request #1 from SoftEtherVPN/master
update to latest version
2017-12-02 01:30:07 +08:00
Daiyuu Nobori
9f9dc459a7 Preparing the development branch 2017-10-19 15:00:41 +09:00
dnobori
faee11ff09 v4.23-9647-beta 2017-10-18 18:24:21 +09:00
Daiyuu Nobori
2241b9a366 Merge pull request #309 from moatazelmasry2/openvpn-extend-ciphers
Openvpn extend ciphers
2017-10-18 16:57:52 +09:00
Daiyuu Nobori
056c322601 Merge branch 'master' into add-sha2 2017-10-18 16:57:26 +09:00
Daiyuu Nobori
936815f2d4 Merge pull request #293 from moatazelmasry2/expand-dh-groups
Add DH groups 2048,3072,4096 to IPSec_IKE
2017-10-18 16:37:22 +09:00
Daiyuu Nobori
8ae035420b Merge pull request #282 from NoahO/NoahO-PPP-patch
Stop Radius Delay from counting to next_resend
2017-10-18 16:37:02 +09:00
Daiyuu Nobori
b61882598f Merge pull request #256 from cm0x4D/master
Using client parameter in function CtConnect
2017-10-18 16:36:24 +09:00
cm0x4d
78bcc07fa9 Peer info optional in OvsParseKeyMethod2() 2017-09-28 10:37:24 +02:00
Moataz Elmasry
fdcf90d3f0 Add CAMELLIA cipher suite to OpenVPN 2017-02-24 14:09:22 +01:00
Moataz Elmasry
e0a9fb1950 Add HMAC-SHA2-256, HMAC2-384, HMAC2-512 support to OpenVPN 2017-01-23 02:34:25 +01:00
Moataz Elmasry
071004477f Fix errors while adding SHA2 support to HMAC 2017-01-23 02:03:37 +01:00
Moataz Elmasry
29234b7f9a Add HMAC SHA2 to IKE 2017-01-23 00:50:48 +01:00
Moataz Elmasry
c7c40c063a Add DH groups 2048,3072,4096 to IPSec_IKE
src/Cedar/IPsec_IkePacket.c
2017-01-21 19:20:59 +01:00
Noah O'Donoghue
a5425bcb4e Add files via upload 2016-12-28 14:39:01 +07:00
Ilya Shipitsin
8d59c33b92 null pointer derefence found by clang static analyzer 2016-11-28 19:12:03 +05:00
Ilya Shipitsin
334765ffd7 resolved several cppcheck findings:
[src/Cedar/Admin.c:418]: (error) Possible null pointer dereference: cedar
[src/Cedar/Admin.c:616]: (error) Possible null pointer dereference: cedar
[src/Cedar/WebUI.c:369]: (error) Uninitialized variable: retcode
[src/Mayaqua/Encrypt.c:4485]: (error) Uninitialized variable: key
[src/Mayaqua/Network.c:13548]: (error) Uninitialized variable: e
2016-11-28 17:27:29 +05:00
dnobori
4df2eb4f9c v4.22-9634-beta 2016-11-27 17:43:14 +09:00
Daiyuu Nobori
c9cd73d906 fix conflict 2016-11-27 18:02:30 +09:00
Daiyuu Nobori
2a2f47e0c8 Merge pull request #127 from nna774/fix/vpncmd-LogFileGet
fix LogFileGet won't save to SAVEPATH
2016-11-27 17:57:47 +09:00
Daiyuu Nobori
86d87d1ac4 fix conflict 2016-11-27 17:57:00 +09:00
Daiyuu Nobori
5f8ce287c3 Merge pull request #133 from yehorov/master
Add the possibility to send the Virtual Hub Name to an external DHCP server
2016-11-27 17:55:04 +09:00
Daiyuu Nobori
7c30cddedb Merge pull request #178 from mcsalgado/fix_initialization
Fix set initialization, set.OnlyCapsuleModeIsInvalid could be garbage
2016-11-27 17:54:17 +09:00
Daiyuu Nobori
034a213c2c Merge pull request #204 from LegDog/master
Adding Radius AVP Called-Station-Id
2016-11-27 17:53:45 +09:00
Daiyuu Nobori
712adc6d74 resolved the conflict 2016-11-27 17:48:18 +09:00
Daiyuu Nobori
cc8fff4d81 Merge pull request #217 from lewellyn/patch-1
Default to TLS connections only
2016-11-27 17:25:15 +09:00
Daiyuu Nobori
5cae447c79 Merge pull request #229 from chipitsine/master
cppcheck issues
2016-11-27 17:25:03 +09:00