Plugin Security (Was Re: How do I create a SqueakPlugin.imagefrom a 2.9a ?)

Hans-Martin Mosner hm.mosner at cityweb.de
Sat Jan 27 14:03:36 UTC 2001


Luciano Notarfrancesco wrote:

> (If you can use something like this to write into the
> header of another object, you might be able to change
> the size of an object making posible to do at:put:'s
> beyond the object memory.)

Try to find out what the attached piece of obfuscated Squeak computes
:-)
Especially, what's the meaning of the result of: "H h: nil"?

Cheers,
Hans-Martin
-------------- next part --------------
'From Squeak2.9alpha of 13 June 2000 [latest update: #2710] on 27 January 2001 at 2:59:37 pm'!
Object subclass: #H
	instanceVariableNames: 'a '
	classVariableNames: ''
	poolDictionaries: ''
	category: 'Hacking'!

!H methodsFor: 'h' stamp: 'hmm 1/27/2001 14:55'!
h: g
	| h |
	self become: g.
	h := a.
	self become: g.
	^h! !

!H methodsFor: 'h' stamp: 'hmm 1/27/2001 14:56'!
h: g h: b
	self become: g.
	a := b.
	self become: g! !

"-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- "!

H class
	instanceVariableNames: ''!

!H class methodsFor: 'h' stamp: 'hmm 1/27/2001 14:58'!
h: x
	| h a b c d e |
	"H h: nil"
	h := self new.
	a := Object new.
	b := Bitmap new: 0.
	c := Array with: x.
	h h: a h: ((d := h h: a) bitOr: 4).
	e := b at: 2.
	h h: a h: d.
	^e! !


More information about the Squeak-dev mailing list