[Mono-bugs] [Bug 350840] New: SecureString.Copy() does not work

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Thu Dec 27 14:56:51 EST 2007


https://bugzilla.novell.com/show_bug.cgi?id=350840


           Summary: SecureString.Copy() does not work
           Product: Mono: Class Libraries
           Version: 1.2.6
          Platform: Other
        OS/Version: Other
            Status: NEW
          Severity: Normal
          Priority: P5 - None
         Component: System.Security
        AssignedTo: spouliot at novell.com
        ReportedBy: vgiszpenc at dsci.com
         QAContact: mono-bugs at ximian.com
          Found By: ---


If it works, it does not copy over the length which means it does not work
quite right.

You should probably turn my WriteLines into an AssertEqual() call but I don't
use it so I don't know the exact syntax.

Thanks,

Vlad

using System;
using System.Security;

class MainClass
{
        public static void Main(string[] args)
        {
                SecureString ss = new SecureString();
                ss.AppendChar('a');
                Console.WriteLine("ss len {0}", ss.Length);
                SecureString ss2 = ss.Copy();
                Console.WriteLine("ss2 len {0}", ss2.Length); //This is zero
when it should be 1
        }
}


-- 
Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.


More information about the mono-bugs mailing list