[REBOL] Question on Secure (repost) Re:(2)

2000-05-17 Thread agem



do compose/deep[secure[(my-dir) allow]]

attention to the 'level in secure, this means, the compose is not evaluatet!
you have to hack a bit more :)

 source secure
secure: native [
{Specify security policies (access levels and directories). Return prior settings.} 
'level [word! block!] "Levels are: quit, throw, ask, and allow."
]

i suggest with default protection before:
do compose/deep[secure[net ask file ask (my-dir) allow]]

Volker

  But if I try using:
 
  downloaddir: %/d/anti%20virus%20downloads/
  == %/d/anti%20virus%20downloads/
 
   secure [downloaddir allow]
  ** Script Error: Invalid argument: downloaddir.
  ** Where: secure [downloaddir allow]
 
  it doesn't. Shouldn't either way work?
 
 'secure doesn't evaluate the block passed to it. Try using 'compose like
 this:
 secure compose [(downloaddir) allow]
 and see if that works better for you. Or you could do this:
 
 DirPermission: 'allow
 secure reduce [downloaddir DirPermission]
 
 'reduce-ing the block first.
 
 Andrew Martin
 Fully condensed...
 ICQ: 26227169
 http://members.xoom.com/AndrewMartin/
 --
 
 
 
 




[REBOL] Question on Secure (repost) Re:(3)

2000-05-17 Thread Al . Bri

Hi, Volker.
Call me idiot, but I didn't understand what you're trying to say here:

 do compose/deep[secure[(my-dir) allow]]

 attention to the 'level in secure, this means, the compose is not
evaluatet!
 you have to hack a bit more :)

  source secure
 secure: native [
 {Specify security policies (access levels and directories). Return prior
settings.}
 'level [word! block!] "Levels are: quit, throw, ask, and allow."
 ]

 I suggest with default protection before:
 do compose/deep[secure[net ask file ask (my-dir) allow]]

How is your solution better than:
DirPermission: 'allow
secure reduce [downloaddir DirPermission]
?

Andrew Martin
Who's been called an idiot today! :-( But I don't believe them... :-)
ICQ: 26227169
http://members.xoom.com/AndrewMartin/
--




[REBOL] Question on Secure (repost) Re:(4)

2000-05-17 Thread mdb

 Not sure what to say, Andrew. Don't take this personally but your solutions
didn't work whereas Volker's did.

Yours:

downloaddir: %/d/anti%20virus%20downloads/
== %/d/anti%20virus%20downloads/
 secure compose [(downloaddir) allow]
** Script Error: Invalid argument: compose.
** Where: secure compose [(downloaddir) allow]
 DirPermission: 'allow
== allow
 secure reduce [downloaddir DirPermission]
** Script Error: Invalid argument: reduce.
** Where: secure reduce [downloaddir DirPermission]

=
Volker's


 do compose/deep[secure[(downloaddir) allow]]
== [net allow file [allow read ask write ask execute]]
 do compose/deep[secure[(downloaddir) allow]]
== [net allow file [allow read ask write ask execute]
%/d/anti%20virus%20downloads allo
w]


Mike.
===
- Original Message -
From: [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Wednesday, May 17, 2000 2:29 AM
Subject: [REBOL] Question on Secure (repost) Re:(3)


 Hi, Volker.
 Call me idiot, but I didn't understand what you're trying to say here:

  do compose/deep[secure[(my-dir) allow]]
 
  attention to the 'level in secure, this means, the compose is not
 evaluatet!
  you have to hack a bit more :)
 
   source secure
  secure: native [
  {Specify security policies (access levels and directories). Return prior
 settings.}
  'level [word! block!] "Levels are: quit, throw, ask, and allow."
  ]
 
  I suggest with default protection before:
  do compose/deep[secure[net ask file ask (my-dir) allow]]

 How is your solution better than:
 DirPermission: 'allow
 secure reduce [downloaddir DirPermission]
 ?

 Andrew Martin
 Who's been called an idiot today! :-( But I don't believe them... :-)
 ICQ: 26227169
 http://members.xoom.com/AndrewMartin/
 --





[REBOL] Question on Secure (repost) Re:(5)

2000-05-17 Thread Al . Bri

Mike wrote:
 Not sure what to say, Andrew. Don't take this personally but your
solutions didn't work whereas Volker's did.

I won't take it tooo personally. I can call my self an idiot for not
checking it? :-)

'source doesn't evaluate it's argument. I didn't check for that. :-(

 source secure
secure: native [
{Specifies security policies (access levels and directories). Return
prior settings.}
'level [word! block!] "Levels are: quit, throw, ask, and allow."
]

Note the little tick { ' } by 'level.

I'm used to the arguments being evaluated.

Andrew Martin
Making new records in personal idiocy. :-D
ICQ: 26227169
http://members.xoom.com/AndrewMartin/
--




[REBOL] Question on Secure (repost)

2000-05-16 Thread mdb



Hello,I'm having a problem trying to change 
security settings with 'secure.If i change settings using the file name as 
in: secure [%/d/anti%20virus%20downloads/ allow]== [net 
allow file [allow read ask write ask execute]] secure 
[%/d/anti%20virus%20downloads/ allow]== [net allow file [allow read ask 
write ask execute]%/d/anti%20virus%20downloads allow]it works just 
fine. But if i try using:downloaddir: 
%/d/anti%20virus%20downloads/== 
%/d/anti%20virus%20downloads/ secure [downloaddir allow]** 
Script Error: Invalid argument: downloaddir.** Where: secure [downloaddir 
allow]it doesn't. Shouldn't either way 
work?Thanks.Mike.


[REBOL] Question on Secure (repost) Re:

2000-05-16 Thread Al . Bri

 But if I try using:

 downloaddir: %/d/anti%20virus%20downloads/
 == %/d/anti%20virus%20downloads/

  secure [downloaddir allow]
 ** Script Error: Invalid argument: downloaddir.
 ** Where: secure [downloaddir allow]

 it doesn't. Shouldn't either way work?

'secure doesn't evaluate the block passed to it. Try using 'compose like
this:
secure compose [(downloaddir) allow]
and see if that works better for you. Or you could do this:

DirPermission: 'allow
secure reduce [downloaddir DirPermission]

'reduce-ing the block first.

Andrew Martin
Fully condensed...
ICQ: 26227169
http://members.xoom.com/AndrewMartin/
--