[REBOL] Re: Evaluating a maths expression in a string?
From: mat:eurogamer at: 29-Dec-2000 19:17
Heya Larry,
>>> either not error? try[result: do str][result]["code to handle error"]
I've just realised the fatal flaw with this approach. Since I allow
user input to my evaluation string - there's nothing to stop them
typing out rebol code.
Security issue to say the least!
I suppose I could filter to make sure there are only characters that
fit a character set of "0123456789+-*/()" - that might do it?
--
Mat Bettinson - EuroGamer's Gaming Evangelist with a Goatee
http://www.eurogamer.net | http://www.eurogamer-network.com