Click here to Skip to main content
   

C#

 
AnswerRe: how can I Pass a value from one page to another dont want to use session querystring class public members and static class in webapplication PinmentorKeith Barrow7-Jan-13 3:19 
AnswerRe: how can I Pass a value from one page to another dont want to use session querystring class public members and static class in webapplication Pinmembersachin_nagane7-Jan-13 5:35 
AnswerRe: how can I Pass a value from one page to another dont want to use session querystring class public members and static class in webapplication PinmemberBobJanova7-Jan-13 6:30 
AnswerRe: how can I Pass a value from one page to another dont want to use session querystring class public members and static class in webapplication PinmvpRahul Rajat Singh7-Jan-13 22:12 
QuestionHow to print pictures in crystal reports Pinmembersaudahmed7-Jan-13 0:50 
QuestionCREATION tree usage recursive functions Pinmemberfatima...686-Jan-13 23:25 
AnswerRe: CREATION tree usage recursive functions Pinmemberjibesh6-Jan-13 23:33 
GeneralRe: CREATION tree usage recursive functions Pinmemberfatima...686-Jan-13 23:40 
GeneralRe: CREATION tree usage recursive functions Pinmemberjibesh6-Jan-13 23:44 
AnswerRe: CREATION tree usage recursive functions PinmvpRichard MacCutchan7-Jan-13 0:13 
NewsRLE encoding/decoding tool C# PinmemberOleg Orlov6-Jan-13 17:15 
GeneralRe: RLE encoding/decoding tool C# PinmvpRichard MacCutchan6-Jan-13 23:18 
GeneralRe: RLE encoding/decoding tool C# PinmemberOleg Orlov7-Jan-13 0:40 
QuestionEncrypting XML **elements** PinmemberSledgeHammer016-Jan-13 11:15 
I have a requirement to serialize out an object to XML where certain elements are encrypted for privacy / security reasons.
 
I've seen some samples on the internet for doing this, but they are all hardcoded. I.e. after the object is serialized you "patch" the elements you want to encrypt with the encrypted version. Not liking the hardcoded aspect of this solution. Also having to hardcode the decryption parts.
 
I've seen another solution where you use the XmlIgnore attribute on the plain text property and then add an "encrypted" version of the property and use the XML attributes to rename it. Not liking that you need 2 versions of every "secure" property.
 
Are there any other options? Ideally I would like something "in the spirit of .NET" along the lines of:
 
public class SomeObject
{
      [XMLEncrypt]
      public string SomeProp { get; set; }
 
      public int SomeIntProp { get; set; }
}
 
where its something ".NETy" like a custom attribute or something like that. Unfortunately, I don't really see any way to hook into the XML serializer without completely re-writing it.
 
I thought about deriving a class from XMLSerializer and providing my own Serialize function that calls the base class and then afterwards goes through the object graph via reflection and patches the elements marked with the XMLEncrypt attribute, but I'm not really liking that idea that much either.
 
Any other suggestions?
AnswerRe: Encrypting XML **elements** PinmemberZac Greve6-Jan-13 15:12 
GeneralRe: Encrypting XML **elements** PinmemberSledgeHammer017-Jan-13 7:32 
AnswerRe: Encrypting XML **elements** PinmemberBobJanova7-Jan-13 6:31 
GeneralRe: Encrypting XML **elements** PinmemberSledgeHammer017-Jan-13 7:34 
AnswerRe: Encrypting XML **elements** PinmemberMustafa Kok9-Jan-13 0:46 
QuestionDelete specific matching rows in datatable PinmemberMember 97041536-Jan-13 9:20 
AnswerRe: Delete specific matching rows in datatable PinmvpMika Wendelius6-Jan-13 9:30 
GeneralRe: Delete specific matching rows in datatable PinmemberMember 97041536-Jan-13 10:36 
GeneralRe: Delete specific matching rows in datatable [modified] PinmvpMika Wendelius6-Jan-13 10:58 
GeneralRe: Delete specific matching rows in datatable PinmemberMember 97041536-Jan-13 11:13 
GeneralRe: Delete specific matching rows in datatable PinmvpMika Wendelius6-Jan-13 11:17 
GeneralRe: Delete specific matching rows in datatable PinmemberMember 97041536-Jan-13 11:26 
GeneralRe: Delete specific matching rows in datatable PinmvpMika Wendelius6-Jan-13 12:20 
GeneralRe: Delete specific matching rows in datatable PinmemberMember 97041536-Jan-13 12:45 
GeneralRe: Delete specific matching rows in datatable PinmvpMika Wendelius6-Jan-13 13:06 
QuestionRow level security with View (SQL) and how to model in Entity Frame work Pinmembersarshogh_eng@yahoo.com6-Jan-13 7:56 
QuestionApplication for a dedicated PC, uncloseable PinmemberZaid Pirwani5-Jan-13 11:28 
AnswerRe: Application for a dedicated PC, uncloseable PinmemberEddy Vluggen5-Jan-13 11:57 
GeneralRe: Application for a dedicated PC, uncloseable PinmemberZaid Pirwani5-Jan-13 19:53 
GeneralRe: Application for a dedicated PC, uncloseable PinmemberEddy Vluggen6-Jan-13 2:22 
AnswerRe: Application for a dedicated PC, uncloseable Pinmemberjschell6-Jan-13 6:06 
Questionproblem in opening word file with c# Pinmembera.ergin5-Jan-13 3:09 
AnswerRe: problem in opening word file with c# PinmvpSandeep Mewara5-Jan-13 7:03 
GeneralRe: problem in opening word file with c# Pinmembera.ergin5-Jan-13 12:57 
AnswerRe: problem in opening word file with c# PinmvpSandeep Mewara5-Jan-13 20:09 
GeneralRe: problem in opening word file with c# Pinmembera.ergin6-Jan-13 0:52 
Questionhow to set folder location of showsaveasdialog in webbrowser control Pinmembernitin_ion5-Jan-13 2:15 
QuestionDevelop Expense Management Tool in C# using ASP.Net PingroupTushar Urade5-Jan-13 0:59 
AnswerRe: Develop Expense Management Tool in C# using ASP.Net PinmvpRichard MacCutchan5-Jan-13 2:33 
AnswerRe: Develop Expense Management Tool in C# using ASP.Net PinmvpOriginalGriff5-Jan-13 22:21 
AnswerRe: Develop Expense Management Tool in C# using ASP.Net PinmvpAbhinav S6-Jan-13 1:04 
QuestionAsk about obfuscating assembly files before creating setup package ? Pinmembertaibc4-Jan-13 20:37 
QuestionCange datagridview cel backcolor if cel has value PinmemberGrooverFromHolland4-Jan-13 10:27 
AnswerRe: Cange datagridview cel backcolor if cel has value PinmvpMika Wendelius4-Jan-13 11:57 
GeneralRe: Cange datagridview cel backcolor if cel has value PinmemberGrooverFromHolland4-Jan-13 12:05 
AnswerRe: Cange datagridview cel backcolor if cel has value PinmemberAlan N4-Jan-13 16:09 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.


Advertise | Privacy | Mobile
Web03 | 2.8.150305.1 | Last Updated 6 Mar 2015
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid