home *** CD-ROM | disk | FTP | other *** search
/ ftp.wwiv.com / ftp.wwiv.com.zip / ftp.wwiv.com / pub / HATCH / WWIVNEWS.ZIP / 9509_2.NWS < prev    next >
Text File  |  1995-09-24  |  52KB  |  1,300 lines

  1. ───────────────┬─────────────────────────────────────────────┬───────────────
  2.            │            Understanding Viruses            │
  3.            │           Compiled by Sam (1@4051)          │
  4.            └─────────────────────────────────────────────┘
  5.  
  6. [This was taken from an FAQ I picked up on the net. It is a rather large
  7. article, which I will post in parts over the next few newsletters.]
  8.  
  9. What are computer viruses (and why should I worry about them)?
  10.  
  11. According to Fred Cohen's well-known definition, a COMPUTER VIRUS is a computer
  12. program that can infect other computer programs by modifying them in such a
  13. way as to include a (possibly evolved) copy of itself. Note that a program does
  14. not have to perform outright damage (such as deleting or corrupting files) in
  15. order to to be called a "virus". However, Cohen uses the terms within his
  16. definition (e.g. "program" and "modify") a bit differently from the way most
  17. anti-virus researchers use them, and classifies as viruses some things which
  18. most of us would not consider viruses.
  19.  
  20. Many people use the term loosely to cover any sort of program that tries to
  21. hide its (malicious) function and tries to spread onto as many computers as
  22. possible.  (See the definition of "Trojan".)  Be aware that what constitutes
  23. a "program" for a virus to infect may include a lot more than is at first
  24. obvious - don't assume too much about what a virus can or can't do!
  25.  
  26. These software "pranks" are very serious; they are spreading faster than they
  27. are being stopped, and even the least harmful of viruses could be fatal.  For
  28. example, a virus that stops your computer and displays a message, in the
  29. context of a hospital life-support computer, could be fatal.  Even those who
  30. created the viruses could not stop them if they wanted to; it requires a
  31. concerted effort from computer users to be "virus-aware", rather than the
  32. ignorance and ambivalence that have allowed them to grow to such a problem.
  33.  
  34.  
  35. What is a Trojan Horse?
  36.  
  37. A TROJAN HORSE is a program that does something undocumented which the pro-
  38. grammer intended, but that the user would not approve of if he knew about it.
  39. According to some people, a virus is a particular case of a Trojan Horse,
  40. namely one which is able to spread to other programs (i.e., it turns them
  41. into Trojans too).  According to others, a virus that does not do any
  42. deliberate damage (other than merely replicating) is not a Trojan.  Finally,
  43. despite the definitions, many people use the term "Trojan" to refer only to a
  44. *non-replicating* malicious program, so that the set of Trojans and the set of
  45. viruses are disjoint.
  46.  
  47.  
  48. What are the main types of PC viruses?
  49.  
  50. Generally, there are two main classes of viruses.  The first class consists of
  51. the FILE INFECTORS which attach themselves to ordinary program files.  These
  52. usually infect arbitrary .COM and/or .EXE programs, though some can infect any
  53. program for which execution is requested, such as .SYS, .OVL, .PRG, & .MNU
  54. files.
  55.  
  56. File infectors can be either DIRECT ACTION or RESIDENT.  A direct-action virus
  57. selects one or more other programs to infect each time the program which
  58. contains it is executed.  A resident virus hides itself somewhere in memory
  59. the first time an infected program is executed, and thereafter infects other
  60. programs when *they* are executed (as in the case of the Jerusalem) or when
  61. certain other conditions are fulfilled.  The Vienna is an example of a direct-
  62. action virus.  Most other viruses are resident.
  63.  
  64. The second category is SYSTEM or BOOT-RECORD INFECTORS: those viruses which
  65. infect executable code found in certain system areas on a disk which are not
  66. ordinary files.   On DOS systems, there are ordinary boot-sector viruses, which
  67. infect only the DOS boot sector, and MBR viruses which infect the Master Boot
  68. Record on fixed disks and the DOS boot sector on diskettes.  Examples include
  69. Brain, Stoned, Empire, Azusa, and Michelangelo.  Such viruses are always
  70. resident viruses.
  71.  
  72. Finally, a few viruses are able to infect both (the Tequila virus is one
  73. example).  These are often called "MULTI-PARTITE" viruses, though there has
  74. been criticism of this name; another name is "BOOT-AND-FILE" virus.
  75.  
  76. FILE SYSTEM or CLUSTER viruses (e.g. Dir-II) are those which modify directory
  77. table entries so that the virus is loaded and executed before the desired
  78. program is.  Note that the program itself is not physically altered, only the
  79. directory entry is.  Some consider these infectors to be a third category of
  80. viruses, while others consider them to be a sub-category of the file infectors.
  81.  
  82.  
  83. What is a stealth virus?
  84.  
  85. A STEALTH virus is one which hides the modifications it has made in the file or
  86. boot record, usually by monitoring the system functions used by programs to
  87. read files or physical blocks from storage media, and forging the results of
  88. such system functions so that programs which try to read these areas see the
  89. original uninfected form of the file instead of the actual infected form. Thus
  90. the viral modifications go undetected by anti-viral programs.  However, in
  91. order to do this, the virus must be resident in memory when the anti-viral
  92. program is executed.
  93.  
  94. Example: The very first DOS virus, Brain, a boot-sector infector, monitors
  95. physical disk I/O and re-directs any attempt to read a Brain-infected boot
  96. sector to the disk area where the original boot sector is stored.  The next
  97. viruses to use this technique were the file infectors Number of the Beast
  98. and Frodo (= 4096 = 4K).
  99.  
  100. Countermeasures: A "clean" system is needed so that no virus is present to
  101. distort the results.  Thus the system should be built from a trusted, clean
  102. master copy before any virus-checking is attempted; this is "The Golden Rule
  103. of the Trade."  With DOS, (1) boot from original DOS diskettes (i.e. DOS
  104. Startup/Program diskettes from a major vendor that have been write-protected
  105. since their creation); (2) use only tools from original diskettes until virus
  106. checking has completed.
  107.  
  108.  
  109. What is a polymorphic virus?
  110.  
  111. A POLYMORPHIC virus is one which produces varied (yet fully operational) copies
  112. of itself, in the hope that virus scanners will not be able to detect all
  113. instances of the virus.
  114.  
  115. One method to evade signature-driven virus scanners is self-encryption with a
  116. variable key; however these viruses (e.g. Cascade) are not termed "poly-
  117. morphic," as their decryption code is always the same and thus can be used as
  118. a virus signature even by the simplest, signature-driven virus scanners (unless
  119. another virus or program uses the identical decryption routine).
  120.  
  121. One method to make a polymorphic virus is to choose among a variety of different
  122. encryption schemes requiring different decryption routines: only one of these
  123. routines would be plainly visible in any instance of the virus (e.g. the Whale
  124. virus).  A signature-driven virus scanner would have to exploit several sig-
  125. natures (one for each possible encryption method) to reliably identify a virus
  126. of this kind.
  127.  
  128. A more sophisticated polymorphic virus (e.g. V2P6) will vary the sequence of
  129. instructions in its copies by interspersing it with "noise" instructions (e.g.
  130. a No Operation instruction, or an instruction to load a currently unused reg-
  131. ister with an arbitrary value), by interchanging mutually independent instruct-
  132. ions, or even by using various instruction sequences with identical net effects
  133. (e.g. Subtract A from A, and Move 0 to A).  A simple-minded, signature-based
  134. virus scanner would not be able to reliably identify this sort of virus;
  135. rather, a sophisticated "scanning engine" has to be constructed after thorough
  136. research into the particular virus.
  137.  
  138. The most sophisticated form of polymorphism discovered so far is the MtE
  139. "Mutation Engine" written by the Bulgarian virus writer who calls himself the
  140. "Dark Avenger".  It comes in the form of an object module. Any virus can be
  141. made polymorphic by adding certain calls to the assembler source code and
  142. linking to the mutation-engine and random-number-generator modules.
  143.  
  144. The advent of polymorphic viruses has rendered virus-scanning an ever more
  145. difficult and expensive endeavor; adding more and more search strings to simple
  146. scanners will not adequately deal with these viruses.
  147.  
  148.  
  149. What are fast and slow infectors?
  150.  
  151. A typical file infector (such as the Jerusalem) copies itself to memory when a
  152. program infected by it is executed, and then infects other programs when they
  153. are executed.
  154.  
  155. A FAST infector is a virus which, when it is active in memory, infects not only
  156. programs which are executed, but even those which are merely opened.  The re-
  157. sult is that if such a virus is in memory, running a scanner or integrity
  158. checker can result in all (or at least many) programs becoming infected all at
  159. once.  Examples are the Dark Avenger and the Frodo viruses.
  160.  
  161. The term "SLOW infector" is sometimes used for a virus which, if it is active
  162. in memory, infects only files as they are modified (or created).  The purpose
  163. is to fool people who use integrity checkers into thinking that the modifi-
  164. cation reported by the integrity checker is due solely to legitimate reasons.
  165. An example is the Darth Vader virus.
  166.  
  167.  
  168. What is a sparse infector?
  169.  
  170. The term "SPARSE infector" is sometimes given to a virus which infects only
  171. occasionally, e.g. every 10th executed file, or only files whose lengths fall
  172. within a narrow range, etc.  By infecting less often, such viruses try to
  173. minimize the probability of being discovered by the user.
  174.  
  175.  
  176. What is a companion virus?
  177.  
  178. A COMPANION virus is one which, instead of modifying an existing file, creates
  179. a new program which (unknown to the user) gets executed by the command-line
  180. interpreter instead of the intended program.  (On exit, the new program
  181. executes the original program so that things will appear normal.)  The only
  182. way this has been done so far is by creating an infected .COM file with the
  183. same name as an existing .EXE file. Note that those integrity checkers which
  184. look only for *modifications* in *existing* files will fail to detect such
  185. viruses.
  186.  
  187. (Note that not all researchers consider this type of malicious code to be a
  188. virus, since it does not modify existing files.)
  189.  
  190.  
  191. What is an armored virus?
  192.  
  193. An ARMORED virus is one which uses special tricks to make the tracing, dis-
  194. assembling and understanding of their code more difficult.  A good example is
  195. the Whale virus.
  196.  
  197.  
  198. Miscellaneous Jargon and Abbreviations
  199.  
  200. BSI = Boot Sector Infector: a virus which takes control when the computer
  201. attempts to boot (as opposed to a file infector).
  202.  
  203. CMOS = Complementary Metal Oxide Semiconductor: A memory area that is used in
  204. AT and higher class PCs for storage of system information. CMOS is battery
  205. backed RAM (see below), originally used to maintain date and time information
  206. while the PC was turned off.  CMOS memory is not in the normal CPU address
  207. space and cannot be executed.  While a virus may place data in the CMOS or may
  208. corrupt it, a virus cannot hide there.
  209.  
  210. DOS = Disk Operating System.  We use the term "DOS" to mean any of the MS-DOS,
  211. PC-DOS, or DR DOS systems for PCs and compatibles, even though there are
  212. operating systems called "DOS" on other (unrelated) machines.
  213.  
  214. MBR = Master Boot Record: the first Absolute sector (track 0, head 0, sector 1)
  215. on a PC hard disk, that usually contains the partition table (but on some PCs
  216. may simply contain a boot sector).  This is not the same as the first DOS sector
  217. (Logical sector 0).
  218.  
  219. RAM = Random Access Memory: the place programs are loaded into in order to
  220. execute; the significance for viruses is that, to be active, they must grab
  221. some of this for themselves.  However, some virus scanners may declare that
  222. a virus is active simply when it is found in RAM, even though it might be
  223. simply left over in a buffer area of RAM rather than truly being active.
  224.  
  225. TOM = Top Of Memory: the end of conventional memory, an architectural design
  226. limit at the 640K mark on most PCs.  Some early PCs may not be fully populated,
  227. but the amount of memory is always a multiple of 64K.  A boot-record virus on a
  228. PC typically resides just below this mark and changes the value which will be
  229. reported for the TOM to the location of the beginning of the virus so that it
  230. won't get overwritten.  Checking this value for changes can help detect a
  231. virus, but there are also legitimate reasons why it may change (see C11).  A
  232. very few PCs with unusual memory managers/settings may report in excess of
  233. 640K.
  234.  
  235. TSR = Terminate but Stay Resident: these are PC programs that stay in memory
  236. while you continue to use the computer for other purposes; they include pop-up
  237. utilities, network software, and the great majority of viruses.  These can
  238. often be seen using utilities such as MEM, MAPMEM, PMAP, F-MMAP and INFOPLUS.
  239.  
  240.  
  241.                     -=■=-
  242.  
  243. Here are a few lesser-known viruses I've found out about, and thought you
  244. should know about so that you may be on the lookout for them.....
  245.  
  246.  BOBBIT VIRUS: Removes a vital part of your hard disk then re-attaches it.
  247.  (But that part will never work again.)
  248.  
  249.  OPRAH WINFREY VIRUS: Your 200MB hard drive suddenly shrinks to 80MB and then
  250.  slowly expands back to 200MB.
  251.  
  252.  AT&T VIRUS: Every three minutes it tells you what great service you are
  253.  getting.
  254.  
  255.  MCI VIRUS: Every three minutes it reminds you that you are paying too much
  256.  for the AT&T virus.
  257.  
  258.  PAUL REVERE VIRUS: This revolutionary virus does not horse around. It warns
  259.  you of impending hard disk attack---once if by LAN, twice if by C:.
  260.  
  261.  POLITICALLY CORRECT VIRUS: Never calls itself a "virus", but instead refers
  262.  to itself as an "electric micro-organism."
  263.  
  264.  ROSS PEROT VIRUS: Activates every component in your system, just before the
  265.  whole damn thing quits.
  266.  
  267.  MARIO CUOMO VIRUS: It would be a great virus, but it refuses to run.
  268.  
  269.  TED TURNER VIRUS: Colorizes your monochrome monitor.
  270.  
  271.  ARNOLD SCHWARZENEGGER VIRUS: Terminates and stays resident. It'll be back.
  272.  
  273.  DAN QUAYLE VIRUS: Prevents your system from spawning any child process
  274.  without joining into a binary network.
  275.  
  276.  DAN QUAYLE VIRUS #2: Their is sumthing rong wit yor komputer, ewe just cant
  277.  figyour out watt!
  278.  
  279.  GOVERNMENT ECONOMIST VIRUS: Nothing works, but all your diagnostic software
  280.  says everything is fine.
  281.  
  282.  NEW WORLD ORDER VIRUS: Probably harmless, but it makes a lot of people
  283.  really mad just thinking about it.
  284.  
  285.  FEDERAL BUREAUCRAT VIRUS: Divides your hard disk into hundreds of little
  286.  units, each of which does practically nothing, but all of which claim to be
  287.  the most important part of your computer.
  288.  
  289.  GALLUP VIRUS: Sixty percent of the PCs infected will lose 38 percent of
  290.  their data 14 percent of the time.  (plus or minus a 3.5 percent
  291.  margin of error)
  292.  
  293.  TEXAS VIRUS: Makes sure that it is bigger than any other file.
  294.  
  295.  ADAM AND EVE VIRUS: Takes a couple of bytes out of your Apple.
  296.  
  297.  CONGRESSIONAL VIRUS: The computer locks up, screen splits erratically with a
  298.  message appearing on each half blaming the other side for the problem.
  299.  
  300.  AIRLINE VIRUS: You're in Dallas, but your data is in Singapore.
  301.  
  302.  FREUDIAN VIRUS: Your computer becomes obsessed with marrying its own
  303.  motherboard.
  304.  
  305.  PBS VIRUS: Your programs stop every few minutes to ask for money.
  306.  
  307.  OLLIE NORTH VIRUS: Causes your printer to become a paper shredder.
  308.  
  309.  NIKE VIRUS: Just does it.
  310.  
  311.  SEARS VIRUS: Your data won't appear unless you buy new cables, power supply
  312.  and a set of shocks.
  313.  
  314.  JIMMY HOFFA VIRUS: Your programs can never be found again.
  315.  
  316.  CONGRESSIONAL VIRUS #2: Runs every program on the hard drive simultaneously,
  317.  but doesn't allow the user to accomplish anything.
  318.  
  319.  STAR TREK VIRUS: Invades your system in places where no virus has gone
  320.  before.
  321.  
  322.  HEALTH CARE VIRUS: Tests your system for a day, finds nothing wrong, and
  323.  sends you a bill for $4,500.
  324.  
  325.  GEORGE BUSH VIRUS: It starts by boldly stating, "Read my docs... No new
  326.  files!" on the screen.  It proceeds to fill up all the free space on your
  327.  hard drive with new files, then blames it on the Congressional Virus.
  328.  
  329.                     -=■=-
  330. ───────────────┬─────────────────────────────────────────────┬───────────────
  331.            │                Type 2/0 Forum               │
  332.            │             Edited by Sam (1@4051)          │
  333.            └─────────────────────────────────────────────┘
  334.  
  335. Have a comment?  Got a beef?  Wanna issue long-overdue kudos?  Here is the
  336. for it!  Send your letters/comments/questions to Sam, 1@4051, for publication
  337. in WWIVNews.
  338.  
  339. ───────────────┬─────────────────────────────────────────────┬───────────────
  340.            │            Microsoft's  Bid to              │
  341.            │            Acquire the Vatican              │
  342.            │      (Quasi-TechNotes by Sam (1@4051))      │
  343.            └─────────────────────────────────────────────┘
  344.  
  345. [Note: In the absence of Omega Man's TechNOTES, which he has told me he will
  346. try to have in the next newsletter, I have attempted to try to fill the void
  347. until Omega Man readies his submission. I found this article on the AP news-
  348. wire, and thought some of you may find it interesting. I am for capitalism
  349. as much as anyone, but perhaps this time Mr Gates has gone to far....]
  350.  
  351.  
  352. MICROSOFT Bids to Acquire Catholic Church
  353. By Hank Vorjes
  354.  
  355. VATICAN CITY (AP) -- In a joint press conference in St. Peter's Square this
  356. morning, MICROSOFT Corp. and the Vatican announced that the Redmond software
  357. giant will acquire the Roman Catholic Church in exchange for an unspecified
  358. number of shares of MICROSOFT common stock. If the deal goes through, it will
  359. be the first time a computer software company has acquired a major world
  360. religion.
  361.  
  362. With the acquisition, Pope John Paul II will become the senior vice-president
  363. of the combined company's new Religious Software Division, while MICROSOFT
  364. senior vice-presidents Michael Maples and Steven Ballmer will be invested in
  365. the College of Cardinals, said MICROSOFT Chairman Bill Gates.
  366.  
  367. "We expect a lot of growth in the religious market in the next five to ten
  368. years," said Gates. "The combined resources of MICROSOFT and the Catholic
  369. Church will allow us to make religion easier and more fun for a broader range
  370. of people."
  371.  
  372. Through the MICROSOFT Network, the company's new on-line service, "we will
  373. make the sacraments available on-line for the first time" and revive the
  374. popular pre-Counter-Reformation practice of selling indulgences, said Gates.
  375. "You can get Communion, confess your sins, receive absolution -- even reduce
  376. your time in Purgatory -- all without leaving your home."
  377.  
  378. A new software application, MICROSOFT Church, will include a macro language
  379. which you can program to download heavenly graces automatically while you are
  380. away from your computer.
  381.  
  382. An estimated 17,000 people attended the announcement in St Peter's Square,
  383. watching on a 60-foot screen as comedian Don Novello -- in character as
  384. Father Guido Sarducci -- hosted the event, which was broadcast by satellite
  385. to 700 sites worldwide.
  386.  
  387. Pope John Paul II said little during the announcement. When Novello chided
  388. Gates, "Now I guess you get to wear one of these pointy hats," the crowd
  389. roared, but the pontiff's smile seemed strained.
  390.  
  391. The deal grants MICROSOFT exclusive electronic rights to the Bible and the
  392. Vatican's prized art collection, which includes works by such masters as
  393. Michelangelo and Da Vinci. But critics say MICROSOFT will face stiff challenges
  394. if it attempts to limit competitors' access to these key intellectual
  395. properties.
  396.  
  397. "The Jewish people invented the look and feel of the holy scriptures," said
  398. Rabbi David Gottschalk of Philadelphia. "You take the parting of the Red Sea
  399. -- we had that thousands of years before the Catholics came on the scene."
  400.  
  401. But others argue that the Catholic and Jewish faiths both draw on a common
  402. Abrahamic heritage. "The Catholic Church has just been more successful in
  403. marketing it to a larger audience," notes Notre Dame theologian Father
  404. Kenneth Madigan. Over the last 2,000 years, the Catholic Church's market
  405. share has increased dramatically, while Judaism, which was the first to
  406. offer many of the concepts now touted by Christianity, lags behind.
  407.  
  408. Historically, the Church has a reputation as an aggressive competitor,
  409. leading crusades to pressure people to upgrade to Catholicism, and entering
  410. into exclusive licensing arrangements in various kingdoms whereby all subjects
  411. were instilled with Catholicism, whether or not they planned to use it. Today
  412. Christianity is available from several denominations, but the Catholic version
  413. is still the most widely used. The Church's mission is to reach "the four
  414. corners of the earth," echoing MICROSOFT's vision of "a computer on every
  415. desktop and in every home".
  416.  
  417. Gates described MICROSOFT's long-term strategy to develop a scalable religious
  418. architecture that will support all religions through emulation. A single core
  419. religion will be offered with a choice of interfaces according to the religion
  420. desired -- "One religion, a couple of different implementations," said Gates.
  421.  
  422. The MICROSOFT move could spark a wave of mergers and acquisitions, according to
  423. Herb Peters, a spokesman for the U.S. Southern Baptist Conference, as other
  424. churches scramble to strengthen their position in the increasingly competitive
  425. religious market.
  426.  
  427. ───────────────┬─────────────────────────────────────────────┬───────────────
  428.            │           Filo's Mod of the Month           │
  429.            │              by Filo (1@4000)               │
  430.            └─────────────────────────────────────────────┘
  431.  
  432. The Mod of the Month is selected by Filo and represents his choice of what
  433. appears to be the most promising mod posted during the past month on Mod Net
  434. (subtype 2370). UUencoded mods are not considered for selection as part of the
  435. mod of the month due to the difficulty of including them in the WWIVnews. Mods
  436. which involve the use of related files such as ENHANCE.C, or any of the
  437. various COMMON type files are also not considered due to the amount of space
  438. required to include them here.  Many of these mods have NOT been tested by
  439. Filo and are selected based on their description as a promising, practical
  440. mod.
  441.  
  442. This month's selection is written by Papa Bear.
  443.  
  444. Papa Bear #1 @11579
  445.  
  446. ┌────────────────────────────A CEREBRUM RELEASE!─────────────────────────────┐
  447. │ Mod Name: SPV031IK.MOD     Mod Authors: 8-Ball                             │
  448. │ Difficulty: ▓▓▓▓▓▓░░░░ <<< TAKE NOTE!   Repo Man                           │
  449. │ Revision Dates: FIRST [01/10/92]        Captain EJ                         │
  450. │                 LAST  [07/18/95]        Pâpâ ßêâr  (1@11579 WW4net)        │
  451. │ WWIV Version: 4.24  [not for versions previous to 4.24!]                   │
  452. │ Files Affected: MSGBASE.C MSGBASE1.C READMAIL.C FCNS.H VARS.H VARDEC.H     │
  453. │ Description: 8-Ball's Quote Mod! As revised by Repo Man and myself.  Code  │
  454. │from Captain EJ included.  I think this is the *best* quote mod I've seen!  │
  455. │>>> NOW WORKS WITH NON-FSE's AS WELL AS FSE's!!! Added Anonymous support.   │
  456. ╞═────────────────────────────────────═╤═───────────────────────────────────═╡
  457. │ StarPort Valhalla [   ]   -     ASV 28.8kbps  Home of the SPV mod series!  │
  458. └─────────────────────────────────────═╧═────────────────────────────────────┘
  459.  
  460.              >>> OFFICIAL WWIV SUPPORT SITE! <<<
  461.  
  462.  Word of Warning:  You installed it, you're responsible! Make back-ups BEFORE
  463.  attempting to install this modification!  Read all text before beginning.
  464.  Again, READ THIS ENTIRE MOD >BEFORE< BEGINNING!
  465. ─────────────────────────────────────────────────────────────────────────────
  466.  LEGEND:
  467.  ==  Original Code [use this to search on]
  468.  ++  Add this Line [mods ALWAYS add stuff, don't they?]
  469.  --  Delete this Line [or comment out, its not needed]
  470.  -+  Change this Line [I usually comment these lines]
  471.  ... Skipping some code here [keeps the mod shorter]
  472. ─────────────────────────────────────────────────────────────────────────────
  473.  LONG DESCRIPTION:  The famous SPV modification redone for WWIV 4.24.  You
  474. should note that 4.24 introduced the M command at the mail prompt that will
  475. allow you reply to E-Mail to a different address than it was sent from.  For
  476. that reason, this that feature has been removed from this mod proper.  The @
  477. command will allow you to send a subboard post to a E-Mail address other than
  478. the one it originated from.
  479.  
  480. REVISION "K"
  481.   - Added ability to use the /Q command in WWIVEdit to quote text.
  482.   - Added #define so you could simply not bother FSED users with quoting
  483.     individual lines.  (Since the /Q now works.)
  484.   - Found a HUGE section of existing 4.24 coding that can now be removed.
  485.  
  486. To UPGRADE:
  487.   Find all occurances of SPV031IK and add/change/delete accordingly.  See
  488.   STEPs: 7, 9a, 11, 13a, 13b, 14, 15a
  489. ─────────────────────────────────────────────────────────────────────────────
  490. STEP 1: Add this line the the top of MSGBASE.C
  491.  
  492. == #include "vars.h"
  493. ==
  494. == #pragma hdrstop
  495.  
  496. == #include <mem.h>
  497. == #include <errno.h>
  498. == #include "subxtr.h"
  499. ++ #include <ctype.h>                                               // SPV031
  500. ==
  501. == #define ALLOW_FULLSCREEN 1
  502. ─────────────────────────────────────────────────────────────────────────────
  503. STEP 2: In MSGBASE.C, make the following changes in:
  504.     char *readfile(messagerec *m1, char *aux, long *l)
  505.  
  506. ==        return(NULL);
  507. ==      }
  508. ==      l1=filelength(f);
  509. -+      if ((b=malloca(l1+2L))==NULL) {                   // SPV031 - add +2L
  510. ==        sh_close(f);
  511. ==        return(NULL);
  512. ==      }
  513. . . . SKIPPING SOME LINES HERE, TAKE CARE TO NOTE THE PROPER LOCATION! . . .
  514. ==        return(NULL);
  515.  ==      }
  516. ==      l1=filelength(f);
  517. -+      if ((b=malloca(l1+258L))==NULL) {       // SPV031 - change 256 to 258
  518. ==        sh_close(f);
  519. ==        return(NULL);
  520. ==      }
  521. ==      sh_read(f,(void *)b,l1);
  522. ─────────────────────────────────────────────────────────────────────────────
  523. STEP 3: Add these variable declarations in MSGBASE.C to  void inmsg(...)
  524.  
  525. ==  struct {char tlen, ttl[81], anon; } fedit_data;
  526. ==  xtrasubsnetrec *xnp;
  527. ==  char q_txt[256];
  528. ++  FILE *pbquote;                                                  // SPV031
  529. ++  char pb[13],pb1[161];                                           // SPV031
  530. ++  int j=0;                                                        // SPV031
  531. ==
  532. ==  oiia=iia;
  533. ─────────────────────────────────────────────────────────────────────────────
  534. STEP 3a:  Add these lines in the same function
  535.  
  536. ==    inputl(title,60);
  537. ==  }
  538. ==  if ((title[0]==0) && (needtitle)) {
  539.  
  540. // SPV031 block START
  541.     sprintf(pb1,"%sINPUT.MSG",syscfgovr.tempdir);
  542.     unlink(pb1);
  543. // SPV031 block END
  544.  
  545. ==    pl(get_string(14));
  546. ==    m.stored_as=0xffffffff;
  547. ─────────────────────────────────────────────────────────────────────────────
  548. STEP 4: Still in void inmsg(...) a little ways down, make these changes
  549.  
  550. ==    outstr(get_string(627));
  551. ==    pln(maxli);
  552. ==    pl(get_string(628));
  553. // SPV031 block START
  554.     if (quoted) {
  555.       nl();
  556.       pl("9Type 1/Q9 in the message to view the quoted text!0");
  557.       nl();
  558.     }
  559. // SPV031 block END
  560. ==    strcpy(s,get_string(629));
  561. ==    s[thisuser.screenchars]=0;
  562. ==    pl(s);
  563. . . . JUST A LITTLE FURTHER DOWN NOW . . .
  564. ==        if (stricmp(s,get_string(942))==0) {
  565. ==          savel=0;
  566. ==          printmenu(2);
  567. ==        }
  568. // START SPV031 BLOCK COPY
  569.         if (stricmp(s,"/Q")==0) {
  570. //        if (stricmp(stripcolors(s),"/Q")==0) {          // NOTE 1 -- SPV031
  571.           if (quoted) {
  572.             sprintf(pb,"%sINPUT.MSG",syscfgovr.tempdir);
  573.             printfile(pb);
  574.           } else {
  575.             nl();
  576.             pl("6You must quote the message you're replying to to0");
  577.             pl("6use this command.  Please continue your message.0");
  578.             nl();
  579.       }
  580.         }
  581. // END SPV031 BLOCK COPY
  582. ==        if (stricmp(s,get_string(943))==0) {
  583. ==          savel=0;
  584. ==          prt(5,get_string(630));
  585.  
  586. NOTE 1: If using FMD's FMD-39A.MOD (keep color) uncomment this line, and
  587.         comment out the one ABOVE it!
  588. ─────────────────────────────────────────────────────────────────────────────
  589. STEP 5: Still in void inmsg(...) a LOT further down, make these changes
  590.  
  591. ==      sh_read(i5, (void *) (& (b[l1]) ),ll);
  592. ==      l1 += ll;
  593. ==      sh_close(i5);
  594. ==    } else {
  595. // START SPV031 BLOCK COPY
  596.       if (quoted) {
  597.         sprintf(pb,"%sINPUT.MSG",syscfgovr.tempdir);
  598.         pbquote=fsh_open(pb,"rt");
  599.     if (!pbquote) {
  600.           nl();
  601.           pl(get_stringx(4,91));
  602.       j=0;
  603.       nl();
  604.         } else {
  605.           do {
  606.             fgets(pb1,160,pbquote);
  607.             addline(b,pb1,&l1);
  608.           } while (!feof(pbquote));
  609.         }
  610.         fsh_close(pbquote);
  611.         unlink(pb);
  612.       }
  613.       nl();
  614.       if (j)
  615.         pl(get_stringx(4,92));
  616. // END SPV031 BLOCK COPY
  617. ==      for (i5=0; i5<curli; i5++)
  618. ==        addline(b,&(lin[i5*LEN]),&l1);
  619. ==    }
  620. ==
  621. ==    if (sysinfo.flags & OP_FLAGS_MSG_TAG) {
  622. ─────────────────────────────────────────────────────────────────────────────
  623. STEP 5a: Add these lines a bit further down:
  624.  
  625. ==    if (fsed)
  626. ==      unlink(fnx);
  627. ==    pl(get_string(14));
  628.  
  629. // SPV031 block START
  630.     sprintf(pb1,"%sINPUT.MSG",syscfgovr.tempdir);
  631.     unlink(pb1);
  632. // SPV031 block END
  633.  
  634. ==    m.stored_as=0xffffffff;
  635. ==  }
  636. ==  *m1=m;
  637. ─────────────────────────────────────────────────────────────────────────────
  638. STEP 6: Add these lines in MSGBASE.C
  639.  
  640. ==    if (an) {
  641. ==      strcat(s,nam(&ur,un));
  642. ==      sysoplog(s);
  643. ++      Unknown=0;                                                  // SPV031
  644. ==    } else {
  645. ++      Unknown=1;                                                  // SPV031
  646. ==      strcpy(s1,s);
  647. ==      strcat(s1,nam(&ur,un));
  648. ==      sysoplog(s1);
  649. ==      strcat(s,get_string(482));
  650. . . . A little farther down . . .
  651. ==    if (an) {
  652. ==      read_user(un,&ur);
  653. ==      strcpy(s2,nam(&ur,un));
  654. ++      Unknown=0;                                                  // SPV031
  655. -+    } else {                                              // SPV031 added {
  656. ++      Unknown=1;                                                  // SPV031
  657. ==      strcpy(s2,get_string(482));
  658. ++    }                                                             // SPV031
  659. ==  } else {
  660. ==    if (net_num_max>1) {
  661. ─────────────────────────────────────────────────────────────────────────────
  662. STEP 7: Add these three functions to the end of MSGBASE.C
  663.  
  664. // SPV031 BLOCK COPY START
  665. void extract_out2(char *org, long len, int type, long daten)
  666. {
  667.   char s[255],s1[81],s2[81],*p,buf[255],*b,tb[81],tb1[81],b1[81],pb[81],ch;
  668.   int i,ii=0,j,jj,length,qnq=1,line_control,done,k;
  669.   FILE *Output;
  670.  
  671.   printfile("QUOTE");
  672.   if (!okfsed())
  673.     pausescr();
  674.   nl();
  675.   quoted=0;
  676. #ifdef BOTHER_USER_QUOTE                                          // SPV031IK
  677.   if (okfsed()) {
  678.     npr("5Do you want to select the lines to quote? 0");
  679.     if (!yn())
  680.       qnq=0;
  681.     else
  682.       outchr(12);
  683.   } else
  684.     outchr(12);
  685. #else                                                             // SPV031IK
  686.   if (okfsed())                                                   // SPV031IK
  687.     qnq=0;                                                        // SPV031IK
  688.   else                                                            // SPV031IK
  689.     outchr(12);                                                   // SPV031IK
  690. #endif                                                            // SPV031IK
  691.   p=b=org;
  692.   if (!hangup) {
  693.     sprintf(s2,"%sINPUT.MSG",syscfgovr.tempdir);
  694.     unlink(s2);
  695.     if ((Output=fopen(s2,"w+t"))==NULL) {
  696.       sprintf(s,"6ERR2: 9Could not create 1%s9! 5(1quote file5)0");
  697.       nl();
  698.       if (so())
  699.     pl(s);
  700.       else {
  701.         ssm(1,0,s);
  702.     pl("6Could not create quote file -- SysOp notified!0");
  703.       }
  704.       nl();
  705.       return;
  706.     }
  707.     while (*p!='\r')
  708.       ++p;
  709.      *p='\0';
  710.     strcpy(s1,b);
  711.     p+=2;
  712.     len=len-(p-b);
  713.     b=p;
  714.     while (*p!='\r')
  715.       ++p;
  716.     p+=2;
  717.     len=len-(p-b);
  718.     b=p;
  719.     sprintf(pb,"%s",ctime(&daten));
  720.     sprintf(s2,"1%s7, 1%s7. 1%s7, 1%s0",
  721.            (strnncpy(pb,0,2)),
  722.        (strnncpy(pb,4,6)),
  723.        (strnncpy(pb,8,9)),
  724.            (strnncpy(pb,20,23)));
  725.     strcpy(tb1,stripcolors(strip_to_node(s1)));
  726.     properize(tb1);
  727.     if (strlen(tb1)%2!=0)
  728.       sprintf(tb," %s",tb1);
  729.     else
  730.       strcpy(tb,tb1);
  731.     jj=tb1[0]=0;
  732.     for (j=0;j<strlen(tb);j++) {
  733.       if ((toupper(tb[j])==tb[j]) &&
  734.         (isalpha(tb[j]))) {
  735.         tb1[jj]=tb[j];
  736.         tb1[jj+1]=0;
  737.         jj++;
  738.       }
  739.     }
  740.     if (!tb1[0]) {
  741.       if (tb[0]==32)
  742.     tb1[0]=tb[1];
  743.       else
  744.         tb1[0]=tb[0];
  745.       tb1[1]=0;
  746.     }
  747.     if (Unknown) {
  748.       sprintf(tb," %s",get_string(482));
  749.       strcpy(tb1,"6>2U6<0");
  750.       Unknown=0;
  751.     }
  752.     switch (type) {
  753.       case 1:
  754.         sprintf(buf,"3» 9In your E-Mail of 1%s7,9 you wrote: 3«0",s2);
  755.         break;
  756.       case 2:
  757.         sprintf(buf,
  758.          "3» 9This was forwarded from 1%s9, sent on 1%s9. 3«0",tb,s2);
  759.     break;
  760.       case 3:
  761.         sprintf(buf,
  762.           "3» 9In a message posted 1%s7,9 you wrote: 3«0",s2);
  763.     break;
  764.       case 4:
  765.         sprintf(buf,"3» 9On 1%s7, 1%s9 said this: 3«0",s2,tb);
  766.         break;
  767.     }
  768.     length=0;
  769.     for (j=0;j<strlen(buf);j++) {
  770.       if ((buf[j]!='\003') && (buf[j-1]!='\003'))
  771.         length++;
  772.     }
  773.     jj=(39-(length/2));
  774.     fprintf(Output,"2%s%s%s0\n",charstr(jj,196),buf,charstr(jj,196));
  775.     line_control=1;
  776.     done=0;
  777.     k=77-strlen(tb1);
  778.     while ((len>0) && (!done) && (!hangup)) {
  779.       while ((strchr("\r\001",*p)==NULL) && ((p-b)<(len<253 ? len : 253)))
  780.         ++p;
  781.       if (*p=='\001')
  782.     *(p++)='\0';
  783.       *p='\0';
  784.       if ((*b!='\004') && (strchr(b,'\033')==NULL)) {
  785.         for (j=0;j<k;j++) {
  786.           if (((b[j]=='0') && (b[j-1]!='\003')) || (b[j]!='0'))
  787.             b1[j]=b[j];
  788.           else
  789.             b1[j]='7';
  790.           b1[j+1]=0;
  791.         }
  792.         if ((qnq) && (line_control>thisuser.screenlines)) {
  793.           line_control=0;
  794.           outchr(12);
  795.         }
  796.         if ((qnq) && (okansi())) {
  797.           goxy(0,line_control);
  798.           line_control++;
  799.     }
  800.         if ((ii) && (okansi()) && (qnq)) {
  801.           pl(charstr(79,32));
  802.       goxy(0,line_control-1);
  803.     }
  804.         sprintf(buf,"1%s7»9%s0",tb1,b1);
  805.         if (qnq) {
  806.           if (!okansi())
  807.             outchr(12);
  808.           pl(buf);
  809.           if (okansi()) {
  810.             goxy(0,line_control);
  811.             line_control++;
  812.           }
  813.           npr(
  814. "5Quote this line? 3(1[2Y1]es, [2n1]o, [2q1]uit, [2a1]bort3) 0");
  815.           ch=onek("QY\rNA");
  816.           switch (ch) {
  817.             case '\r':
  818.             case 'Y':
  819.           fprintf(Output,"%s\n",buf);
  820.               quoted=1;
  821.               ii=0;
  822.           line_control--;
  823.           goxy(0,line_control);
  824.               pl(charstr(79,32));
  825.               done=0;
  826.               break;
  827.             case 'N':
  828.               line_control-=2;
  829.               ii=1;
  830.               done=0;
  831.               break;
  832.             case 'A':
  833.               pl("Aborted!");
  834.               quoted=0;
  835.               done=1;
  836.               break;
  837.             default:
  838.             case 'Q':
  839.           done=1;
  840.               break;
  841.           }
  842.     } else {
  843.       fprintf(Output,"%s\n",buf);
  844.           quoted=1;
  845.         }
  846.       }
  847.       p+=2;
  848.       len=len-(p-b);
  849.       b=p;
  850.     }
  851.     nl();
  852.     pl("5Enter your reply text 3(1default6: 2My reply to this3)0");
  853.     mpl(60);
  854.     inputl(s,60);
  855.     if (!s[0])
  856.       strcpy(s,"My reply to this");
  857.     jj=(39-((strlen(s)+4)/2));
  858.     fprintf(Output,"2%s3» 4%s3 «2%s0\n",
  859.         charstr(jj,196),s,charstr(jj,196));
  860.     outchr(12);
  861.     if (!okfsed())
  862.       fprintf(Output,"\n");
  863.     fclose(Output);
  864. //    if (!quoted) {                                      // SPV031IK removed
  865. //      sprintf(s2,"%sINPUT.MSG",syscfgovr.tempdir);      // SPV031IK removed
  866. //      unlink(s2);                                       // SPV031IK removed
  867. //    }                                                   // SPV031IK removed
  868.   }
  869.   farfree(org);
  870. }
  871.  
  872. char *strip_to_node(char *txt)
  873. {
  874.   int i,ok,ok1,i1=-1;
  875.   char s[81],s1[81];
  876.  
  877.   if (txt[0]==96 && txt[1]==96) {
  878.     for (i=2;(i<=strlen(txt)) && (txt[i]!=96);i++) {
  879.        s[i-2]=txt[i];
  880.        s[i-1]=0;
  881.     }
  882.     return(s);
  883.   }
  884.   if (strstr(txt,"AT")) {
  885.     ok=1;
  886.     for (i=2; i<strlen(txt); i++) {
  887.       if (ok) {
  888.         s[++i1]=txt[i];
  889.         s[i1+1]=0;
  890.       }
  891.       if (txt[i+1]==96)
  892.         ok=0;
  893.     }
  894.     return(s);
  895.   }
  896.   if (strstr(txt,"@")) {
  897.     if (strstr(txt,"#")==NULL) {
  898.       strcpy(s1,strrev(txt));
  899.       ok=ok1=0;
  900.       for (i=0;i<strlen(s1);i++) {
  901.         if ((ok) && (ok1)) {
  902.       s[i1++]=s1[i];
  903.       s[i1+1]=0;
  904.         }
  905.         if ((ok1) && (!ok)) {
  906.           if (s1[i+1]==32)
  907.             ok=1;
  908.         }
  909.         if ((s1[i]==64) && (!ok1))
  910.           ok1=1;
  911.       }
  912.       return(strrev(s));
  913.     } else {
  914.       ok=1;
  915.       for (i=0; i<strlen(txt); i++) {
  916.         if (ok) {
  917.           s[i]=txt[i];
  918.           s[i+1]=0;
  919.     }
  920.         if (txt[i+2]==35)
  921.           ok=0;
  922.       }
  923.       return(s);
  924.     }
  925.   }
  926.   return(txt);
  927. }
  928.  
  929. char *strnncpy(char *str_parse, int start_ch, int end_ch)
  930. {
  931.   int i,j=0;
  932.   char s[255];
  933.  
  934.   if (start_ch<0)
  935.     start_ch=0;
  936.   if (end_ch>(strlen(str_parse)))
  937.     end_ch=strlen(str_parse);
  938.   for (i=start_ch;i<(end_ch+1);i++) {
  939.     s[j]=str_parse[i];
  940.     s[j+1]=0;
  941.     j++;
  942.   }
  943.   return(s);
  944. }
  945. // SPV031 BLOCK COPY END
  946.  
  947. NOTE:  To use this function, simply call it something like:
  948.  
  949.   strcpy(s,(strnncpy("This is a test",5,8)));
  950.  
  951.   This places "is a" into the variable s.
  952. ─────────────────────────────────────────────────────────────────────────────
  953. STEP 8: Prototype the function ins FCNS.H:
  954.  
  955. == int existprint(unsigned char *fn);
  956. == void read_message(int n, int *next, int *val);
  957. == void lineadd(messagerec *m1, char *sx, char *aux);
  958. ++ void extract_out2(char *org, long len, int type, long daten);     //SPV031
  959. ++ char *strip_to_node(char *txt);                                   //SPV031
  960. ++ char *strnncpy(char *str_parse, int start_ch, int end_ch);        //SPV031
  961. ==
  962. == /* File: msgbase1.c */
  963. ─────────────────────────────────────────────────────────────────────────────
  964. STEP 9: Add these global variable declarations to VARS.H in the __EXTRN__
  965.         int section:
  966.  
  967. ==               use_workspace, using_modem, wfc, x_only,
  968. ==               instance,debuglevel,multitasker,tagging,tagptr,cursormove,
  969. -+              titled, abortext,quoted,Unknown;                    // SPV031
  970. ==
  971. == __EXTRN__ unsigned short com_speed, *csn_index, crc, *gat, modem_flag,
  972. ==                       modem_mode, modem_speed, net_sysnum, curloc, eflags;
  973. ─────────────────────────────────────────────────────────────────────────────
  974. STEP 9a:  Add this line to the top of VARDEC.H
  975.  
  976. == #ifndef __OS2__
  977. == #define RIPDRIVE
  978. == #endif
  979. ==
  980. ++ #define BOTHER_USER_QUOTE                               // SPV031IK - NOTE
  981. ==
  982. == #define OK_LEVEL 0
  983. == #define NOK_LEVEL 1
  984.  
  985. NOTE : Comment this line out if you don't want to bother your users by asking
  986.        them if they want to quote.  With this commented out, it will quote
  987.        everytime.  Additionally, when commented out, it'll stop asking FSED
  988.        users if they want to quote by line ('cause the /Q works in WWIVEdit
  989.        now.)
  990. ─────────────────────────────────────────────────────────────────────────────
  991. STEP 10: In MSGBASE1.C, add this line in
  992.          void scan(int msgnum, int optype, int *nextsub)
  993.  
  994. ==    write_inst(INST_LOC_SUBS, usub[cursub].subnum, INST_FLAGS_NONE);
  995. ==    switch(optype) {
  996. ==      case 0: /* Read Prompt */
  997. ++        quoted=0;                                                 // SPV031
  998. ==        if (E_C) {
  999. ==          sprintf(s,"1%s0:7(11-%u,^%u7)1,? 0: ",get_string(678),
  1000. ==            nummsgs,msgnum);
  1001. ─────────────────────────────────────────────────────────────────────────────
  1002. STEP 11: In MSGBASE1.C, make the following changes in:
  1003.      void scan(int msgnum, int optype, int *nextsub)
  1004.  
  1005. ==          optype=2;
  1006. ==          msgnum=i;
  1007. ==        } else
  1008. ==          if (s[1]==0) {
  1009. // START SPV031 BLOCK COPY
  1010.             if ((s[0]=='A') || (s[0]=='W')) {
  1011. #ifdef BOTHER_USER_QUOTE                                          // SPV031IK
  1012.               nl();
  1013.               npr("5Quote from this message? 0");
  1014.               if (ny()) {
  1015. #endif                                                            // SPV031IK
  1016.                 p2=*get_post(msgnum);
  1017.                 grab_quotes(&(p2.msg),subboards[curlsub].filename);
  1018.                 if ((msgnum>0) && (msgnum<=nummsgs)) {
  1019.           b=readfile(&(get_post(msgnum)->msg),
  1020.                             (subboards[curlsub].filename),&len);
  1021.                   extract_out2(b,len,((s[0]=='A')?3:4),p2.daten);
  1022.         }
  1023. #ifdef BOTHER_USER_QUOTE                                          // SPV031IK
  1024.               }
  1025. #endif                                                            // SPV031IK
  1026.             }
  1027. // END SPV031 BLOCK COPY
  1028. ==            switch(s[0]) {
  1029. ==
  1030. ==              /* Find addition */
  1031. ─────────────────────────────────────────────────────────────────────────────
  1032. STEP 12: In MSGBASE1.C, make the following changes in:
  1033.          void scan(int msgnum, int optype, int *nextsub)
  1034.  
  1035. ++              case '@':                                         // SPV031
  1036. ==              case 'A':
  1037. ==                if (rip_on()) {
  1038. ==                  sprintf(s,"\n!|w000%c271610|e|#\r ", formery);
  1039. ==                  comstr(s);
  1040. . . . SKIPPING DOWN A HAIR . . .
  1041. ==                    pl(get_string(679));
  1042. ==                    break;
  1043. ==                  }
  1044. ==                }
  1045. // START SPV031 BLOCK COPY
  1046.                 if (s[0]=='@') {
  1047.                   nl();
  1048.                   pl("4Replying to a different address!0");
  1049.                   send_email();
  1050.                 } else {
  1051. // END SPV031 BLOCK COPY
  1052. ==                  if ((lcs()) || (ss.ability & ability_read_post_anony) ||
  1053. ==                     (get_post(msgnum)->anony==0))
  1054. ==                  else
  1055. ==                    email(get_post(msgnum)->owneruser,
  1056. ==                     get_post(msgnum)->ownersys,0,get_post(msgnum)->anony);
  1057.  
  1058. ++                }                                         // SPV031 added }
  1059.  
  1060. ==                irt_sub[0]=0;
  1061. ==                grab_quotes(NULL, NULL);
  1062.  
  1063.   DID YOU ADD THE } (4 LINES ABOVE HERE)
  1064. ─────────────────────────────────────────────────────────────────────────────
  1065. STEP 13: Make these changes in MSGBASE1.C, function:
  1066.          void scan(int msgnum, int optype, int *nextsub)
  1067.  
  1068. ==            if ((msgs[msgnum].anony & anony_sender) &&
  1069. ==              ((syscfg.sl[actsl].ability & ability_read_post_anony)==0)) {
  1070. ==                strcat(s,get_string(482));
  1071. ++              Unknown=1;                                          // SPV031
  1072. ==            } else {
  1073. ++              Unknown=0;                                          // SPV031
  1074. ==              b=readfile(&(msgs[msgnum].msg),(subboards[curlsub].filename),
  1075. ==                         &len);
  1076. ─────────────────────────────────────────────────────────────────────────────
  1077. STEP 13a: Add these lines to MSGBASE1.C
  1078.           void grab_quotes(messagerec *m, char *aux):
  1079.  
  1080.  
  1081. ++ //#define REMOVE_COLOR                                    // SPV031IK NOTE
  1082. ==
  1083. == void grab_quotes(messagerec *m, char *aux)
  1084. == {
  1085. ++   FILE *File;                                                  // SPV031IK
  1086. ++   char ch,pb[161],pb1[161];                                    // SPV031IK
  1087. ==   char *ss,*ss1;
  1088. ==   long l,l1,l2,l3;
  1089. ==   FILE *f;
  1090.  
  1091. NOTE: Normally this mod adds quite a bit of color to the quoted text.  In
  1092.       using the /Q mode of WWIVEdit, all this color *can* cause the editor
  1093.       to add extra, blank, lines.  These lines can easily be removed by you
  1094.       using CTRL-Y on the blank line.  (This is due to the line length being
  1095.       80 instead of 79 characters.)  If you want a more ordered output, one
  1096.       that has no blank lines, and no color as well, then uncomment this
  1097.       line (#define REMOVE_COLOR).
  1098. ─────────────────────────────────────────────────────────────────────────────
  1099. STEP 13b: Now add this block at the end of the same function:
  1100.  
  1101. ==        quotes_nrm=NULL;
  1102. ==        quotes_nrm_l=0;
  1103. == #endif
  1104. ==      }
  1105. ==    }
  1106. ==  }
  1107.  
  1108. // START SPV031IK block copy
  1109.   sprintf(q_txt,"%sINPUT.MSG",syscfgovr.tempdir);
  1110.   if (exist(q_txt)) {
  1111.     f=fopen(q_txt,"rt");
  1112.     sprintf(q_txt,"%sQUOTES.TXT",syscfgovr.tempdir);
  1113.     File=fopen(q_txt,"wt");
  1114.     fputs(" \n \n",File);
  1115.     pb1[0]=0;
  1116.     while ((!hangup) && (!feof(f))) {
  1117.       fgets(pb,160,f);
  1118.       if (strcmp(pb,pb1)) {
  1119.     strcpy(pb1,pb);
  1120. #ifdef REMOVE_COLOR
  1121.         fprintf(File,"%-79s",stripcolors(pb));
  1122. #else
  1123.     fprintf(File,"%s",pb);
  1124. #endif
  1125.       }
  1126.     }
  1127.     fclose(f);
  1128.     fclose(File);
  1129.     nl();
  1130.     npr("5Auto-Display quoted text in editor? 0");
  1131.     if (!ny()) {
  1132.       sprintf(q_txt,"%sINPUT.MSG",syscfgovr.tempdir);
  1133.       unlink(q_txt);
  1134.     }
  1135.   }
  1136. // END SPV031IK block copy
  1137.  
  1138. == }
  1139. ─────────────────────────────────────────────────────────────────────────────
  1140. STEP 14: Now in READMAIL.C make these changes in void readmail(void)
  1141.  
  1142. ==            pl(get_string(715));
  1143. ==            nl();
  1144. ==            break;
  1145. ==          }
  1146. ==          nln(2);
  1147. // START SPV031 BLOCK COPY
  1148. #ifdef BOTHER_USER_QUOTE                                          // SPV031IK
  1149.           nl();
  1150.           npr("5Quote this message?0 ");
  1151.           if (ny()) {
  1152. #endif                                                            // SPV031IK
  1153.             b=readfile(&(m.msg),"EMAIL",&len);
  1154.             extract_out2(b,len,2,m.daten);
  1155.             nl();
  1156.             pl("6Forwarding this E-Mail.0");
  1157.             send_email();
  1158. //            break;                            // SPV031IK REMOVED THIS LINE
  1159. #ifdef BOTHER_USER_QUOTE                                          // SPV031IK
  1160.           }
  1161. #endif                                                            // SPV031IK
  1162. // END SPV031 BLOCK COPY
  1163. ==          prt(2,get_string(716));
  1164. ==          input(s,75);
  1165. . . . SKIPPING SOME MORE LINES! . . .
  1166. ==        case 'A':
  1167. ==        case 'S':
  1168. ==        case 'M':
  1169. // START SPV031 BLOCK READ
  1170. #ifdef BOTHER_USER_QUOTE                                          // SPV031IK
  1171.           nl();
  1172.           npr("5Quote from this message? 0");
  1173.           if (ny()) {
  1174. #endif                                                            // SPV031IK
  1175.             grab_quotes(&(m.msg),"EMAIL");
  1176.             b=readfile(&(m.msg),"EMAIL",&len);
  1177.             extract_out2(b,len,((ch=='M')?2:1),m.daten);
  1178.             if (ch=='M') {
  1179.           nl();
  1180.               pl("5Forwarding this E-Mail!0");
  1181.             }
  1182. #ifdef BOTHER_USER_QUOTE                                          // SPV031IK
  1183.       }
  1184. #endif                                                            // SPV031IK
  1185. // END SPV031 BLOCK READ
  1186. ==          if (rip_on()) {
  1187. ==            sprintf(s,"\n!|w000%c271610|e|#\r ", formery);
  1188. . . .SKIP DOWN JUST A FEW MORE LINES . . .
  1189. ==            i2=0;
  1190. ==            break;
  1191. ==          } else if (m.fromuser!=65535) {
  1192.  
  1193. --            grab_quotes(&(m.msg),"EMAIL");       // SPV031 delete this line
  1194.  
  1195. ==            if (ch=='M') {
  1196. ─────────────────────────────────────────────────────────────────────────────
  1197. STEP 15: Make these changes throughout READMAIL.C
  1198.  
  1199. ==      sprintf(s,"2%3d 7%c0 ",i+1,okansi()?'│':'|');
  1200. ==      if ((m.anony & anony_sender) &&
  1201. ==          ((ss.ability & ability_read_email_anony)==0)) {
  1202. ==        strcat(s,get_string(482));
  1203. ++        Unknown=1;                                                // SPV031
  1204. ==      } else {
  1205. ++        Unknown=0;                                                // SPV031
  1206. ==        if (m.fromsys==0) {
  1207. ==          if (m.fromuser==65535) {
  1208. . . . SKIPPING DOWN . . .
  1209. ==                  strcpy(s,nam1(&thisuser,usernum,net_sysnum));
  1210. -+                if (m.anony & anony_receiver) {           // SPV031 added {
  1211. ==                  strcpy(s,get_string(482));
  1212. ++                  Unknown=1;
  1213. ++                } else
  1214. ++                  Unknown=0;
  1215. ==                strcat(s,get_string(713));
  1216. . . . DOWN SOME MORE . . .
  1217. ==            sprintf(s,"%s: %s",net_name,nam1(&thisuser,usernum,net_sysnum));
  1218. ==          else
  1219. ==            strcpy(s,nam1(&thisuser,usernum,net_sysnum));
  1220. -+          if (m.anony & anony_receiver) {                 // SPV031 added {
  1221. ==            strcpy(s,get_string(482));
  1222. ++            Unknown=1;
  1223. ++          } else
  1224. ++            Unknown=0;
  1225. ==          strcat(s,get_string(713));
  1226. . . .YEP, GO DOWN SOME MORE! (YES IT LOOKS THE SAME AS ABOVE). . .
  1227. ==            sprintf(s,"%s: %s",net_name,nam1(&thisuser,usernum,net_sysnum));
  1228. ==          else
  1229. ==            strcpy(s,nam1(&thisuser,usernum,net_sysnum));
  1230. -+          if (m.anony & anony_receiver) {                 // SPV031 added {
  1231. ==            strcpy(s,get_string(482));
  1232. ++            Unknown=1;
  1233. ++          } else
  1234. ++            Unknown=0;
  1235. ==          strcat(s,get_string(713));
  1236. ==          strcat(s,date());
  1237. ─────────────────────────────────────────────────────────────────────────────
  1238. STEP 15a: Go back to the top of the top of the void readmail(void) function
  1239.       and find this large block of code.  Remove it all.
  1240.  
  1241. // SPV031IK START CODE REMOVAL
  1242. --          prt(2,get_string(716));
  1243. --          input(s,75);
  1244.  
  1245. . . . continue removing (commenting out) code all the way down to here . . .
  1246.  
  1247. --                  if ((!wfc) && (incom))
  1248. --                    topscreen();
  1249. --                  mailcheck=1;
  1250. --                }
  1251. --              }
  1252. --            }
  1253. --          }
  1254. // SPV031IK END CODE REMOVAL
  1255. ==          break;
  1256. ==        case 'A':
  1257. ==        case 'S':
  1258. ==        case 'M':
  1259. ─────────────────────────────────────────────────────────────────────────────
  1260. STEP 16: In NEWUSER.C, make this change in: void properize(char *s)
  1261.  
  1262. ==  for (i=0;i<strlen(s);i++) {
  1263. ==    if ((i==0) || ((i>0) && ((s[i-1]==' ') ||
  1264. ++        (s[i-1]=='-') ||                                          // SPV031
  1265. ==        (s[i-1]=='.')))) {
  1266. ─────────────────────────────────────────────────────────────────────────────
  1267. STEP 17: Make a file in your GFILES and call it QUOTE.MSG.  Mine looks like
  1268.     this, and yours should be similar!
  1269.  
  1270. QUOTE.MSG
  1271. ---------
  1272.  
  1273.     You are about to send a msg/e-mail with a quotation in it.  You should
  1274.     remove unnecessary lines, including taglines and signoff macros.  This
  1275.             helps reduce network LD costs.
  1276.  
  1277. ─────────────────────────────────────────────────────────────────────────────
  1278. STEP 18: Recompile this beast, and enjoy your new quoting!
  1279. ─────────────────────────────────────────────────────────────────────────────
  1280.   Well, this is a complete overhauled mod for 4.24.  I've installed it first
  1281. thing on my virgin 4.24 system 'cause this is the most installation intensive
  1282. mod I make.
  1283.  
  1284.   The word is, it works fine...
  1285.  
  1286.     This mod is copyright 1993-1995 by Tracy Baker, aka Papa Bear, and is
  1287.  distributed as freeware.  Permission is granted to distribute and post this
  1288.    mod on BBS systems and online services, provided no alterations are made
  1289.   (removal of message headers/taglines allowed).  This mod may contain some
  1290.   parts of WWIV source code, which is copyright 1988-1994 by Wayne Bell and
  1291.     licensed only to registered users of WWIV.  Use of WWIV source without
  1292.      registration constitutes a license violation and could lead to legal
  1293.             prosecution and certain doom.
  1294.    Shareware distributors and CD-ROM publishers may not distribute this mod
  1295.  without express written permission of the Author or WWIV Software Services.
  1296.  
  1297.  
  1298.                     -=■=-
  1299.  
  1300.