windows shared memory -- msdn document of the file mapping object

8 篇文章 0 订阅
1 篇文章 0 订阅

EXECUTE? Execute addresses within the shared memory?

  1. CreateFileMapping

    • PAGE_READONLY

      Allows views to be mapped for read-only or copy-on-write access. An attempt to write to a specific region results in an access violation.

    • PAGE_READWRITE

      Allows views to be mapped for read-only, copy-on-write, or read/write access.

    • PAGE_WRITECOPY

      Allows views to be mapped for read-only or copy-on-write access. This value is equivalent to PAGE_READONLY.

    • PAGE_EXECUTE_READ

    • PAGE_EXECUTE_READWRITE
    • PAGE_EXECUTE_WRITECOPY
  2. MapViewOfFile

    • FILE_MAP_ALL_ACCESS

      When used with the MapViewOfFile function, FILE_MAP_ALL_ACCESS is equivalent to FILE_MAP_WRITE.

    • FILE_MAP_WRITE

      A read/write view of the file is mapped. The file mapping object must have been created with PAGE_READWRITE or PAGE_EXECUTE_READWRITE protection.

      When used with MapViewOfFile, (FILE_MAP_WRITE | FILE_MAP_READ) and FILE_MAP_ALL_ACCESS are equivalent to FILE_MAP_WRITE.

    • FILE_MAP_READ

      A read-only view of the file is mapped. An attempt to write to the file view results in an access violation.

      The file mapping object must have been created with PAGE_READONLY, PAGE_READWRITE, PAGE_EXECUTE_READ, or PAGE_EXECUTE_READWRITE protection.

    • FILE_MAP_COPY

      A copy-on-write view of the file is mapped. The file mapping object must have been created with PAGE_READONLY, PAGE_READ_EXECUTE, PAGE_WRITECOPY, PAGE_EXECUTE_WRITECOPY, PAGE_READWRITE, or PAGE_EXECUTE_READWRITE protection.

      When a process writes to a copy-on-write page, the system copies the original page to a new page that is private to the process. The contents of the new page are never written back to the original file and are lost when the view is unmapped.

  3. OpenFileMapping
    This access is checked against any security descriptor on the target file mapping object. For a list of values, see File Mapping Security and Access Rights.

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值