Sync from SUSE:SLFO:Main xauth revision 0c351d270a48d1be0e3a8d3c0eaa4e96
This commit is contained in:
commit
89b895be96
23
.gitattributes
vendored
Normal file
23
.gitattributes
vendored
Normal file
@ -0,0 +1,23 @@
|
||||
## Default LFS
|
||||
*.7z filter=lfs diff=lfs merge=lfs -text
|
||||
*.bsp filter=lfs diff=lfs merge=lfs -text
|
||||
*.bz2 filter=lfs diff=lfs merge=lfs -text
|
||||
*.gem filter=lfs diff=lfs merge=lfs -text
|
||||
*.gz filter=lfs diff=lfs merge=lfs -text
|
||||
*.jar filter=lfs diff=lfs merge=lfs -text
|
||||
*.lz filter=lfs diff=lfs merge=lfs -text
|
||||
*.lzma filter=lfs diff=lfs merge=lfs -text
|
||||
*.obscpio filter=lfs diff=lfs merge=lfs -text
|
||||
*.oxt filter=lfs diff=lfs merge=lfs -text
|
||||
*.pdf filter=lfs diff=lfs merge=lfs -text
|
||||
*.png filter=lfs diff=lfs merge=lfs -text
|
||||
*.rpm filter=lfs diff=lfs merge=lfs -text
|
||||
*.tbz filter=lfs diff=lfs merge=lfs -text
|
||||
*.tbz2 filter=lfs diff=lfs merge=lfs -text
|
||||
*.tgz filter=lfs diff=lfs merge=lfs -text
|
||||
*.ttf filter=lfs diff=lfs merge=lfs -text
|
||||
*.txz filter=lfs diff=lfs merge=lfs -text
|
||||
*.whl filter=lfs diff=lfs merge=lfs -text
|
||||
*.xz filter=lfs diff=lfs merge=lfs -text
|
||||
*.zip filter=lfs diff=lfs merge=lfs -text
|
||||
*.zst filter=lfs diff=lfs merge=lfs -text
|
BIN
xauth-1.1.2.tar.xz
(Stored with Git LFS)
Normal file
BIN
xauth-1.1.2.tar.xz
(Stored with Git LFS)
Normal file
Binary file not shown.
174
xauth-tolerant-hostname-changes.diff
Normal file
174
xauth-tolerant-hostname-changes.diff
Normal file
@ -0,0 +1,174 @@
|
||||
Index: xauth-1.0.8/gethost.c
|
||||
===================================================================
|
||||
--- xauth-1.0.8.orig/gethost.c
|
||||
+++ xauth-1.0.8/gethost.c
|
||||
@@ -156,7 +156,8 @@ struct addrlist *get_address_info (
|
||||
int family,
|
||||
const char *fulldpyname,
|
||||
int prefix,
|
||||
- char *host)
|
||||
+ char *host,
|
||||
+ char *localhostname)
|
||||
{
|
||||
struct addrlist *retval = NULL;
|
||||
int len = 0;
|
||||
@@ -183,7 +184,7 @@ struct addrlist *get_address_info (
|
||||
if (prefix == 0 && (strncmp (fulldpyname, "unix:", 5) == 0 ||
|
||||
fulldpyname[0] == ':')) {
|
||||
|
||||
- if (!get_local_hostname (buf, sizeof buf)) {
|
||||
+ if (!get_local_hostname (buf, sizeof buf, localhostname)) {
|
||||
len = 0;
|
||||
} else {
|
||||
src = buf;
|
||||
@@ -233,7 +234,7 @@ struct addrlist *get_address_info (
|
||||
src = &(sin->sin_addr);
|
||||
if (*(const in_addr_t *) src == htonl(INADDR_LOOPBACK)) {
|
||||
family = FamilyLocal;
|
||||
- if (get_local_hostname (buf, sizeof buf)) {
|
||||
+ if (get_local_hostname (buf, sizeof buf, localhostname)) {
|
||||
src = buf;
|
||||
len = strlen (buf);
|
||||
} else
|
||||
@@ -248,7 +249,7 @@ struct addrlist *get_address_info (
|
||||
if (!IN6_IS_ADDR_V4MAPPED((const struct in6_addr *)src)) {
|
||||
if (IN6_IS_ADDR_LOOPBACK((const struct in6_addr *)src)) {
|
||||
family = FamilyLocal;
|
||||
- if (get_local_hostname (buf, sizeof buf)) {
|
||||
+ if (get_local_hostname (buf, sizeof buf, localhostname)) {
|
||||
src = buf;
|
||||
len = strlen (buf);
|
||||
} else
|
||||
@@ -303,7 +304,7 @@ struct addrlist *get_address_info (
|
||||
src = (char *) &hostinetaddr;
|
||||
if (*(const in_addr_t *) src == htonl(INADDR_LOOPBACK)) {
|
||||
family = FamilyLocal;
|
||||
- if (get_local_hostname (buf, sizeof buf)) {
|
||||
+ if (get_local_hostname (buf, sizeof buf, localhostname)) {
|
||||
src = buf;
|
||||
len = strlen (buf);
|
||||
} else {
|
||||
Index: xauth-1.0.8/parsedpy.c
|
||||
===================================================================
|
||||
--- xauth-1.0.8.orig/parsedpy.c
|
||||
+++ xauth-1.0.8/parsedpy.c
|
||||
@@ -70,20 +70,23 @@ copystring (const char *src, int len)
|
||||
|
||||
|
||||
char *
|
||||
-get_local_hostname (char *buf, int maxlen)
|
||||
+get_local_hostname (char *buf, int maxlen, char *localhostname)
|
||||
{
|
||||
buf[0] = '\0';
|
||||
+ if (localhostname)
|
||||
+ strncpy(buf, localhostname, maxlen);
|
||||
+ else
|
||||
(void) XmuGetHostname (buf, maxlen);
|
||||
return (buf[0] ? buf : NULL);
|
||||
}
|
||||
|
||||
#ifndef UNIXCONN
|
||||
static char *
|
||||
-copyhostname (void)
|
||||
+copyhostname (char *localhostname)
|
||||
{
|
||||
char buf[256];
|
||||
|
||||
- return (get_local_hostname (buf, sizeof buf) ?
|
||||
+ return (get_local_hostname (buf, sizeof buf, localhostname) ?
|
||||
copystring (buf, strlen (buf)) : NULL);
|
||||
}
|
||||
#endif
|
||||
@@ -93,6 +96,7 @@ copyhostname (void)
|
||||
*/
|
||||
Bool
|
||||
parse_displayname (const char *displayname,
|
||||
+ char *localhostname,
|
||||
int *familyp, /* return */
|
||||
char **hostp, /* return */
|
||||
int *dpynump, /* return */
|
||||
@@ -134,7 +138,7 @@ parse_displayname (const char *displayna
|
||||
host = copystring ("0", 1);
|
||||
family = FamilyDECnet;
|
||||
} else {
|
||||
- host = copyhostname ();
|
||||
+ host = copyhostname (localhostname);
|
||||
family = FamilyInternet;
|
||||
}
|
||||
#endif
|
||||
Index: xauth-1.0.8/process.c
|
||||
===================================================================
|
||||
--- xauth-1.0.8.orig/process.c
|
||||
+++ xauth-1.0.8/process.c
|
||||
@@ -470,7 +470,7 @@ read_auth_entries(FILE *fp, Bool numeric
|
||||
}
|
||||
|
||||
static Bool
|
||||
-get_displayname_auth(const char *displayname, AuthList **authl)
|
||||
+get_displayname_auth(const char *displayname, AuthList **authl, char *localhostname)
|
||||
{
|
||||
int family;
|
||||
char *host = NULL, *rest = NULL;
|
||||
@@ -490,11 +490,13 @@ get_displayname_auth(const char *display
|
||||
prelen = (cp - displayname);
|
||||
|
||||
if (!parse_displayname (displayname + ((prelen > 0) ? prelen + 1 : 0),
|
||||
+ localhostname,
|
||||
&family, &host, &dpynum, &scrnum, &rest)) {
|
||||
return False;
|
||||
}
|
||||
|
||||
- addrlist_head = get_address_info(family, displayname, prelen, host);
|
||||
+ addrlist_head = get_address_info(family, displayname, prelen, host,
|
||||
+ localhostname);
|
||||
if (addrlist_head) {
|
||||
char buf[40]; /* want to hold largest display num */
|
||||
unsigned short dpylen;
|
||||
@@ -1240,13 +1242,18 @@ iterdpy (const char *inputfilename, int
|
||||
Xauth *tmp_auth;
|
||||
AuthList *proto_head, *proto;
|
||||
AuthList *l, *next;
|
||||
-
|
||||
+ /*
|
||||
+ * get saved local address from environment in case the host
|
||||
+ * name has changed after the credential was added.
|
||||
+ */
|
||||
+ char *xlocalhostname = getenv("XAUTHLOCALHOSTNAME");
|
||||
+
|
||||
/*
|
||||
* iterate
|
||||
*/
|
||||
for (i = start; i < argc; i++) {
|
||||
const char *displayname = argv[i];
|
||||
- if (!get_displayname_auth (displayname, &proto_head)) {
|
||||
+ if (!get_displayname_auth (displayname, &proto_head, xlocalhostname)) {
|
||||
prefix (inputfilename, lineno);
|
||||
baddisplayname (displayname, argv[0]);
|
||||
errors++;
|
||||
@@ -1601,7 +1608,7 @@ do_add(const char *inputfilename, int li
|
||||
}
|
||||
}
|
||||
|
||||
- if (!get_displayname_auth (dpyname, &list)) {
|
||||
+ if (!get_displayname_auth (dpyname, &list, NULL)) {
|
||||
prefix (inputfilename, lineno);
|
||||
baddisplayname (dpyname, argv[0]);
|
||||
free (key);
|
||||
Index: xauth-1.0.8/xauth.h
|
||||
===================================================================
|
||||
--- xauth-1.0.8.orig/xauth.h
|
||||
+++ xauth-1.0.8/xauth.h
|
||||
@@ -48,10 +48,10 @@ struct addrlist {
|
||||
};
|
||||
|
||||
extern const char *get_hostname ( Xauth *auth );
|
||||
-extern struct addrlist *get_address_info ( int family, const char *fulldpyname, int prefix, char *host);
|
||||
+extern struct addrlist *get_address_info ( int family, const char *fulldpyname, int prefix, char *host, char *localhostname);
|
||||
extern char *copystring ( const char *src, int len );
|
||||
-extern char *get_local_hostname ( char *buf, int maxlen );
|
||||
-extern Bool parse_displayname ( const char *displayname, int *familyp, char **hostp, int *dpynump, int *scrnump, char **restp );
|
||||
+extern char *get_local_hostname ( char *buf, int maxlen, char *localhostname );
|
||||
+extern Bool parse_displayname ( const char *displayname, char *localhostname, int *familyp, char **hostp, int *dpynump, int *scrnump, char **restp );
|
||||
extern int auth_initialize ( const char *authfilename );
|
||||
extern int auth_finalize ( void );
|
||||
extern int process_command ( const char *inputfilename, int lineno, int argc, const char **argv );
|
99
xauth.changes
Normal file
99
xauth.changes
Normal file
@ -0,0 +1,99 @@
|
||||
-------------------------------------------------------------------
|
||||
Wed Apr 20 08:51:00 UTC 2022 - Stefan Dirsch <sndirsch@suse.com>
|
||||
|
||||
- update to version 1.1.2
|
||||
* tests: make tests work in out-of-tree builds
|
||||
* tests: Fix failure to make distcheck
|
||||
* tests: report failure if stderr has unexpected output
|
||||
* configure.ac: fail build if xtrans is not found
|
||||
* gitlab CI: add a basic build test
|
||||
* Build xz tarballs instead of bzip2
|
||||
* Fix off-by-one in quote-stripping routines
|
||||
* gitlab CI: stop requiring Signed-off-by in commits
|
||||
* Improve portability
|
||||
* Removed build requirement "cmdtest".
|
||||
* Fix warning -Wstringop-truncation for strncpy by using memcpy instead
|
||||
* Expand checks of socket file with S_ISSOCK
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Nov 29 15:29:09 UTC 2021 - Stefan Dirsch <sndirsch@suse.com>
|
||||
|
||||
- update to version 1.1.1
|
||||
* This is a minor bugfix release, including fixes for reported
|
||||
crashes.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Mar 15 15:19:29 UTC 2021 - Dirk Müller <dmueller@suse.com>
|
||||
|
||||
- modernize spec file (move license to licensedir)
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Fri Jul 12 10:41:09 UTC 2019 - Stefan Dirsch <sndirsch@suse.com>
|
||||
|
||||
- Update to version 1.1
|
||||
* This release fixes a race condition where an existing
|
||||
authority file would be unlinked (possibly causing other
|
||||
clients to fail to connect), and fixes sorting and merging
|
||||
of authority file entries.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Feb 1 13:27:01 UTC 2017 - sndirsch@suse.com
|
||||
|
||||
- Update to version 1.0.10
|
||||
* include POSIX-standard limits.h for PATH_MAX instead of sys/syslimits.h
|
||||
* autogen.sh: Honor NOCONFIGURE=1
|
||||
* Clarified RELEASING in README
|
||||
* Fix for xauth failing on ENOSPC (= disk full)
|
||||
* autogen.sh: use quoted string variables
|
||||
* Update DISPLAY parsing to work with new launchd paths in Yosemite
|
||||
* Fix !HAVE_STRLCPY case
|
||||
* Build xauth before running tests.
|
||||
* autogen: add default patch prefix
|
||||
* autogen.sh: stop using maintainer mode
|
||||
* autogen.sh: use exec instead of waiting for configure to finish
|
||||
* usage(): Print summary for the -n option
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed May 7 10:01:28 UTC 2014 - sndirsch@suse.com
|
||||
|
||||
- Update to version 1.0.9
|
||||
* Add AC_USE_SYSTEM_EXTENSIONS to expose non-standard extensions
|
||||
* Do not install test_xauth during "make install" as it is
|
||||
* Fix warning about warn_unused_result triggered by WRITES.
|
||||
* Fixed missing EXTRA_DIST in tests. Extended README for releasing.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Fri Oct 25 14:48:02 UTC 2013 - sndirsch@suse.com
|
||||
|
||||
- Update to version 1.0.8
|
||||
* Fix a long standing problem that for ssh tunneled connections a
|
||||
display variable of the form: localhost:<N>.<M> leads to correct
|
||||
authorization when an X client is started but "xauth list $DISPLAY"
|
||||
returns nothing.
|
||||
* Fix for: If using GDM with XDMCP, then ssh is not able to start X11
|
||||
clients on the remote side. You get a "No xauth data; using fake
|
||||
authentication data for X11 forwarding." from SSH.
|
||||
- obsoletes xauth-1.0.2.diff,
|
||||
u_xauth_Look-for-FamilyLocal-if-inet-or-inet6-addr.patch
|
||||
- adjusted xauth-tolerant-hostname-changes.diff
|
||||
- added new test_xauth tool to %files section
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Sat Apr 14 21:47:40 UTC 2012 - dimstar@opensuse.org
|
||||
|
||||
- Update to version 1.0.7:
|
||||
+ Remove alarm handler in get_hostname
|
||||
+ Add const attributes to fix gcc -Wwrite-strings warnings
|
||||
+ convert strlen/malloc/strcpy combo to strdup
|
||||
- Changes from version 1.0.6:
|
||||
+ auth_finalize: Attempt to rename() if link() fails
|
||||
+ Error out and avoid a call to malloc(0) if given a bad hex
|
||||
string
|
||||
+ Build system fixes.
|
||||
- Rebase xauth-tolerant-hostname-changes.diff.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Fri Apr 13 08:46:08 UTC 2012 - vuntz@opensuse.org
|
||||
|
||||
- Split xauth from xorg-x11. Initial version: 1.0.5.
|
||||
|
59
xauth.spec
Normal file
59
xauth.spec
Normal file
@ -0,0 +1,59 @@
|
||||
#
|
||||
# spec file for package xauth
|
||||
#
|
||||
# Copyright (c) 2022 SUSE LLC
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
# remain the property of their copyright owners, unless otherwise agreed
|
||||
# upon. The license for this file, and modifications and additions to the
|
||||
# file, is the same license as for the pristine package itself (unless the
|
||||
# license for the pristine package is not an Open Source License, in which
|
||||
# case the license is the MIT License). An "Open Source License" is a
|
||||
# license that conforms to the Open Source Definition (Version 1.9)
|
||||
# published by the Open Source Initiative.
|
||||
|
||||
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
||||
#
|
||||
|
||||
|
||||
Name: xauth
|
||||
Version: 1.1.2
|
||||
Release: 0
|
||||
Summary: Utility to edit and display the X authorization information
|
||||
License: MIT
|
||||
Group: System/X11/Utilities
|
||||
URL: https://xorg.freedesktop.org/
|
||||
Source0: https://xorg.freedesktop.org/releases/individual/app/%{name}-%{version}.tar.xz
|
||||
Patch1: xauth-tolerant-hostname-changes.diff
|
||||
BuildRequires: pkgconfig
|
||||
BuildRequires: pkgconfig(x11)
|
||||
BuildRequires: pkgconfig(xau)
|
||||
BuildRequires: pkgconfig(xext)
|
||||
BuildRequires: pkgconfig(xmuu)
|
||||
BuildRequires: pkgconfig(xorg-macros) >= 1.8
|
||||
# Name of subpackage when this was part of the xorg-x11 package up to version 7.6
|
||||
Provides: xorg-x11-xauth = 7.6
|
||||
Obsoletes: xorg-x11-xauth <= 7.6
|
||||
|
||||
%description
|
||||
The xauth program is used to edit and display the authorization
|
||||
information used in connecting to the X server.
|
||||
|
||||
%prep
|
||||
%setup -q
|
||||
%patch1 -p1
|
||||
|
||||
%build
|
||||
%configure
|
||||
%make_build
|
||||
|
||||
%install
|
||||
%make_install
|
||||
|
||||
%files
|
||||
%license COPYING
|
||||
%doc ChangeLog README.md
|
||||
%{_bindir}/xauth
|
||||
%{_mandir}/man1/xauth.1%{?ext_man}
|
||||
|
||||
%changelog
|
Loading…
Reference in New Issue
Block a user