Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

we are having some issues with an external developer. i am not a wp person so i turn to the masses to help out. we want to limit access to the wp-admin site to internal access only (via vpn). simply so it will not be attacked by external people. we can enumerate the admins from the site and do not want them to be phished.

the developer is saying we cant do that because the site needs to have the admin page accessible externally so the page will function. specifically the admin-ajax page.

what does the admin-ajax.php page do?

it is located in the admin section of wp.. is it accessed unauthenticated by end users? is it an unsafe practice to have this available to external users?

share|improve this question
    
ajax-admin.php handles.. ajax requests. Please clear your title up and the question in general, wordpress.stackexchange.com/faq –  Wyck Dec 27 '12 at 15:49
add comment

3 Answers

admin-ajax.php is part of the WordPress AJAX API, and yes, it does handle requests from both backend and front. Try not to worry about the fact that it is in wp-admin. I think that is a strange place for it too, but it is not a security problem in itself. How this relates to "enumerate the admins", I don't know.

share|improve this answer
    
would you recommend moving the wp admin page from being externally available? and do you know if doing so would disrupt anything with the ajax admin? –  nick Dec 27 '12 at 16:38
    
I am not 100% sure what this means but if you require that access to files in wp-admin be from your VPN's IP, then yes that should mess up AJAX. AJAX calls are from the user's browser so come from the user's IP. –  s_ha_dum Dec 27 '12 at 16:52
add comment

If you want to limit access to the WP backend ( ie wp-admin ) just use an .htaccess rule on the wp-admin directory. Try : http://davidwalsh.name/password-protect-directory-using-htaccess for a general overview and http://wordpress.org/support/topic/password-protecting-wp-admin for your specific case.

share|improve this answer
    
Or if you'd rather do it by IP : betterwp.net/wordpress-tips/protect-wordpress-wp-admin-folder –  Juicki Dec 27 '12 at 18:39
add comment

My personal opinion is that this is a god awful idea. About two months ago our director of development insisted we do just this, much against the advice of the Dev team. It's a genuine nightmare and an incredible pain for us, not only does it kill ajax all together it presents so many administration issues for us.

We have 40 regular staff and 4 devs trying to use the vpn at times and it just stutters, along with that all users now require two sets of passwords one for wp and one for vpn and that's not just a shared password it's individual ones, I mean how else would you do a security audit. It's hard enough to remember one secure password, let alone two.

Add to the issue that a lot of people do not know how to use a vpn and often that just causes more issues.

Ultimately it's a terrible idea and it's often put forward by management or higher who do not know or understand WordPress. They see it in a terrible light, that because it's open source it must also be a security issue, filled with easily tapped exploits and so on.... its getting old.

WordPress is secure and sticking wp-admin behind a vpn is not only fear mongering it presents a nightmare for every member of the team

Why is it that management types have no trust when it comes to WordPress, they seem to forget major sites use WordPress and don't use vpns, look at mashable for example.

So to recap:

Ajax won't work behind a vpn.

Vpn is a terrible idea for reasons mentioned above

WordPress is secure and will remain so if you keep it and plugins up to date.

Listen to your Dev, you pay them for their expertise. I can promise you, that nothing undermines a working relationship like not putting your trust into an individual and having to check up on their knowledge.

If you do go with vpn, be sure to buy enough user licenses.

share|improve this answer
add comment

protected by Community Jan 17 at 8:18

Thank you for your interest in this question. Because it has attracted low-quality answers, posting an answer now requires 10 reputation on this site.

Would you like to answer one of these unanswered questions instead?

Not the answer you're looking for? Browse other questions tagged or ask your own question.