Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
com.ccwangluo.accelerator
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
sheteng
com.ccwangluo.accelerator
Commits
a64eb8ac
Commit
a64eb8ac
authored
May 10, 2017
by
Max Lv
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Forward DNS packet to dnsgw
parent
9ab92309
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
4 additions
and
4 deletions
+4
-4
mobile/src/main/jni/badvpn
mobile/src/main/jni/badvpn
+1
-1
mobile/src/main/scala/com/github/shadowsocks/BaseService.scala
...e/src/main/scala/com/github/shadowsocks/BaseService.scala
+1
-1
mobile/src/main/scala/com/github/shadowsocks/ShadowsocksVpnService.scala
.../scala/com/github/shadowsocks/ShadowsocksVpnService.scala
+2
-2
No files found.
badvpn
@
af4a5647
Subproject commit
057ed9f36490a9dccd5e7337fabcb142dd3afc0d
Subproject commit
af4a5647eaa7263087d79817b38fc084e2206311
mobile/src/main/scala/com/github/shadowsocks/BaseService.scala
View file @
a64eb8ac
...
@@ -317,7 +317,7 @@ trait BaseService extends Service {
...
@@ -317,7 +317,7 @@ trait BaseService extends Service {
protected
final
def
buildOvertureConfig
(
file
:
String
)
:
String
=
{
protected
final
def
buildOvertureConfig
(
file
:
String
)
:
String
=
{
val
config
=
new
JSONObject
()
val
config
=
new
JSONObject
()
.
put
(
"BindAddress"
,
"
0.0.0.0
:"
+
(
profile
.
localPort
+
53
))
.
put
(
"BindAddress"
,
"
127.0.0.1
:"
+
(
profile
.
localPort
+
53
))
.
put
(
"RedirectIPv6Record"
,
true
)
.
put
(
"RedirectIPv6Record"
,
true
)
.
put
(
"DomainBase64Decode"
,
true
)
.
put
(
"DomainBase64Decode"
,
true
)
.
put
(
"HostsFile"
,
"hosts"
)
.
put
(
"HostsFile"
,
"hosts"
)
...
...
mobile/src/main/scala/com/github/shadowsocks/ShadowsocksVpnService.scala
View file @
a64eb8ac
...
@@ -143,7 +143,7 @@ class ShadowsocksVpnService extends VpnService with BaseService {
...
@@ -143,7 +143,7 @@ class ShadowsocksVpnService extends VpnService with BaseService {
/** Called when the activity is first created. */
/** Called when the activity is first created. */
def
handleConnection
()
{
def
handleConnection
()
{
startShadowsocksDaemon
()
startShadowsocksDaemon
()
if
(!
profile
.
udpdns
)
{
if
(!
profile
.
udpdns
)
{
...
@@ -247,7 +247,7 @@ class ShadowsocksVpnService extends VpnService with BaseService {
...
@@ -247,7 +247,7 @@ class ShadowsocksVpnService extends VpnService with BaseService {
cmd
+=
"--enable-udprelay"
cmd
+=
"--enable-udprelay"
if
(!
profile
.
udpdns
)
if
(!
profile
.
udpdns
)
cmd
+=
(
"--dnsgw"
,
"%s:%d"
.
formatLocal
(
Locale
.
ENGLISH
,
PRIVATE_VLAN
.
formatLocal
(
Locale
.
ENGLISH
,
"1"
)
,
cmd
+=
(
"--dnsgw"
,
"%s:%d"
.
formatLocal
(
Locale
.
ENGLISH
,
"127.0.0.1"
,
profile
.
localPort
+
53
))
profile
.
localPort
+
53
))
tun2socksProcess
=
new
GuardedProcess
(
cmd
:
_
*
).
start
(()
=>
sendFd
(
fd
))
tun2socksProcess
=
new
GuardedProcess
(
cmd
:
_
*
).
start
(()
=>
sendFd
(
fd
))
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment