Codeigniter tank auth - codeigniter

I am wondering if someone can help me, I have recently moved my site live to test it so I basically copied the database and uploaded the files. This means that I had already set up a user account on my local server. However, I have found the login to be a bit temperamental, when I went to login it wouldn’t accept it so I had to reset my password which it then worked fine. Then I decided to register another user and that worked fine however I went to log in the next day and it wouldn’t let me, even though I know that the details were correct…
Has anyone else experienced something similar? Also, if you have, how did you fix it?
Thanks

One thing to remember with Tank Auth is that the password hashes are localized to a single server, and will not work on any other. You can change that inside the tank_auth config file by changing phpass_hash_portable to true, but this is less safe. My recommendation is to just recreate the accounts.
That is the only problem I can think of in your situation, hope if fixes it.

Related

Joomla 2.5 website lost all the changes I did

Suddenly all the changes I've done on a joomla(2.5) site has been lost. reseted to the original state. How can this be anyone?
How this can be, is a mistery to all of us (without the log files). How this can be undone, however, is a question worth answering.
One way is to set back your database back-up. That is, obviously, if you have made one.
Another way is to set back any export you would've made that holds the data you are now missing. That is, obviously... you get the point.
If there is no way you have secured your data, it is probably gone. You could contact your server administrator to see if he has any backup data, but other then that your data is gone.

CakePHP Completely Random 403 AJAX Errors

I using CakePHP with Backbone.JS, I set up a controller just to give me a JSON output for getting my data, e.g. client names etc, to pass into each Backbone model.
This was all working, or appeared to be, however, it seems that it now gives me some random 403 errors when the page / from is saved or reloaded. But I have no idea why? If it can access it to start with, and does, then why would it not have access after a save or reload?
I have tried, $this->Auth->allow and it dose appear to fix the problem but this data is or could be important and need it not to be access my everybody who might guest at my access path.
Now I have read a number of articles on her, most point to read/write access on the files your accessing, but in my case its just a path /XXXX/XXXXX/myjson/clients For example.
Now I can post my code, if needed, but I am not sure what the problem is, is this a CakePHP issue or is Backbone not requesting the data right?
Please be aware that I am dyslexic, please be kind about my question, if I have not explained myself right. Then please be me some time to re-word / edit my post.
Thanks,
For any one else looking at this, I had added autoRegenerate to the Configure Write Session. For some reason it looks like CakePHP was taking to long to regenerate a new cookie and request my information at the same time.

CodeIgniter not storing sessions in IE

I am using version 2.1.3 of CodeIgniter, and primarily use Chrome or FireFox, but I am learning that some of my clients are having issues with my systems not allowing them to log in. The system log indicates that the user has logged in, but I check if the session variable is set to determine whether the control panel or login screen needs to be displayed.
For some reason, the session variables are not set in at least IE8 and below, so the login screen keeps showing, even though the log says the user is logged in.
I checked this: CodeIgniter IE not storing sessions correctly and this is not applicable to me.
I am not using Ajax for this, so this is not it either: PHP Session lost in CodeIgniter IE only
Also, this is not loaded in an iFrame. So, I doubt there are P3P problems: CodeIgniter 2.x sessions and Internet Explorer
What could be the cause of this?
Thanks!
I could just guess, hope its helpful.
Check your php files if you have a closing tag ?> and if you have a whitespace after it. This cause to return a blank response, because of the whitespace, and this breaks the session and cookies.
Do you have some mechanism for regenerating session id`s
Thats all i can come up with, hope i`ve helped.
Regards
I found this article, and it appears to solve the problem for me, but I want to test more before accepting my own answer.
http://ellislab.com/forums/viewthread/211955/#982986
Hope this helps someone else.
Regards,
Kobus

Issues Logging in Twice After Installing Lightspeed Module

We are having an issue with logging in a second time on our site ever since we installed the lightspeed module. At first I thought this might have to do with the need for hole punching, but now I'm not sure.
If you try to log into our website the first time, it works well. However, if you log in a second time, it won't work. It just remains on the customer/account/login page with no effect.
I tried to test this on my end, and echoed the user's email in the loginPost function in the account controller. When echoing directly from the controller, it was obvious that the user was being logged in, but upon the redirect to a page on the site, the user was no longer logged in and appeared as a Guest in the Magento backend (where you view online customers).
It appears to me as if the session is being lost after the redirect. I am not sure if this has anything to do with a switch between https and http as described in the stackoverflow problem here (http://stackoverflow.com/questions/7823994/magento-session-lost-when-switching-to-https-from-http ) where they had also installed lightspeed. The person there resolved the problem, but did not post the solution. Their problem wasn't the same as ours, but I was thinking there may be a connection between the two.
Has anyone seen a problem like this before?
Thanks in advance,
Brenda

Sessions across all subdomains

I am hoping some of you might have some answers here. I've been at this for many hours and I'm not making much headway. From doing an extensive amount of research, I see this is a common problem without many solutions.
I have my login at domain.com that then goes to the user profile at domain.com/profile?u=username that has been rewritten with .htaccess to username.domain.com. I need to have access to SESSION username across all subdomains so I can see if the user is on their own profile or not. I have tried all the basic solutions to get SESSIONS working across all subdomains with .htaccess etc (I do not have direct access to php.ini), but nothing seemed to work; with the exception of session_set_cookie_params(0, '/', '.domain.com'); at the top of the script setting the SESSION. This all of a sudden worked - but the problem is - it also all of a sudden stopped working and has intermittently continued to work and not work without me touching the code.
My questions here are...
Does anyone have any idea why this would be intermittently working and then not working?
Does anyone have any other simple, cross platform solutions to solve this problem.
Failing that, I believe I can store the SESSION in the database and recreate it in all the subdomains. This seems inefficient, but might be the only solution. What are your thoughts and what would be the best way to do this?
I would really appreciate any help in this. This has proven a real challenge.
I was able to fix this by simply adding a text file to my main directory called php.ini with session.cookie_domain = ".domain.com" inside. That was it. And you have to re-launch your browser.

Resources