locked
Login information entered is not correct RRS feed

  • Question

  • I have a problem deploying a web application using Forms Authentication on VSLS 2012 Professional. Iit is a project Migrated from VSLS 2010

    The publishing wizard does not update the security tables of the DB with the admin user, instead it publish the user in plain text into the web.config file.

    On Beth Massi's blog she said: "Once your application runs for the first time and the System Administrator is added, you can remove these settings to avoid storing the password in your web.config indefinitely." (Read here)

    But I cant run the aplication due the fact that I cant Login into the applicattion.

    Can anyone help me please?

    Best regards,

    Gabriel

    Thursday, May 2, 2013 2:49 PM

Answers

  • Hi Gabriel,

    Sorry you're having trouble. Did you previously publish the 2010 version of the database or is this the first time you are trying to publish? Also did you make sure you checked "Publish Schema" in the publish wizard?

    Thanks,

    -Beth


    Senior Program Manager, Visual Studio Community http://www.bethmassi.com http://msdn.com/lightswitch http://dev.office.com

    Thursday, May 2, 2013 4:59 PM
  • Hi Gabriel,

    The rows in the database aren't populated until you attempt to access the app for the first time.  It populates those rows based on the settings that exist in the web.config file.  Just to be sure, you need to make sure you login using the administrator credentials you specified when publishing.  If you're not seeing the rows in the security tables being populated after you've accessed the application, there may be a problem communicating with the database.  To determine if this is the case, follow the instructions for enabling tracing here: http://blogs.msdn.com/b/lightswitch/archive/2011/09/20/diagnosing-problems-in-a-deployed-lightswitch-application-eric-erhardt.aspx. Look at the trace log and see if that indicates an error.

    Thursday, May 2, 2013 8:42 PM
  • I found it. I found my mistake.

    What Beth said was wright (of course). But the issue with me is that I replace the default login screen with an ASPX screen, so instead of download the XAP file the first time (and create the admin user) my app just wait for the first login (thing that would never happen) to start downloading the XAP.

    So, I have to replace the login form with the default (for now) and see if it works.

    Thanks for everything.

    Regards, 

    Gabriel

    Friday, May 3, 2013 3:56 PM

All replies

  • Hi Gabriel,

    Sorry you're having trouble. Did you previously publish the 2010 version of the database or is this the first time you are trying to publish? Also did you make sure you checked "Publish Schema" in the publish wizard?

    Thanks,

    -Beth


    Senior Program Manager, Visual Studio Community http://www.bethmassi.com http://msdn.com/lightswitch http://dev.office.com

    Thursday, May 2, 2013 4:59 PM
  • Hi Beth, 

    Its a first time publish, The database is created correctly and also the security tables, but they are complety empty.

    I'd checked the option "Publis Schema".

    The admin user is only published in plain text on the web.config file.

    Thank you

    Gabriel

    P.S.: Im a big fan of your work

    Thursday, May 2, 2013 5:27 PM
  • Hi Gabriel,

    The rows in the database aren't populated until you attempt to access the app for the first time.  It populates those rows based on the settings that exist in the web.config file.  Just to be sure, you need to make sure you login using the administrator credentials you specified when publishing.  If you're not seeing the rows in the security tables being populated after you've accessed the application, there may be a problem communicating with the database.  To determine if this is the case, follow the instructions for enabling tracing here: http://blogs.msdn.com/b/lightswitch/archive/2011/09/20/diagnosing-problems-in-a-deployed-lightswitch-application-eric-erhardt.aspx. Look at the trace log and see if that indicates an error.

    Thursday, May 2, 2013 8:42 PM
  • Matt, 

    Thanks for your answer i will read he post and check agains my configuration. I'll let you know.

    Thank you!

    Regards, 

    Gabriel

    Thursday, May 2, 2013 10:07 PM
  • Hello, 

    So, I'd enable the trace log and it didn't show anything wrong.

    I must say, that the first that I see in my application is the login screen (aspx), thats when i want to enter the admin user and pass.

    Also the IIS have specified the admin user and pass in the Application Settings section.

    Is there any way to override this behaviour and publish the app like before?

    Regards,

    Gabriel 


    Friday, May 3, 2013 2:12 PM
  • I found it. I found my mistake.

    What Beth said was wright (of course). But the issue with me is that I replace the default login screen with an ASPX screen, so instead of download the XAP file the first time (and create the admin user) my app just wait for the first login (thing that would never happen) to start downloading the XAP.

    So, I have to replace the login form with the default (for now) and see if it works.

    Thanks for everything.

    Regards, 

    Gabriel

    Friday, May 3, 2013 3:56 PM