Click here to Skip to main content
15,915,093 members
Home / Discussions / C#
   

C#

 
GeneralRe: active directory users listing Pin
Heath Stewart22-Mar-04 3:54
protectorHeath Stewart22-Mar-04 3:54 
QuestionHow to: Registry Pin
bouli21-Mar-04 22:55
bouli21-Mar-04 22:55 
Generalunknown exception thrown when decrypting read-in message Pin
chau_fai_rubbish21-Mar-04 21:36
chau_fai_rubbish21-Mar-04 21:36 
GeneralRe: unknown exception thrown when decrypting read-in message Pin
chau_fai_rubbish22-Mar-04 2:34
chau_fai_rubbish22-Mar-04 2:34 
GeneralRe: unknown exception thrown when decrypting read-in message Pin
Heath Stewart22-Mar-04 3:17
protectorHeath Stewart22-Mar-04 3:17 
GeneralRe: unknown exception thrown when decrypting read-in message Pin
Heath Stewart22-Mar-04 3:23
protectorHeath Stewart22-Mar-04 3:23 
GeneralRe: unknown exception thrown when decrypting read-in message Pin
chau_fai_rubbish22-Mar-04 15:00
chau_fai_rubbish22-Mar-04 15:00 
GeneralRe: unknown exception thrown when decrypting read-in message Pin
Heath Stewart23-Mar-04 2:56
protectorHeath Stewart23-Mar-04 2:56 
You're still not telling me the actual exception Type, only the message.

In any case, try using a buffer that is a power of 2 (2, 4, 8, 16, 32, 64, ...) when decrypting. This is a pretty common requirement when decrypting so that the decryption algorithm has all that it needs to decrypt a block. This usually isn't the case when you don't have a block of the right size, which is almost always a power of 2.

Also, don't new-up a UnicodeEncoding object every time you use it. Use Encoding.Unicode which create a single instance to be used any time you use it, which saves time and memory:
byte[] buffer = Encoding.Unicode.GetBytes(someString);


 

Microsoft MVP, Visual C#
My Articles
GeneralRe: unknown exception thrown when decrypting read-in message Pin
terry_cyf23-Mar-04 20:40
terry_cyf23-Mar-04 20:40 
GeneralRe: unknown exception thrown when decrypting read-in message Pin
Heath Stewart24-Mar-04 2:46
protectorHeath Stewart24-Mar-04 2:46 
GeneralFormatting Strings Pin
Maharishi Bhatia21-Mar-04 18:35
Maharishi Bhatia21-Mar-04 18:35 
GeneralRe: Formatting Strings Pin
Heath Stewart21-Mar-04 18:56
protectorHeath Stewart21-Mar-04 18:56 
GeneralRe: Formatting Strings Pin
Spanky321-Mar-04 21:12
Spanky321-Mar-04 21:12 
GeneralRe: Formatting Strings Pin
Heath Stewart22-Mar-04 3:09
protectorHeath Stewart22-Mar-04 3:09 
GeneralRe: Formatting Strings Pin
Judah Gabriel Himango22-Mar-04 4:01
sponsorJudah Gabriel Himango22-Mar-04 4:01 
GeneralRe: Formatting Strings Pin
Heath Stewart22-Mar-04 4:11
protectorHeath Stewart22-Mar-04 4:11 
GeneralRe: Formatting Strings Pin
Alvaro Mendez22-Mar-04 10:08
Alvaro Mendez22-Mar-04 10:08 
GeneralRe: Formatting Strings Pin
Heath Stewart22-Mar-04 11:45
protectorHeath Stewart22-Mar-04 11:45 
GeneralRe: Formatting Strings Pin
Alvaro Mendez22-Mar-04 10:34
Alvaro Mendez22-Mar-04 10:34 
Generalclipboard Pin
cmarmr21-Mar-04 16:49
cmarmr21-Mar-04 16:49 
GeneralRe: clipboard Pin
Heath Stewart21-Mar-04 18:51
protectorHeath Stewart21-Mar-04 18:51 
GeneralRe: clipboard Pin
cmarmr22-Mar-04 9:45
cmarmr22-Mar-04 9:45 
GeneralRe: clipboard Pin
Heath Stewart22-Mar-04 9:52
protectorHeath Stewart22-Mar-04 9:52 
GeneralRe: clipboard Pin
cmarmr23-Mar-04 3:47
cmarmr23-Mar-04 3:47 
Generalanyone help me!! Pin
lcsnatoo21-Mar-04 16:05
lcsnatoo21-Mar-04 16:05 

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

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