Code Access Security - Demands

Demands

Code that performs some privileged action will make a demand for one or more permissions. The demand makes the CLR walk the call stack and for each method the CLR will ensure that the demanded permissions are in the method's assembly's granted permissions. If the permission is not granted then a security exception is thrown. This prevents downloaded code from performing privileged actions. For example, if an assembly is downloaded from an untrusted site the assembly will not have any file IO permissions and so if this assembly attempts to access a file code access security will throw an exception preventing the call.

Read more about this topic:  Code Access Security

Famous quotes containing the word demands:

    The shift from the perception of the child as innocent to the perception of the child as competent has greatly increased the demands on contemporary children for maturity, for participating in competitive sports, for early academic achievement, and for protecting themselves against adults who might do them harm. While children might be able to cope with any one of those demands taken singly, taken together they often exceed children’s adaptive capacity.
    David Elkind (20th century)

    The distractions, the exhaustions, the savage noises, the demands of town life, are, for me, mortal enemies to thought, to sleep, and to study; its extremes of squalor and of splendor do not stimulate, but sadden me; certain phases of its society I profoundly value, but would sacrifice them to the heaven of country quiet, if I had to choose between.
    Elizabeth Stuart Phelps (1844–1911)

    The kind of man who demands that government enforce his ideas is always the kind whose ideas are idiotic.
    —H.L. (Henry Lewis)