Quantcast
Channel: Moodle for mobile
Viewing all articles
Browse latest Browse all 8344

Re: Moodle in English: Re: cannot connect via moodle mobile to one of our sites

$
0
0
by David Richert.  

Yes, we got the same message when using bad credentials which is very perplexing.  We have tried using a Cellular data connection outside of our network and when using valid credentials, get the "Cannot Connect:  Verify that you have typed correctly the URL and that your site uses Moodle 2.4 or later".  When I change the password to an invalid password for the same test user, I get "the username was not found in the database" error same as you.  This behavior is the same from outside our network as it is inside.  Plus, we have 3 other sites that work perfectly so I don't believe it is our network. 

As you note, it is making some kind of connection in order to see that the username/password is valid or not so why would it present the other connection error with valid credentials.  As an additional test, we created a manual account on the server and attempted to log in within our network, and outside with the exact same results, the "Cannot Connect" error, just like we get when trying to connect with a valid LDAP user. 

When I run the /login/token.php page passing in the credentials for the manual account I created, I got the following response from the browser:

<hr>
(mysql): SELECT  *
                  FROM enrollments
                 WHERE USERNAME = 'mobile.test'&nbsp;<hr>
{"token":"3bfc04c5ee6d7f1a5d04e63731a54c4d"}

When I do the same with a valid user on one of our other sites I just get a token.

{"token":"d7e2a4dc97b4477c0e2eaced3344e6ba"}

I'm guessing the app is just expecting the token to be returned and that might be why we are getting the connect error message. 

Any ideas where we might go from here to check why our site is returning the MySQL select statement instead of just the token?

By the way, thank you for trying to help us figure this out.


Dave Richert


Viewing all articles
Browse latest Browse all 8344

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>