Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [authentication]

The tag has no usage guidance.

0
votes
0answers
14 views

How can cookie/session authentication be used in wp-json fetch request?

I've written a /wp-json path like: add_action( 'rest_api_init', function () { register_rest_route( 'myplugin', 'foo', array( 'methods' => 'GET', 'callback' => function( $data ) { ...
0
votes
0answers
11 views

Using WooCommerce account to my other website

I'm is selling online trainings using WooCommerce store. When the client buys the item, he's given an unique key, which he can use to start new training on a dedicated training website (another ...
0
votes
1answer
34 views

Check for empty username or password on login

I'm building a custom login page for clients and wish to keep the wp-login page for site administrators. For checking for empty fields I'm using the code: function verify_user_pass($user, $username, ...
-1
votes
0answers
19 views

Make Authentication for Fake Login Without using Session

I'm newbie on WP, I want to make Login just using Password, the password set on Category. The Criteria is like this : Users sees login page on first visit Passwords are determined by password set in ...
3
votes
0answers
83 views

WordPress REST API call generates nonce twice on every call

I'm trying to login a user via the REST API, and then retrieve the current user on subsequent requests. As per the documentation, in my plugin, I am creating and retrieving a nonce after a successful ...
0
votes
0answers
4 views

Wordpress external autentication

I have question about autentication. I have external aplication (with login form) for autentication users, it is not wordpress. Other apps use this application, it is SSO. Now I needed to change ...
2
votes
0answers
173 views

WordPress “Link has expired” error on updating posts

I'm maintaining a WordPress site on GoDaddy for a client and they started to get the "this link has expired error" when they saved a post. It does not happen when I upload a file. However, I am ...
0
votes
0answers
43 views

Incorrect FTP authentication is blocking a plugin install and setting FS_METHOD to 'direct' in wp-config doesn't help

I'm trying to install the plugin "Form Maker by WD" into my WordPress site. Whether trying to install directly or through downloading and then uploading it, it throws an "incorrect ftp username/...
0
votes
0answers
22 views

Cannot access wp-admin but can authenticate frontend login

I have a custom function which is based off the wp_login_form(). I copied the function and essentially wrote it to add in two new fields to validate against - "mbjbookdomain" and "mbjbookreference". ...
0
votes
0answers
6 views

HTTP API: Request a page as authenticated user

Suppose i need to perform a HTTP request to a page inside my Wordpress itself, but i want it to be available only if actual user can manage options. It is basically a version of any page, with some ...
0
votes
0answers
27 views

Custom Login Integration not working in wordpress anymore

I have added a script in my functions.php file which checks a second custom database within the WordPress database when a member tries to login. This script was working correctly in the past and I ...
0
votes
1answer
162 views

Calling an API to do authentication / user login

I'm relatively new to wordpress and am working on a customized site. I have an API endpoint that I'd like to call to do authentication, because our users are going to have their credentials stored/...
0
votes
0answers
18 views

Add “edit” link to third-party application pages

I'm in the process migrating the WP theme to use a third-party client (JS web application). I'd like for people who are editing content to be able to easily click a link to go to edit the page. ...
0
votes
1answer
45 views

WordPress user Authentication

I am currently working on a plugin using WordPress. I created a register page that allow users to register, this information is then stored in custom database table called finusers. This is what I ...
0
votes
1answer
482 views

Rest API basic auth not working

I've setup a basic auth for quick testing a site. $headers = array ( 'Authorization' => 'Basic ' . base64_encode( 'admin' . ':' . 'Str0nGP@$$w0rd' ), ); $url = rest_url( 'wp/v2/posts/1' ); $...
1
vote
0answers
35 views

Wordpress + REST API v2 and private pages Load by slug

Im creating WP theme based on VUE, anyway I load pages based on slug - no by ID. I use base X-WP-Nonce header authentication, it working well with revision etc. So now I have a private page and my ...
0
votes
1answer
190 views

Possibility to login without password

I'm creating a webapplication for users that are racing in a rally. I have the following data from the different racers: Username Password Mobile phone Email The problem is they never know their ...
0
votes
0answers
326 views

Why does permission_callback not ovverride authentication?

I created a custome REST API endpoint for my WP instance, and upon reading the docs, they say that if you return true for the permission_callback function, that this will bypass the authentication ...
1
vote
1answer
43 views

implement authentication and authorization to user

i want to get authentication to my website like to be the page with name and password as a file reference to log in as visitor with detected authorization to each person want to visit the website how ...
0
votes
1answer
18 views

is_user_logged_in() returns different values on different pages

On most of my site, is_user_logged_in() works perfectly. On two pages with similar custom templates set, this incorrectly returns FALSE. The user can navigate back to other pages where it works ...
0
votes
0answers
12 views

To enter comment as a logged in user in my app

I have developed an app in ionic in which I am retrieving posts from my WordPress site. Now I want my registered users in the app to be able to post comments in the posts on Wordpress site without ...
1
vote
0answers
47 views

Add basic authentication of WordPress on any external PHP file?

I have a file named upload.php that is an API which does the job of uploading images to the server. I want that file to have a basic authentication of WordPress, so that while accessing that php from ...
0
votes
1answer
59 views

Securely log in a user without a password using a link?

I'd like to use links from my application to log users into Wordpress in their browser, but I'm concerned about whether this can be done securely. Obviously using any sort of static URL pattern seems ...
0
votes
0answers
12 views

How can I use the same fields for two different forms?

I'm trying to combine the login and register forms on a WooCommerce/WordPress site. The idea is that a single set of fields, username and password, could be submitted by two different forms. The first ...
0
votes
1answer
63 views

Authenticating users with usermeta fields

I have a working site where users are logging into using their email/username and password. Every user has a usermeta field with an unique code. I have to modify the login page in order to let them ...
0
votes
1answer
981 views

authentication issue with rest api - rest_cannot_create

I am using the rest api in Wordpress. For authentication I use the Basic authentication plugin (JSON Basic Authentication) I use this request (from both postman and nodejs): POST /wp-json/wp/v2/...
0
votes
0answers
86 views

Make REST API accessible to the public

My Wordpress site's API is currently set to private. Here is the link. How do I make it publicly accessible so the user doesn't have to be authenticated in order to access all of site's data via REST ...
0
votes
1answer
19 views

Secruity Questions on a timer

I am doing some research for a project and one requirement from the client is that to create an account a user must create security questions on account creation. I think this should be easy with a ...
3
votes
3answers
214 views

How to check WordPress website username and password is correct

On my site i have one form for client to submit their WordPress site details. On that form containing these fields WordPress admin url, username, and password. I want to check their login details are ...
11
votes
2answers
6k views

How to: Make JWT-authenticated requests to the Wordpress API

This is not really a question but a guide on how to make authenticated requests to the Wordpress API using JWT. I'm writing this as a reminder to myself and for those who may need some help with the ...
1
vote
0answers
74 views

How do I execute a wp_remote_get call using NTLM authentication?

I need to use ntlm authentication for a remote call, and I'm not sure how to configure the wp_remote_get call to do so. I have used wp_remote_get successfully in other situations without NTLM by ...
0
votes
1answer
195 views

Register rest field authentication with REST API

I'm trying to add some user meta information to the existing wp/v2/users REST endpoint. However, it looks like additional authentication is required, i.e. I get this (output in comments): ...
0
votes
1answer
252 views

Why does Wordpress use cookies for /wp-admin and /wp-content/plugins for non-admin users [duplicate]

After login with Firefox to Wordpress website as non admin user, 3 cookies are set: wordpress_logged_in_... wordpress_sec_... for path /wp-admin wordpress_sec_... for path /wp-content/plugins Why ...
0
votes
0answers
26 views

User registration for access to entire site with email invite

I am building an intranet site for a community to share confidential information. Access to the entire site should require registration and login. Registration should require an email invite with a ...
1
vote
2answers
258 views

Configuring WordPress Auth Cookie Expiration

I'm trying to configure the WordPress cookie expiration time, but for some reason it's not working. I went here: https://developer.wordpress.org/reference/hooks/auth_cookie_expiration/ And put the ...
4
votes
3answers
76 views

Log in from one wordpress website to another wordpress website

My client explicitly does not want to use 'multisite' wordpress option. My client has a main site and 199 sub sites (other domains). A user has usermeta with meta key: branch_id As an example (...
0
votes
1answer
341 views

wp_authenticate but not logged in

I am pretty new to all things Wordpress and seem to be really confused by what I have read. What I am doing is creating a plugin for a specific job and I need to simply change the menu once logged in....
0
votes
0answers
39 views

Random authentication failures on a load balanced WP setup

1 Wordpress instance I have a wordpress setup on one EC2 with a MySQL DB on another server. This setup works fine for both the blog access and wp-admin. 2 Wordpress instances I repeat a similar ...
0
votes
1answer
582 views

How can I authenticate user credentials against a Wordpress instance?

I am running a second web application in addition to Wordpress/WooCommerce. When users log into the second application, I'd like to authenticate them against the WP instance. I am using the REST API ...
0
votes
2answers
2k views

Can I authenticate with both WooCommerce consumer key and JWT?

I want to authenticate against both: the WooCommerce consumer key, for system queries and JSON Web Tokens (JWT), for user queries I have installed JWT Authentication for WP REST API. But after ...
2
votes
1answer
890 views

How to login to WordPress site using basic authentication HTTP headers?

I'm looking to run some of my automated acceptance tests as a logged in user. My acceptance tests are run using Ghost Inspector which can send basic authentication headers. There is a basic ...
1
vote
0answers
90 views

Wordpress authentication cookie and ajax calls

I'm up against a challenge. I got a WordPress website where users sign up to the website using the built-in WordPress user login system. And as you may know, this places a WordPress authentication ...
1
vote
0answers
108 views

for a role-protected page, programmatically login user and load page

Background: I would like to use WordPress as the companion site to my course the course is administered through an LMS on WordPress, I am using the Restrict Content to protect pages that cannot be ...
0
votes
1answer
393 views

Woocommerce cart expiry for logged in users

Does Woocommerce clear abandoned carts for logged in users? If so, what is the default lifespan and is it possible to change this? I would like to set a long expiry for authenticated user's carts so ...
1
vote
2answers
1k views

WP REST API - Nonce passes wp_verify_nonce even after logout

I'm creating a single page app with WP REST API and AngularJS. After solving a problem with nonces on this question, now i'm facing something else. To test the chance of adding fields and making them ...
0
votes
1answer
2k views

WP REST API: check if user is logged in

The idea is to show or hide some sections of the site in a theme that's fetching all data from the REST API, using AngularJS. I thought this check would help me (nonce is passed as header, as ...
0
votes
1answer
88 views

wp-json API: not logged in when clicking link to the API from admin mode

I have a meta box on a custom post type which has an link in it. This link goes to an endpoint in the wp-json rest API. On the endpoint in the rest API I use current_user_can to verify if the user is ...
0
votes
1answer
361 views

Best Authetication between REST API and Mobile App

I am developing a mobile app, with WordPress REST API. What is the recommended authentication method and plugin to use for? here the list I found: OAuth 1.0a OAuth 2.0 JWT Authentication Two-Factor ...
0
votes
1answer
147 views

How to make an other web app can login with wordpress authentication?

I creating an app right now using asp.net mvc 5. My client told me they have a main system created using wordpress. and our new app must be login/auth using that wordpress user or authentication. ...
2
votes
1answer
762 views

Should wordpress_logged_in cookie exist while logged out?

I noticed that while logged out on my Wordpress site, my browser is sending this Cookie header with every request (obfuscated for security): Cookie: wordpress_logged_in_OBFUSCATED=flimm%7COBFUSCATED; ...