[Mono-list] Bad PKCS7 padding. Invalid length when using asp.net membership provider - a bug in mono?
Piotr Walat
piotr.walat at gmail.com
Thu Aug 13 11:26:21 EDT 2009
Hello
i am using Nauckit Postgresql membership provider for asp.net
(http://dev.nauck-it.de/aspsqlprovider/) with passwordFormat set to
"Encrypted".
I used Membership.CreateUser(string,string,string) method to create a user
and it worked flawlessly... however everytime i try to login using
registered user's credentials i get an exception:
Bad PKCS7 padding. Invalid length {some_number}
Stack trace:
System.Security.Cryptography.CryptographicException: Bad PKCS7 padding.
Invalid length 176.
at Mono.Security.Cryptography.SymmetricTransform.ThrowBadPaddingException
(PaddingMode padding, Int32 length, Int32 position) [0x0005c] in
/var/tmp/portage/dev-lang/mono-2.4.2/work/mono-2.4.2/mcs/class/corlib/Mono.Security.Cryptography/SymmetricTransform.cs:363
at Mono.Security.Cryptography.SymmetricTransform.FinalDecrypt
(System.Byte[] inputBuffer, Int32 inputOffset, Int32 inputCount) [0x001a3]
in
/var/tmp/portage/dev-lang/mono-2.4.2/work/mono-2.4.2/mcs/class/corlib/Mono.Security.Cryptography/SymmetricTransform.cs:515
at Mono.Security.Cryptography.SymmetricTransform.TransformFinalBlock
(System.Byte[] inputBuffer, Int32 inputOffset, Int32 inputCount) [0x00034]
in
/var/tmp/portage/dev-lang/mono-2.4.2/work/mono-2.4.2/mcs/class/corlib/Mono.Security.Cryptography/SymmetricTransform.cs:554
at
System.Security.Cryptography.RijndaelManagedTransform.TransformFinalBlock
(System.Byte[] inputBuffer, Int32 inputOffset, Int32 inputCount) [0x00000]
in
/var/tmp/portage/dev-lang/mono-2.4.2/work/mono-2.4.2/mcs/class/corlib/System.Security.Cryptography/RijndaelManagedTransform.cs:94
at System.Web.Security.MembershipProvider.DecryptPassword (System.Byte[]
encodedPassword) [0x00017] in
/var/tmp/portage/dev-lang/mono-2.4.2/work/mono-2.4.2/mcs/class/System.Web/System.Web.Security/MembershipProvider.cs:123
at NauckIT.PostgreSQLProvider.PgMembershipProvider.UnEncodePassword
(System.String encodedPassword) [0x00025] in
/home/pw/projects/ptest/ASPNetProvider/src/NauckIT.PostgreSQLProvider/PgMembershipProvider.cs:1432
at NauckIT.PostgreSQLProvider.PgMembershipProvider.CheckPassword
(System.String password, System.String dbpassword) [0x0001e] in
/home/pw/projects/ptest/ASPNetProvider/src/NauckIT.PostgreSQLProvider/PgMembershipProvider.cs:1366
at NauckIT.PostgreSQLProvider.PgMembershipProvider.ValidateUser
(System.String username, System.String password) [0x00144] in
/home/pw/projects/ptest/ASPNetProvider/src/NauckIT.PostgreSQLProvider/PgMembershipProvider.cs:1241
at System.Web.UI.WebControls.Login.AuthenticateUser () [0x00087] in
/var/tmp/portage/dev-lang/mono-2.4.2/work/mono-2.4.2/mcs/class/System.Web/System.Web.UI.WebControls/Login.cs:1289
at System.Web.UI.WebControls.Login.OnBubbleEvent (System.Object source,
System.EventArgs e) [0x00023] in
/var/tmp/portage/dev-lang/mono-2.4.2/work/mono-2.4.2/mcs/class/System.Web/System.Web.UI.WebControls/Login.cs:1119
Version information: Mono Version: 2.0.50727.1433; ASP.NET Version:
2.0.50727.1433
Well is it likely to be a bug in mono or am I doing something wrong?
--
View this message in context: http://www.nabble.com/Bad-PKCS7-padding.-Invalid-length-when-using-asp.net-membership-provider---a-bug-in-mono--tp24955064p24955064.html
Sent from the Mono - General mailing list archive at Nabble.com.
More information about the Mono-list
mailing list