-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathlibxcrypt-xcrypt.patch
270 lines (250 loc) · 8.84 KB
/
libxcrypt-xcrypt.patch
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
diff -ur libxcrypt-4.4.19.orig/Makefile.am libxcrypt-4.4.19/Makefile.am
--- libxcrypt-4.4.19.orig/Makefile.am 2021-04-08 21:57:36.000000000 +0200
+++ libxcrypt-4.4.19/Makefile.am 2021-04-13 18:19:42.502648175 +0200
@@ -86,17 +86,15 @@
test/des-cases.h \
test/ka-table.inc
-if ENABLE_XCRYPT_COMPAT_FILES
nodist_include_HEADERS += xcrypt.h
-endif
noinst_PROGRAMS = \
lib/gen-des-tables
lib_LTLIBRARIES = \
- libcrypt.la
+ libxcrypt.la
-libcrypt_la_SOURCES = \
+libxcrypt_la_SOURCES = \
lib/alg-des-tables.c \
lib/alg-des.c \
lib/alg-gost3411-2012-core.c \
@@ -146,23 +144,23 @@
# Build libcrypt.so.2 if obsolete APIs are excluded, libcrypt.so.1 otherwise.
if ENABLE_OBSOLETE_API
-libcrypt_la_VERSION = 2:0:1
+libxcrypt_la_VERSION = 3:0:1
else
-libcrypt_la_VERSION = 2:0:0
+libxcrypt_la_VERSION = 3:0:0
endif
-libcrypt_la_LDFLAGS = -version-info $(libcrypt_la_VERSION)
+libxcrypt_la_LDFLAGS = -version-info $(libxcrypt_la_VERSION)
if HAVE_VSCRIPT
-libcrypt_la_LDFLAGS += $(VSCRIPT_LDFLAGS),$(builddir)/libcrypt.map
+libxcrypt_la_LDFLAGS += $(VSCRIPT_LDFLAGS),$(builddir)/libcrypt.map
endif
-libcrypt_la_LDFLAGS += $(UNDEF_FLAG) $(TEXT_RELOC_FLAG) $(AM_LDFLAGS)
+libxcrypt_la_LDFLAGS += $(UNDEF_FLAG) $(TEXT_RELOC_FLAG) $(AM_LDFLAGS)
-libcrypt_la_CPPFLAGS = $(AM_CPPFLAGS) -DIN_LIBCRYPT
+libxcrypt_la_CPPFLAGS = $(AM_CPPFLAGS) -DIN_LIBCRYPT
CONFIG_STATUS_DEPENDENCIES = lib/libcrypt.minver
-EXTRA_libcrypt_la_DEPENDENCIES = libcrypt.map
+EXTRA_libxcrypt_la_DEPENDENCIES = libcrypt.map
CLEANFILES = \
Makefile.deps Makefile.deps.T \
libcrypt.map libcrypt.map.T libcrypt.map.stamp \
@@ -266,9 +264,9 @@
uninstall-hook-xcrypt-static
install-exec-hook-xcrypt-static:
cd $(DESTDIR)$(libdir) && \
- $(LN_S) -f libcrypt.a libxcrypt.a
+ $(LN_S) -f libxcrypt.a libcrypt.a
uninstall-hook-xcrypt-static:
- -rm -f $(DESTDIR)$(libdir)/libxcrypt.a
+ -rm -f $(DESTDIR)$(libdir)/libcrypt.a
endif
if ENABLE_SHARED
@@ -281,9 +279,9 @@
uninstall-hook-xcrypt-shared
install-exec-hook-xcrypt-shared:
cd $(DESTDIR)$(libdir) && \
- $(LN_S) -f libcrypt.so libxcrypt.so
+ $(LN_S) -f libxcrypt.so libcrypt.so
uninstall-hook-xcrypt-shared:
- -rm -f $(DESTDIR)$(libdir)/libxcrypt.so
+ -rm -f $(DESTDIR)$(libdir)/libcrypt.so
endif
endif
@@ -310,7 +308,7 @@
uninstall-hook-libstatic
install-exec-hook-libstatic:
cd $(DESTDIR)$(libdir) && \
- $(LN_S) -f libcrypt.a libowcrypt.a
+ $(LN_S) -f libxcrypt.a libowcrypt.a
uninstall-hook-libstatic:
-rm -f $(DESTDIR)$(libdir)/libowcrypt.a
endif
@@ -323,8 +321,8 @@
uninstall-hook-libshared
install-exec-hook-libshared:
cd $(DESTDIR)$(libdir) && \
- $(LN_S) -f libcrypt.so libowcrypt.so && \
- $(LN_S) -f libcrypt.so.1 libowcrypt.so.1
+ $(LN_S) -f libxcrypt.so libowcrypt.so && \
+ $(LN_S) -f libxcrypt.so.1 libowcrypt.so.1
uninstall-hook-libshared:
-rm -f $(DESTDIR)$(libdir)/libowcrypt.so \
$(DESTDIR)$(libdir)/libowcrypt.so.1
@@ -422,7 +420,7 @@
# This is very slow and requires nonstandard Python libraries and a shared
# library build of libcrypt already present in the build-tree, so we only
# do it when explicitly requested.
-regen-ka-table: libcrypt.la
+regen-ka-table: libxcrypt.la
$(PYTHON) $(srcdir)/test/ka-table-gen.py > ka-table.inc.T
@if cmp -s ka-table.inc.T $(srcdir)/test/ka-table.inc; \
then echo ka-table.inc is unchanged; rm ka-table.inc.T; \
@@ -434,7 +432,7 @@
endif
if ENABLE_OBSOLETE_API
-libcrypt_la_SOURCES += lib/crypt-des-obsolete.c
+libxcrypt_la_SOURCES += lib/crypt-des-obsolete.c
check_PROGRAMS += test/des-obsolete test/des-obsolete_r
endif
@@ -449,7 +447,7 @@
endif
AM_TESTS_ENVIRONMENT = \
- lib_la="./libcrypt.la"; \
+ lib_la="./libxcrypt.la"; \
lib_map="$(srcdir)/lib/libcrypt.map.in"; \
HAVE_CPP_dD="$(HAVE_CPP_dD)"; \
SYMBOL_PREFIX="$(SYMBOL_PREFIX)"; \
@@ -473,7 +471,7 @@
test/symbols-renames.log test/symbols-renames.trs: test/TestCommon.pm
test/symbols-static.log test/symbols-static.trs: test/TestCommon.pm
-COMMON_TEST_OBJECTS = libcrypt.la
+COMMON_TEST_OBJECTS = libxcrypt.la
test_badsalt_LDADD = $(COMMON_TEST_OBJECTS)
test_badsetting_LDADD = $(COMMON_TEST_OBJECTS)
@@ -507,81 +505,81 @@
# These tests call internal APIs that may not be accessible from the
# fully linked shared library.
# Refer to object files that are linked into libxcrypt with the
-# qualified name, lib/libcrypt_la-foobar.lo, to prevent them from
+# qualified name, lib/libxcrypt_la-foobar.lo, to prevent them from
# being compiled a second time.
test_gensalt_LDADD = \
- lib/libcrypt_la-util-xstrcpy.lo \
+ lib/libxcrypt_la-util-xstrcpy.lo \
$(COMMON_TEST_OBJECTS)
test_alg_des_LDADD = \
- lib/libcrypt_la-alg-des.lo \
- lib/libcrypt_la-alg-des-tables.lo \
+ lib/libxcrypt_la-alg-des.lo \
+ lib/libxcrypt_la-alg-des-tables.lo \
$(COMMON_TEST_OBJECTS)
test_alg_gost3411_2012_LDADD = \
- lib/libcrypt_la-alg-gost3411-2012-core.lo \
- lib/libcrypt_la-alg-gost3411-2012-hmac.lo \
- lib/libcrypt_la-util-xbzero.lo \
+ lib/libxcrypt_la-alg-gost3411-2012-core.lo \
+ lib/libxcrypt_la-alg-gost3411-2012-hmac.lo \
+ lib/libxcrypt_la-util-xbzero.lo \
$(COMMON_TEST_OBJECTS)
test_alg_gost3411_2012_hmac_LDADD = \
- lib/libcrypt_la-alg-gost3411-2012-core.lo \
- lib/libcrypt_la-alg-gost3411-2012-hmac.lo \
- lib/libcrypt_la-util-xbzero.lo \
+ lib/libxcrypt_la-alg-gost3411-2012-core.lo \
+ lib/libxcrypt_la-alg-gost3411-2012-hmac.lo \
+ lib/libxcrypt_la-util-xbzero.lo \
$(COMMON_TEST_OBJECTS)
test_alg_hmac_sha1_LDADD = \
- lib/libcrypt_la-alg-sha1.lo \
- lib/libcrypt_la-alg-hmac-sha1.lo \
- lib/libcrypt_la-util-xbzero.lo \
+ lib/libxcrypt_la-alg-sha1.lo \
+ lib/libxcrypt_la-alg-hmac-sha1.lo \
+ lib/libxcrypt_la-util-xbzero.lo \
$(COMMON_TEST_OBJECTS)
test_alg_md4_LDADD = \
- lib/libcrypt_la-alg-md4.lo \
- lib/libcrypt_la-util-xbzero.lo \
+ lib/libxcrypt_la-alg-md4.lo \
+ lib/libxcrypt_la-util-xbzero.lo \
$(COMMON_TEST_OBJECTS)
test_alg_md5_LDADD = \
- lib/libcrypt_la-alg-md5.lo \
- lib/libcrypt_la-util-xbzero.lo \
+ lib/libxcrypt_la-alg-md5.lo \
+ lib/libxcrypt_la-util-xbzero.lo \
$(COMMON_TEST_OBJECTS)
test_alg_pbkdf_hmac_sha256_LDADD = \
- lib/libcrypt_la-alg-sha256.lo \
- lib/libcrypt_la-util-xbzero.lo \
+ lib/libxcrypt_la-alg-sha256.lo \
+ lib/libxcrypt_la-util-xbzero.lo \
$(COMMON_TEST_OBJECTS)
test_alg_sha1_LDADD = \
- lib/libcrypt_la-alg-sha1.lo \
- lib/libcrypt_la-util-xbzero.lo \
+ lib/libxcrypt_la-alg-sha1.lo \
+ lib/libxcrypt_la-util-xbzero.lo \
$(COMMON_TEST_OBJECTS)
test_alg_sha256_LDADD = \
- lib/libcrypt_la-alg-sha256.lo \
- lib/libcrypt_la-util-xbzero.lo \
+ lib/libxcrypt_la-alg-sha256.lo \
+ lib/libxcrypt_la-util-xbzero.lo \
$(COMMON_TEST_OBJECTS)
test_alg_sha512_LDADD = \
- lib/libcrypt_la-alg-sha512.lo \
- lib/libcrypt_la-util-xbzero.lo \
+ lib/libxcrypt_la-alg-sha512.lo \
+ lib/libxcrypt_la-util-xbzero.lo \
$(COMMON_TEST_OBJECTS)
test_alg_yescrypt_LDADD = \
- lib/libcrypt_la-alg-sha256.lo \
- lib/libcrypt_la-alg-yescrypt-common.lo \
- lib/libcrypt_la-alg-yescrypt-opt.lo \
- lib/libcrypt_la-util-base64.lo \
- lib/libcrypt_la-util-xbzero.lo \
+ lib/libxcrypt_la-alg-sha256.lo \
+ lib/libxcrypt_la-alg-yescrypt-common.lo \
+ lib/libxcrypt_la-alg-yescrypt-opt.lo \
+ lib/libxcrypt_la-util-base64.lo \
+ lib/libxcrypt_la-util-xbzero.lo \
$(COMMON_TEST_OBJECTS)
test_crypt_gost_yescrypt_LDADD = \
- lib/libcrypt_la-alg-gost3411-2012-core.lo \
- lib/libcrypt_la-alg-gost3411-2012-hmac.lo \
- lib/libcrypt_la-alg-sha256.lo \
- lib/libcrypt_la-alg-yescrypt-common.lo \
- lib/libcrypt_la-alg-yescrypt-opt.lo \
- lib/libcrypt_la-crypt-yescrypt.lo \
- lib/libcrypt_la-util-base64.lo \
- lib/libcrypt_la-util-xbzero.lo \
- lib/libcrypt_la-util-xstrcpy.lo \
+ lib/libxcrypt_la-alg-gost3411-2012-core.lo \
+ lib/libxcrypt_la-alg-gost3411-2012-hmac.lo \
+ lib/libxcrypt_la-alg-sha256.lo \
+ lib/libxcrypt_la-alg-yescrypt-common.lo \
+ lib/libxcrypt_la-alg-yescrypt-opt.lo \
+ lib/libxcrypt_la-crypt-yescrypt.lo \
+ lib/libxcrypt_la-util-base64.lo \
+ lib/libxcrypt_la-util-xbzero.lo \
+ lib/libxcrypt_la-util-xstrcpy.lo \
$(COMMON_TEST_OBJECTS)
test_explicit_bzero_LDADD = \
- lib/libcrypt_la-util-xbzero.lo
+ lib/libxcrypt_la-util-xbzero.lo
test_getrandom_interface_LDADD = \
- lib/libcrypt_la-util-get-random-bytes.lo \
- lib/libcrypt_la-util-xbzero.lo
+ lib/libxcrypt_la-util-get-random-bytes.lo \
+ lib/libxcrypt_la-util-xbzero.lo
test_getrandom_fallbacks_LDADD = \
- lib/libcrypt_la-util-get-random-bytes.lo \
- lib/libcrypt_la-util-xbzero.lo
+ lib/libxcrypt_la-util-get-random-bytes.lo \
+ lib/libxcrypt_la-util-xbzero.lo
if HAVE_LD_WRAP
diff -ur libxcrypt-4.4.19.orig/lib/libxcrypt.pc.in libxcrypt-4.4.19/lib/libxcrypt.pc.in
--- libxcrypt-4.4.19.orig/lib/libxcrypt.pc.in 2021-04-08 21:57:36.000000000 +0200
+++ libxcrypt-4.4.19/lib/libxcrypt.pc.in 2021-04-13 18:20:04.059324711 +0200
@@ -11,5 +11,5 @@
Name: @PACKAGE@
Version: @VERSION@
Description: Extended crypt library for DES, MD5, Blowfish and others
-Libs: -L${libdir} -lcrypt
+Libs: -L${libdir} -lxcrypt
Cflags: -I${includedir}