HIDESTR(local)

NAME
hidestr - write a C prog to recover hidden strings

SYNOPSIS
hidestr string [ string2 [ string3 ... ] ] char *gethiddenstr(string_num)
  int string_num;

DESCRIPTION
hidestr produces C source for a procedure gethiddenstr() which is called with the string number (from 1 to N) of the original argument to hidestr, and returns a pointer to the clear text in an internal buffer. The caller can then copy the string to another buffer, or clear the buffer if needed. If the index is out of range a NULL value is returned.

The source output by hidestr may be compiled with TEST_HIDE defined to generate a tiny main program which will test the values storeg in the C code.

  Uses for hidestr
It is sometimes nice to put help for undocumented features, or copyright notices, etc, in a program in a way which prevents easy location and modification with readily available tools.

EXAMPLES
$ hidestr "Copyright (c) 1990, by joe" "all rights reserved" >cpr.c
$ cc -o testit -DTEST_HIDE cpr.c
$ ./testit
String  1: Copyright (c) 1990, by joe
String  2: all rights reserved
$ cc -c cpr.c
(and use this by)
  char *line, *gethidderstr();
  line = gethiddenstr(1);
  printf("%s\n", line);

FILES
none.

SEE ALSO
strings, od, hd, bpe, etc.

DIAGNOSTICS
none.

LIMITATIONS
Hard to use when many strings are needed. Also probably inappropriate.

AUTHOR
Original by David Vincenzetti, vince@ghost.dsi.unimi.it. It left the strings in global arrays. Modified by Bill Davidsen to write into a user buffer. davidsen@crd.ge.com also write the man page and Makefile (such as it is).

Copyright
None, but credit where credit is due, please.