extend pragma(msg) with writing to file

Andrey Zherikov andrey.zherikov at gmail.com
Sat Oct 8 13:28:54 UTC 2022


On Saturday, 8 October 2022 at 10:48:49 UTC, kdevel wrote:
> On Friday, 7 October 2022 at 16:22:22 UTC, Andrey Zherikov 
> wrote:
> [...]
>> We already have read compile-time access to a system by 
>> [`import("foo.txt")`](https://dlang.org/spec/expression.html#import_expressions).
>
> Quote: "Note that by default an import expression will not 
> compile unless one or more paths are passed via the -J switch. 
> This tells the compiler where it should look for the files to 
> import. This is a security feature."

Writing can be implemented the same way: it works only when a 
specific command line parameter is provided, or error out 
otherwise.

>> How does write access change the risk in principle?
>
> Nice try.

Tis is not an answer to the question how does writing make 
security risks higher comparing to existing reading.



More information about the Digitalmars-d mailing list