OSQA: lost access to web-site due to changing allowed IP (admin's maintenance-mode) - osqa

I am the admin of a OSQA system (which is cool and great, by the way).
I tried to learn and understand the "maintenance mode", in order to create backups. So I have entered the "maintenance mode", and there I saw the text box with the message that my users will see when the site is under maintenance mode. Plus, there was a list of IPs that will be allowed to access the site even if it is under maintenance mode.
My IP was there...
My mistake was that I changed the IP in that text box, in order to see what my users will see. Immediately, I lost access the web site, and all I can see is the message, as the rest of my users... (at least now I know that it works - users cannot access the site, and they DO see the message...)
How can I regain access to my web site?
thanks!

do you have acces to the server where your site is hosted?
if so you just need to enter in django shell: python manage.py shell
then run the following code:
from forum import settings
settings.MAINTAINANCE_MODE.set_value(None)
exit()
With that the maintainance mode will be disable and you will be able to modify the allowed IP's.
~Mike

Related

How can i resolve django fraudulente site in chrome?

In fact i have a django web app that i host in continous deployment. When i try to open this app in chrome i have a warning red page which notice that the site is fraudulent and in addition i have to enabled the chrome advance protection to be protect of malicious site. In the show more button i can access the site by clicking on open the insecure site. Trying to open the site in edge browser i didn't see any kind of warning and the site open successfully. By this point i think that it's something relative to the security settings of chrome.
bellow is the error:
*fraudulent website
Attackers at xxxxxxxxxxx might trick you into doing something dangerous, like installing software or revealing your personal information (for example, passwords, phone numbers, or credit cards). know more
To use Chrome's highest level of security, enable enhanced protection
Recently, Google's "Safe Browsing" feature detected phishing from bluecamp.azurewebsites.net. Phishing sites pretend to be other sites to trick you.
*
You can report a detection issue or, if you understand the risks to your security, access this unsafe site.
Then i navigate to the security settings of chrome and disabled the protection settings to without security and by this point the site log without the previous error. The issue is i have to deploy the site and no matter the browser, the site should open without any kind of error. I was also thinking that it's something relative to my django apps secret key and i generate another using the django apps secret key generator but no change.Any kind of hand to solve this problem will be thankfull.

Sitecore content editor redirects to Page not foud

Due to some publishing issues i corrupted my local enviroment. Luckily i had backup which i restored and my local site was functioning well but, when i login to sitecore and choose any option from main page like Content Editor or Desktop it redirects to page not found.
I've tried to disable exceptions which redirect to page but they were of no use. And no logs are being created. Should i replace the entire wwwroot folder but, my wwwroot backup is 2 months old.
Or should i start from scratch and create a new sitecore site for same solution. I've compared my web.config,connection strings files they don't seem o have any problem.
Suggest what to do.
You are able to login but seems due to some permission issue you are not able to Content Editor/Desktop. Check permission on folders like identityserver(used for login)/your website(content editor and other CMS work), to start with you can try to give permission to your IIS User/Everyone (as shown in image), once it starts working you can be selective and change permission as per your need
enter image description here

Django openid authentication issue when I changed the url domain of my site but kept the same database

I should first note that I am a newbie in python/django applications but I am trying hard to learn :)
I am working/experimenting on a django project that supports login through openid providers. So I was able to login through my google account with no problems.
Recently, I decided to change the url of my site but at the same time I kept the current database because I dont want to lose my data,users etc. After that point, I am not able to login to the application. This is the following scenario that happens all the time:
Try to login to my site
Site doesn't remember me and I am redirected to google server
I fill my credentials in google server
I am redirected to my site that complains that the user already exists
So, I don't know how to manage with this problem. Is there any workaround or a hack that I can do to my database that will solve this problem? When I browse to my database I find several tables that may be related:
django_authopenid_association, django_authopenid_nonce, django_authopenid_userassociation,django_authopenid_userpasswordqueu
One of the tables in my database (django_authopenid_association) contains the following data. Do you believe that If I reset anything there is going to help?
If you have any good advices/tips are more than welcome.
Thanx
I found a solution/temp hack that worked for me. Of course, this doesn't imply that my solution is the optimal nor that I recommend this to anyone else.
What I did is to create a second account to my application using the same gmail account but having different user name. Then, I edit the new entry in the django_authopenid_association table, copy paste the openid_url value and use it for my old user (database entry 1 in the screenshot of my question).
After that, since I was able to login with my old user, I delete from the database the new user and everything seems to work smoothly until now.

