Ask a Question related to ASP.NET General, Design and Development.

  1. #1

    Default Page Filter in C#

    Your opinion is appreciated.

    I am thinking about building a role-based security module for my web
    based application. Here is what I have in mind:

    1. Build a page filter class which enherits from IHttpModule and
    overide the Stream.Write() method....to basically remove the
    restricted html elements based on the user's role before the html
    comes back to the browser. Any defects in this design or do you see
    any other better approaches ?

    Thanks
    Andy Le Guest

  2. Similar Questions and Discussions

    1. #40499 [NEW]: filter sapi does not register any highlightning filter
      From: php at henke37 dot cjb dot net Operating system: any PHP version: 6CVS-2007-02-15 (CVS) PHP Bug Type: Apache2 related...
    2. Data Grid Header Filter Renderer or how do I get aheader to filter the data in a datagrid.
      Okay so on the same theme as why isn't the datagrid like Excel, I have created a (very cool) Filter header. 1) The filter looks like any other...
    3. checkbox-driven page-content filter
      I'd like to provide a client-side function to give the user the abiliity to filter a results set, after a search. As an example, a user searches for...
    4. Fog Filter
      Is it possible to add fog to a picture? I am using PS Elements 2. Thanks Arnold
    5. Best way to filter?
      Lets say we have two tables (1) VIPCustomers and (2) Invoices with the usual data. I have the following valid statement: SELECT A.* FROM...
  3. #2

    Default Page Filter in C#

    Hi,

    You have mentioned you are implementing role based
    security. Roles are often responsible for working with
    certain business entities that could be displayed in
    UserControl (for caching, UI process, etc.).

    So another possible approach in such case could be to
    develop some attribute and apply it to class inherited
    from UserControl, which would simply handle the display
    according the attribute parameters such as groups, users
    and display mode (hide or disable controls).
    The benefits in this case:
    - Easy to create;
    - Simple attribute based programming later;
    - All the benefits from the UserControl;
    - And one more - the ViewState will have everything as it
    should have. Just by removing HTML elements you'll have to
    be carefull about this;
    Drawbacks:
    - Not sure, but probably streams could be a bit faster;

    Romualdas

    >-----Original Message-----
    >Your opinion is appreciated.
    >
    >I am thinking about building a role-based security module
    for my web based application. any other better
    approaches ?
    >
    >Thanks.
    Romualdas Guest

  4. #3

    Default Page Filter in C#

    Just thought,

    maybe dynamically loading different UserControls could be
    enough (see IBuySpy portal)?

    Romualdas
    Romualdas Guest

  5. #4

    Default Page Filter in C#

    another idea,

    maybe it would be sufficient to load user controls
    dynamically (like in IBuySpy)?

    Romualdas
    romualdas Guest

Posting Permissions

  • You may not post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139