Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
L
libvncserver
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
rasky
libvncserver
Commits
f31f7159
Commit
f31f7159
authored
Aug 16, 2007
by
runge
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
x11vnc: add reverse -connect support to -display WAIT:, fix SSL Fetch cert only for -display WAIT:
parent
eb2eeed9
Changes
6
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
201 additions
and
72 deletions
+201
-72
ChangeLog
x11vnc/ChangeLog
+6
-0
README
x11vnc/README
+85
-65
help.c
x11vnc/help.c
+6
-2
user.c
x11vnc/user.c
+96
-1
x11vnc.1
x11vnc/x11vnc.1
+7
-3
x11vnc_defs.c
x11vnc/x11vnc_defs.c
+1
-1
No files found.
x11vnc/ChangeLog
View file @
f31f7159
2007-08-15 Karl Runge <runge@karlrunge.com>
* x11vnc: add reverse -connect support to -display WAIT:
i.e. -find, -create, -svc, ... mode. Document need for
-shared under -connect host1,host2,... Fix bug in -display
WAIT: mode if vnc client tries to only retrieve SSL cert.
2007-08-03 Karl Runge <runge@karlrunge.com>
* x11vnc: add -xrefresh option, fix KDE .DCOPserver parse bug,
make sure UNIXPW_DISABLE_LOCALHOST/-unixpw_unsafe ignore
...
...
x11vnc/README
View file @
f31f7159
This diff is collapsed.
Click to expand it.
x11vnc/help.c
View file @
f31f7159
...
...
@@ -405,8 +405,12 @@ void print_help(int mode) {
"
\n
"
"-connect string For use with
\"
vncviewer -listen
\"
reverse connections.
\n
"
" If
\"
string
\"
has the form
\"
host
\"
or
\"
host:port
\"\n
"
" the connection is made once at startup. Use commas
\n
"
" for a list of host's and host:port's.
\n
"
" the connection is made once at startup.
\n
"
"
\n
"
" Use commas for a list of host's and host:port's.
\n
"
" E.g. -connect host1,host2 or host1:0,host2:5678.
\n
"
" Note that to reverse connect to multiple hosts at the
\n
"
" same time you will likely need to also supply: -shared
\n
"
"
\n
"
" Note that unlike most vnc servers, x11vnc will require a
\n
"
" password for reverse as well as for forward connections.
\n
"
...
...
x11vnc/user.c
View file @
f31f7159
...
...
@@ -1328,6 +1328,8 @@ int wait_for_client(int *argc, char** argv, int http) {
char
*
users_list_save
=
NULL
;
int
created_disp
=
0
;
int
ncache_save
;
int
did_client_connect
=
0
;
int
loop
=
0
;
if
(
!
use_dpy
||
strstr
(
use_dpy
,
"WAIT:"
)
!=
use_dpy
)
{
return
0
;
...
...
@@ -1527,20 +1529,113 @@ int wait_for_client(int *argc, char** argv, int http) {
#endif
}
if
(
inetd
&&
use_openssl
)
{
accept_openssl
(
OPENSSL_INETD
,
-
1
);
}
if
(
client_connect
!=
NULL
)
{
char
*
remainder
=
NULL
;
if
(
inetd
)
{
rfbLog
(
"wait_for_client: -connect disallowed in inetd mode: %s
\n
"
,
client_connect
);
}
else
if
(
screen
&&
screen
->
clientHead
)
{
rfbLog
(
"wait_for_client: -connect disallowed: client exists: %s
\n
"
,
client_connect
);
}
else
if
(
strchr
(
client_connect
,
'='
))
{
rfbLog
(
"wait_for_client: invalid -connect string: %s
\n
"
,
client_connect
);
}
else
{
char
*
q
=
strchr
(
client_connect
,
','
);
if
(
q
)
{
rfbLog
(
"wait_for_client: only using first"
" connect host in: %s
\n
"
,
client_connect
);
remainder
=
strdup
(
q
+
1
);
*
q
=
'\0'
;
}
rfbLog
(
"wait_for_client: reverse_connect(%s)
\n
"
,
client_connect
);
reverse_connect
(
client_connect
);
did_client_connect
=
1
;
}
free
(
client_connect
);
if
(
remainder
!=
NULL
)
{
/* reset to host2,host3,... */
client_connect
=
remainder
;
}
else
{
client_connect
=
NULL
;
}
}
while
(
1
)
{
loop
++
;
if
(
shut_down
)
{
clean_up_exit
(
0
);
}
if
(
use_openssl
)
{
if
(
loop
<
2
)
{
if
(
did_client_connect
)
{
goto
screen_check
;
}
if
(
inetd
)
{
goto
screen_check
;
}
if
(
screen
&&
screen
->
clientHead
)
{
goto
screen_check
;
}
}
if
(
use_openssl
&&
!
inetd
)
{
check_openssl
();
/*
* This is to handle an initial verify cert from viewer,
* they disconnect right after fetching the cert.
*/
if
(
!
use_threads
)
rfbPE
(
-
1
);
if
(
screen
&&
screen
->
clientHead
)
{
int
i
;
if
(
unixpw
)
{
if
(
!
unixpw_in_progress
)
{
rfbLog
(
"unixpw but no unixpw_in_progress
\n
"
);
clean_up_exit
(
1
);
}
if
(
unixpw_client
&&
unixpw_client
->
onHold
)
{
rfbLog
(
"taking unixpw_client off hold
\n
"
);
unixpw_client
->
onHold
=
FALSE
;
}
}
for
(
i
=
0
;
i
<
10
;
i
++
)
{
if
(
shut_down
)
{
clean_up_exit
(
0
);
}
usleep
(
20
*
1000
);
if
(
0
)
rfbLog
(
"wait_for_client: %d
\n
"
,
i
);
if
(
!
use_threads
)
{
if
(
unixpw
)
{
unixpw_in_rfbPE
=
1
;
}
rfbPE
(
-
1
);
if
(
unixpw
)
{
unixpw_in_rfbPE
=
0
;
}
}
if
(
unixpw
&&
!
unixpw_in_progress
)
{
/* XXX too soon. */
goto
screen_check
;
}
if
(
!
screen
->
clientHead
)
{
break
;
}
}
}
}
else
if
(
use_openssl
)
{
check_openssl
();
}
if
(
!
use_threads
)
{
rfbPE
(
-
1
);
}
screen_check:
if
(
!
screen
||
!
screen
->
clientHead
)
{
usleep
(
100
*
1000
);
continue
;
...
...
x11vnc/x11vnc.1
View file @
f31f7159
...
...
@@ -2,7 +2,7 @@
.TH X11VNC "1" "August 2007" "x11vnc " "User Commands"
.SH NAME
x11vnc - allow VNC connections to real X11 displays
version: 0.9.3, lastmod: 2007-08-
03
version: 0.9.3, lastmod: 2007-08-
15
.SH SYNOPSIS
.B x11vnc
[OPTION]...
...
...
@@ -480,8 +480,12 @@ Same as \fB-avahi.\fR
.IP
For use with "vncviewer -listen" reverse connections.
If \fIstring\fR has the form "host" or "host:port"
the connection is made once at startup. Use commas
for a list of host's and host:port's.
the connection is made once at startup.
.IP
Use commas for a list of host's and host:port's.
E.g. \fB-connect\fR host1,host2 or host1:0,host2:5678.
Note that to reverse connect to multiple hosts at the
same time you will likely need to also supply: \fB-shared\fR
.IP
Note that unlike most vnc servers, x11vnc will require a
password for reverse as well as for forward connections.
...
...
x11vnc/x11vnc_defs.c
View file @
f31f7159
...
...
@@ -15,7 +15,7 @@ int xtrap_base_event_type = 0;
int
xdamage_base_event_type
=
0
;
/* date +'lastmod: %Y-%m-%d' */
char
lastmod
[]
=
"0.9.3 lastmod: 2007-08-
03
"
;
char
lastmod
[]
=
"0.9.3 lastmod: 2007-08-
15
"
;
/* X display info */
...
...
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