Bug 316048 (MONO66117) - [PATCH] Runtime doesn't encode assembly-level security attributes in the metadata
Summary: [PATCH] Runtime doesn't encode assembly-level security attributes in the meta...
Status: RESOLVED FIXED
Alias: MONO66117
Product: Mono: Runtime
Classification: Mono
Component: misc (show other bugs)
Version: unspecified
Hardware: Other All
: P3 - Medium : Normal
Target Milestone: ---
Assignee: Mono Bugs
QA Contact: Mono Bugs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-09-16 21:51 UTC by Sebastien Pouliot
Modified: 2007-09-15 21:24 UTC (History)
0 users

See Also:
Found By: ---
Services Priority:
Business Priority:
Blocker: ---
Marketing QA Status: ---
IT Deployment: ---


Attachments
AssemblyBuilder.patch (3.03 KB, patch)
2004-09-16 21:54 UTC, Thomas Wiest
Details | Diff
bug66117.patch (2.32 KB, patch)
2004-09-16 22:02 UTC, Thomas Wiest
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Thomas Wiest 2007-09-15 18:54:03 UTC


---- Reported by sebastien@ximian.com 2004-09-16 14:51:33 MST ----

Description of Problem:
Runtime doesn't encode assembly-level security attributes in the metadata.


Steps to reproduce the problem:
1. Compile sample code decl_all.cs from https://bugzilla.novell.com/show_bug.cgi?id=MONO66035
http://bugzilla.ximian.com/showattachment.cgi?attach_id=10765

2. Disassemble using MS ildasm (or monodis with patches from #66035)


Actual Results:
No .permissionset reqmin|reqopt|reqrefuse are present in the IL.


Expected Results:
.assembly 'decl_all'
{
  .permissionset reqmin =  (
  3C 00 49 00 50 00 65 00 72 00 6D 00 69 00 73 00   // <.I.P.e.r.m.i.s.
  73 00 69 00 6F 00 6E 00 20 00 63 00 6C 00 61 00   // s.i.o.n. .c.l.a.
...
  .permissionset reqopt =  (
...
  .permissionset reqrefuse =  (
...
}
...


How often does this happen? 
Always


Additional Information:
(a) AssemblyBuilder doesn't provide the permissions in a "easily usable"
state (they are available in Assembly as PermissionSet).
(b) the runtime doesn't encode them.



---- Additional Comments From sebastien@ximian.com 2004-09-16 14:54:43 MST ----

Created an attachment (id=166797)
AssemblyBuilder.patch




---- Additional Comments From sebastien@ximian.com 2004-09-16 15:02:03 MST ----

Created an attachment
https://bugzilla.novell.com/show_bug.cgi?id=MONO66117.patch




---- Additional Comments From sebastien@ximian.com 2004-09-16 15:04:30 MST ----

Here are the patches to enable assembly-level security permissions.

Note: The patch also requires to bump corlib_version as it changes add
members that are shared between managed and unmanaged code.



---- Additional Comments From vargaz@gmail.com 2004-09-16 16:24:50 MST ----

This is ok to check in.



---- Additional Comments From sebastien@ximian.com 2004-09-16 19:21:00 MST ----

Commited.

Imported an attachment (id=166797)
Imported an attachment (id=166798)