]> granicus.if.org Git - fortune-mod/blob - fortune-mod/ChangeLog
prepare for the new release
[fortune-mod] / fortune-mod / ChangeLog
1 (Note: this file has been re-arranged to be in reverse chronological
2 order, which is The Right Thing for ChangeLogs - DLC)
3
4 August 30, 2020 (fortune-mod 2.29.1)
5
6         DEVELOPMENT RELEASE
7
8         Fix the build and tests on AppVeyor-CI / Windows
9
10         Fix some compiler warnings.
11
12 August 20, 2020 (fortune-mod 2.29.0)
13
14         DEVELOPMENT RELEASE
15
16         Convert the documentation from troff to DocBook 5/XML using
17         doclifter ( http://www.catb.org/~esr/doclifter/ ). The resultant troff
18         man pages are included in the source release tarball.
19
20         Fix formatting of several cookies.
21
22         Minor build fixes (avoid rebuilding the symlinks).
23
24 June 02, 2020 (fortune-mod 2.28.0)
25
26         SECURITY [low risk]: avoid overflow with the -i flag
27
28         Correct attributions and typos (Thanks to Tobin Yehle.)
29
30         Small code cleanups.
31
32 May 02, 2020 (fortune-mod 2.26.0)
33
34         SECURITY: Avoid integer overflow in parsing the percentages which caused
35         using negative integers.
36
37         https://metacpan.org/pod/Test::Trap is a new tests' dependency
38
39         Format strings cleanups in C.
40
41 April 30, 2020 (fortune-mod 2.24.0)
42
43         SECURITY: Avoid some potential buffer overflows in unstr, strfile and randstr.
44                 - This was found to exist in NetBSD's fortune, and FreeBSD's fortune
45                 as well (OpenBSD's fortune appear to have been fixed).
46
47         Add regression valgrind tests for the buffer overflows.
48
49         Some cleanups inspired by OpenBSD'd fortune.
50
51 April 29, 2020 (fortune-mod 2.22.0)
52
53         SECURITY: Avoid some hypothetical buffer overflows in unstr, strfile and randstr.
54
55         Modernize and refactor the code.
56
57         Avoid build targets' proliferation in CMake.
58
59 April 04, 2020 (fortune-mod 2.20.0)
60
61         Further avoid double traversal if FORTDIR == LOCFORTDIR.
62
63         Using clang-format to format the code.
64
65         Eliminate -D_FORTIFY_SOURCE warnings.
66
67         Modernize and refactor the code.
68
69 March 30, 2020 (fortune-mod 2.18.0)
70
71         Avoid double traversal if FORTDIR == LOCFORTDIR.
72
73         Typos' corrections and a new quote.
74
75 February 26, 2020 (fortune-mod 2.16.0)
76
77         Better portability to Microsoft Windows and other OSes
78         Thanks to AppVeyor (done by Shlomi Fish).
79
80         Add the -u flag [from debian]
81
82         Add fortune.desktop [from debian]
83
84         Remove backspaces in a cookie [from debian]
85
86         Complete the lyrics of a Leonard Cohen song [from debian]
87
88         Correct a misattribution.
89
90 February 23, 2020 (fortune-mod 2.14.0)
91
92         Correct some typos and add some new cookies.
93
94         Better Win32/Win64 Portability (AppVeyor is still failing.)
95
96         Code cleanups.
97
98 December 18, 2019 (fortune-mod 2.12.0)
99
100         Extract rinutils as a package and require it as a dep:
101         https://github.com/shlomif/rinutils/ .
102
103         Move some jokes to the offensive collection:
104         https://github.com/shlomif/fortune-mod/pull/38 - thanks
105         to @s0nata .
106
107 June 30, 2019 (fortune-mod 2.10.0)
108
109         Move strfile and unstr to /usr/bin :
110         https://github.com/shlomif/fortune-mod/issues/35
111
112         Code cleanups: warnings and portability.
113
114         Better porting to windows / appveyor-CI
115         (still not perfect)
116
117 June 07, 2019 (fortune-mod 2.8.0)
118
119         Add some quotes by amigojapan.
120
121         Some improvements for spelling, punctuation and grammar.
122
123         Extract a common C header.
124
125         Add TidyAll tests.
126
127 December 19, 2018 (fortune-mod 2.6.2)
128
129         Fix the cmake files installation paths. See
130         https://github.com/shlomif/fortune-mod/pull/29 .
131
132         Some improvements for spelling, punctuation and grammar.
133
134         Normalize the numbering of "Great Moments in History":
135         https://github.com/shlomif/fortune-mod/issues/28 .
136
137 July 10, 2018 (fortune-mod 2.6.1)
138
139         Fix the previously rotated display of offensive fortunes (using the "-o"
140         or "-a" flags). See https://github.com/shlomif/fortune-mod/issues/26 .
141
142         Incorporate several more minor patches from Debian.
143
144 June 26, 2018 (fortune-mod 2.6.0)
145
146         Incorporate patches from the Debian package.
147
148         Add the "tao", "pratchett" and many individual cookies.
149
150 March 22, 2018 (fortune-mod 2.4.1)
151
152         Add the missing cmake/Shlomif_Common.cmake file.
153
154 March 22, 2018 (fortune-mod 2.4.0)
155
156         Fix issue #24 reported by @pouar of an underflow error in strfile.
157
158         Fix some GCC warnings with the Recode flags.
159
160         Remove some trailing empty lines in fortunes
161
162 February 15, 2018 (fortune-mod 2.2.1)
163
164         Fix some mispellings.
165
166         Remove some duplicates.
167
168         Thanks to bug reporters on the bug trackers of Linux distributions.
169
170 January 31, 2018 (fortune-mod 2.2.0)
171
172         Add the "disclaimer" cookie file (thanks to mathew).
173
174         Correct some problems in the documentation.
175
176         Fix some memory leaks (thanks to valgrind).
177
178         Reenable the valgrind tests (requires Recode 3.7).
179
180 January 11, 2018 (fortune-mod-2.0.0)
181
182         Correct typos.
183
184         Deprecate the BSD_REGEX - we now use only POSIX ones.
185
186         Various build fixes.
187
188 March 25, 2017 (fortune-mod-1.99.5)
189
190         Add a new cmake-based configuration/build/install system.
191
192         Converted the source files to UTF-8.
193
194         Added automated tests.
195
196         Removed trailing whitespace.
197
198         Reformatted long (> 80 chars) lines.
199
200         Fixed many typos.
201
202         Fixed some compiler warnings.
203
204         Added a build-time option to remove the “-o” (= “offensive”) flag.
205
206         Incorporated some downstream patches from Linux distributions.
207
208
209 March 05, 2004 (fortune-mod-1.99.1)
210
211         Most of the changes have occurred at some point in time in the last
212         5 years.
213
214         A high number of spelling, punctuation, formatting and grammar
215         fixes.
216
217         Internationalisation support.
218
219         New -c option to see which file a fortune came from.
220
221 August 29, 1997
222
223   Incorporated a couple of minor changes made in the (old) Debian
224   fortune-mod package, including the addition of an extra data file
225   called 'cookie'.  Renamed some documentation files, and included some
226   install information for non-Linux users.  Added a "-v" option to
227   report the program version.
228
229   I intend to submit this distribution to SunSITE RSN.
230
231     -- Dennis L. Clark <dbugger@progsoc.uts.edu.au>
232
233 May, 1997
234
235   This release fixes many of the portability problems with the
236   fortune-mod program released by Amy Lewis in October, 1995.  The
237   previous version had many Linux-isms in it, which left it unworkable
238   on any other platform.  This version replaces most of these with more
239   standard calls, making it more likely to work under other platforms.
240   The Makefiles have been modified so that GNU's gcc and make are no
241   longer required: any standard make and ANSI-compatible C compiler
242   should work.  Sorry, pre-ANSI compilers are not supported (c'mon, this
243   is the 90's, darn it!)
244
245   This version has been tested to work on SunOS 4.1.x as well as Linux.
246   All changes made to the sources were as platform-independant as
247   possible.  Therefore, no "#ifdef LINUX" or "#ifdef SUNOS4" directives
248   appear in the code.  An effect of this is that a number of 'implicit
249   declaration' warnings are emitted by gcc under SunOS 4.1.x, but this a
250   problem with SunOS's standard headers, not with the program or the
251   compiler.  The benefit of this approach is that it eases the work of
252   expanding the port to include other platforms. Bug reports and fixes
253   for other platforms are most welcome!
254
255   A few "standard" C function calls were replaced with more standard
256   counterparts at various points.  Generally, when there was a choice
257   between a BSD version of a function and a POSIX version, the POSIX
258   version was favoured (even though fortune originated on BSD).  An
259   exception to this was the regex functions: either POSIX or BSD
260   versions can be used, with selection made via the top-level Makefile.
261
262   Fortune and strfile also compiles on Solaris 2.5, but a discrepency
263   between the declaration and implementation of 'struct dirent' on the
264   test platform caused fortune to execute incorrectly there.  It is not
265   certain whether this is a bug in the header file, the C library, or
266   the test platform.
267
268   While the making of this release was not meant to become a bug
269   search-and-destroy mission, some bugs were inadvertently discovered
270   and fixed. including the known bug of using -a with a file that occurs
271   in both the offensive and inoffensive directories.  Fixing this
272   particular bug required a way to be able to separately identify two
273   fortune files with the same name, with one in the inoffensive
274   directory, the other one in the offensive directory.  Now, such a name
275   will be taken to be the inoffensive file by default.  However, you can
276   now append '-o' to a fortune name, and the '-o' will be removed and
277   the offensive directory will be searched.  Thus you can say (assuming
278   you use the distributed datfiles):
279
280         fortune 80% politics politics-o
281
282   Which has an 80% change of giving an "inoffensive" political fortune,
283   and a 20% change of giving an "offensive" political one.  Note that
284   this makes fortune-mod backwards-compatible with BSD fortune, but only
285   for users, not fortune database maintainers.
286
287   Of course, this solution only passes the buck: with the above example
288   again, if you have a 'politics-o' file in your inoffensive directory,
289   you are back to square one.  OTOH, seeing that '-o' originally was
290   meant for offensive fortunes, using it for inoffensive ones is simply
291   asking for trouble.
292
293   Bug fixed: Fortune's definition of a fortune length (for -s and -l)
294   was inconsistent.  Unordered fortunes counted the 2 delimiting
295   characters (as hinted in the man page), but sorted or randomized
296   fortunes did not.  Now the delimiting characters are _NEVER_ counted,
297   so you will always get the length limit you expect.
298
299   Another bug fix: -l and -s can now work together with -m.  Previously
300   -l and -s were ignored when -m was in effect.  The new behaviour helps
301   me count how many long or short fortunes there are in a file.
302
303   Ansify has been removed from the package, as well as some filter
304   scripts from NetBSD that no longer appear useful.  Randstr has been
305   kept, but has not been improved in any way.  It at least has a man
306   page: maybe somebody will find it useful.
307
308   Some of the documentation (including the man pages) has been improved
309   and updated, and some files have been renamed so that the package
310   looks less Linux-specific.
311
312     -- Dennis L. Clark <dbugger@progsoc.uts.edu.au>
313
314 Late October 1995
315   Ansify has been abandoned.  I'm going to distribute this working version
316   of fortune, and then see how difficult it would be to add termcap/terminfo
317   enhancements to fortune itself--I don't anticipate serious problems, but
318   I'd rather go ahead and get this on the net.
319
320   A last-minute change was made to the way that percentages are displayed
321   with -f; it is now in the format nnn.nn%.  The reason for this is that
322   with the multiplication of small files, fortune -af displayed a large
323   number of "0%"s--no worse than the old version, but not helpful.
324
325   The fortunes database was finally cleaned up, and this version is now
326   being distributed (at least, I hope it is).  I don't consider the current
327   division of fortunes among files absolutely canonical; some are certainly
328   in the wrong places.  But things are *better*.
329
330 Amy A. Lewis    alewis@email.unc.edu
331
332 Mid-October '95
333   Another utility, ansify, now compiles; it has not been tested at all, so
334   it may not work even slightly.
335
336   Ansify is a rather stupid program, all things considered, but the work on
337   it does raise an interesting possibility for an enhanced fortune.  At
338   present, the fortune databases contain x^Hy sequences for underline and
339   special characters (and this can be extended to include bold, = x^Hx).
340   Ansify is stupid because it doesn't use the proper tools, ie termcap or
341   terminfo (hmmm ... since it works on files, that may not be so stupid);
342   it appears that if that can be done, then a termcap/terminfo enhanced
343   fortune could be produced, which would recognize the existence of ^H in
344   a string and attempt to display using appropriate control sequences.
345   This sort of modification would be of greater interest to casual users,
346   I think, than even the bug fixes, and since it would not force changes
347   in the storage of fortunes, it is eminently portable.  Consider this a
348   'todo' announcement.
349
350 Added (early October 95):
351   A new executable, rot, which is a rot13 filter (a caesar cipher). Most
352   probably have caesar, but on the other hand, if you compile this mess
353   as root, caesar probably isn't in the path.
354
355   A new parameter to fortune, -n, which permits you to specify the length
356   at which to break between long (-l) and short (-s) fortunes.
357
358   fortune -f now shows probabilities.
359
360   A bug: fortune -a nn% filename filename ... now fails without an error
361   message, if the filename named following the percentage exists in both
362   the inoffensive and the offensive directories (that is, if you have two
363   files containing definitions, one called fortunes/definitions and one
364   called fortunes/off/definitions, and call fortune as: fortune -a 10%
365   definitions religion politics ..., then fortune simply fails).  This
366   appears to be an artifact of the changes that were made in storage/
367   naming of offensive fortunes.  It only happens with the combination of
368   a percentage with -a and inoffensive/offensive files that share a name.
369   Temporary workaround: rename one or the other of the files (*sigh*  I
370   don't like that as a solution).
371
372   The man pages have been updated.  The old man pages are also available,
373   but are not installed unless you do it yourself (the new ones are).  The
374   new man pages have the extension .man; the old ones have numeric
375   extensions.
376
377   A place has been created for fortune files containing HTML tags (the
378   reason I started playing with this mess was because I wanted to be
379   able to format fortunes nicely for the web without having to run an
380   enormously complex script to figure out from formatting how best to
381   display things, a particular problem since the formatting isn't
382   consistent).  Tagged fortunes don't exist yet, and I'm seriously
383   considering creating a slightly different fortune binary that would
384   output the necessary headers and trailers (reducing the CGI script
385   to complete triviality) (-f isn't really needed for a webfortune).
386
387 Todo: I'm thinking of adding a -x to unstr, to rot13 the output.  This
388 would have the effect of putting all the necessary tools in one package.
389 It further breaks compatibility with BSD tools (which has *mostly* been
390 maintained, merely enhanced slightly, although the change in how
391 offensive files are distinguished from inoffensive might be regarded as
392 breaking compatibility) by adding yet another parameter to unstr, which
393 didn't have any, before.  So I haven't decided, yet.
394
395 Todo: KOI8 encoded fortunes?  They couldn't be rotated without a great
396 deal of trouble, of course.
397
398 More minor fixes:
399
400   The way that fortune -m prints its output has been slightly changed.  It
401   used to print the delimiter first, then, if this were the first fortune
402   from a particular file, it printed the name of the file in parentheses.
403   It now prints the first fortune without an initial delimiter; if the
404   fortune is the first from a particular file, it then prints
405   (filename), newline, delimiter, newline *to stderr*.  Redirect stderr to
406   stdout to get something *similar to* (but not the same as) the old
407   behavior.  The new behavior, if stderr is redirected to stdout, and
408   both are then redirected to a file, produces fictitious entries, one
409   per file in which a match was found.  However, whether stderr is
410   redirected or not, the new format produces files that strfile can
411   parse without choking (the old format, since it placed the filename
412   on the same line as the delimiter character, effectively forced editing
413   of the file in order to make it usable by strfile, unless the option of
414   concatenating two fortunes with an ugly "% (filename)" line separating
415   them was considered acceptable output).  Under the new display format,
416   if stderr is redirected into the file, you end up with filenames marking
417   the separation between files (as before), but they are now valid text
418   strings (which should probably, therefore, be deleted).
419
420   In other words, if you don't care what files the original text came from,
421   and want a new file containing (let us say), quotes from Mark Twain,
422   you might do:
423   fortune -am '-- Mark Twain' >twain
424   The files accessed would march down the screen; the fortunes would be
425   stored in parsable format into the file twain.  If, however, you planned
426   to edit (perhaps to remove the quotes from the original file, you might
427   then wish to redirect stderr to stdout.  Using bash:
428   fortune -am '-- Mark Twain' &>twain
429     or
430   fortune -am '-- Mark Twain' >twain 2>&1
431
432   [The above is now in the man page, more or less]
433
434 Late September, 1995
435   Too many changes to mention, really.  Look at the source code for
436   comments on individual files.  LINUX.DIF has been removed.
437
438   It is worth noting that strfile was completely broken as distributed,
439   and fortune had code to make it report a different file list than the
440   one it used to retrieve fortunes.  There's some rather strong language
441   on the subject in strfile.c; if it offends you, tough.
442
443   Bugs were fixed, and some enhancements were added.  Unstr, in
444   particular, has had its command line considerably enhanced.  Strfile
445   now *really does* sort, instead of merely setting the 'sorted' flag.
446   Ditto for randomizing.
447
448   Noteworthy: the way to distinguish between offensive and non-offensive
449   files has changed for fortune.  A second directory (which may be a
450   subdirectory of the main fortune directory; the program doesn't
451   add files recursively down a directory tree) has been added to
452   pathnames.h.  Offensive files should be placed there.  There is no
453   longer any need to add the -o suffix to file names, and the problems
454   with finding files (especially offensive ones) seem to have
455   disappeared in the process.
456
457   Currently, I'm working on breaking the fortune files themselves into
458   smaller, more manageable pieces, checking spelling, punctuation, and
459   grammar, and trying to reduce redundancy.  The eventual goal, after
460   the files are cleaned up, is another set of files carrying HTML tags,
461   which would then massively simplify a CGI script that calls fortune.
462
463   New Makefiles.
464
465   A 'randstr' (I want to call it 'lottery,' but I won't) utility, which
466   amounts to a poor woman's stripped-down fortune, to illustrate some
467   other possible uses of strfile-type random-access strings files.
468
469   Amy A. Lewis   alewis@email.unc.edu
470