Creating Firewall rule for a process running in a Non-admin user account

I have a basic requirement - to run my application smoothly on Windows by creating firewall rules when prompted, that has windows firewall turned-ON.
When I log in to my system as an user with Admin privileges when I run my application the first time, the firewall comes up with a prompt, I inform it to allow my app and create a rule, nice.
However when I turn-on my PC, log in as a non-Admin user, and I run my application, the firewall shows up with a prompt as expected; however when I click on the same options as I did from the Admin user, the firewall prompt keeps popping up continuously even though I clicked on Allow /ok every time the prompt appears. The prompt only goes away when I click on "Cancel / Block" the application from running, which is obviously not what I want to do.
So here comes the million $ question, What and How should I change my application code to run smoothly by creating the firewall rule successfully the first time I click on the firewall prompt to allow my application; exactly the same way it is working when I run my application as an user with Admin privileges.
I have done my bit of searching online and have come to understand that Non-admin users cannot modify firewall rules (cannot even create them???). BTW I have tested this scenario on Windows XP, Vista 7 both x86 and x64 with same results.
If someone has encountered and / or solved similar issues please share your knowledge. If I am missing something, please make me understand what I am missing.
Thanks
I don't think what you are trying is possible in a non-admin account. What you may try is to gain admin privilege by using the windows runas feature by creating a new process, so that the user is prompted for the username and password of the Admin Account, which would give your program the required access to create firewall rules for your program.
You may also take a look into CreateProcessAsUser or LogOnUSer . Basically in order to succeed in what you are trying to do, you need a token that represents the Administrator account or an account which has admin privileges.

web services access not being reached thru the browser

I am trying to reference my .asmx webservices in .NET but my server is not exposed to the internet. When I put on the following address I get the message mentioned below. What's the reason for not being able to see the directory? Am I missing something in my IIS configuraction? Am I missing anything in my permissions? Just as reference I have other folders with webservices and I have the same issue.
When I login to the server I am doing it with my windows user and password (I am using windows authentication). It's necessary to mention that when I put the URL I am getting a popup screen to put in my userid and password but it seems that's not able to validate since keeps asking me a couple of times. Let me know if you need more information to address this issue .
http://appsvr02/Inetpub/wwwroot/DevWebApi/
Internet Explorer cannot display the webpage
What you can try:
It appears you are connected to the Internet, but you might want to try to reconnect to the Internet.
Retype the address.
Go back to the previous page.
Most likely causes:
•You are not connected to the Internet.
•The website is encountering problems.
•There might be a typing error in the address.
More information
This problem can be caused by a variety of issues, including:
•Internet connectivity has been lost.
•The website is temporarily unavailable.
•The Domain Name Server (DNS) is not reachable.
•The Domain Name Server (DNS) does not have a listing for the website's domain.
•If this is an HTTPS (secure) address, click tools, click Internet Options, click Advanced, and check to be sure the SSL and TLS protocols are enabled under the security section.
For offline users
You can still view subscribed feeds and some recently viewed webpages.
To view subscribed feeds
1.Click the Favorites Center button , click Feeds, and then click the feed you want to view.
To view recently visited webpages (might not work on all pages)
1.Click Tools , and then click Work Offline.
2.Click the Favorites Center button , click History, and then click the page you want to view.
Try http://appsvr02/DevWebApi.
You shouldn't need to specify the full path, as IIS serves from wwwroot by default.
I don't know what I did but I was able to see it this time. thank youa all for your input. This is how the path to my server shows now. http://appsvr02/DevWeApi/Owner.asmx