Getting user names and passwords is a horrible idea I hope no user will actually agree to, but beyond that your idea to do it from JS is going to fail due to CORS, which means you will have to do it in AJAX to your server, and let your server try to login, which in turn will most likely flag it as a brute force attacker in no time, and all the major security players will just automatically block the requests.
You need to redesign you software to not need user name and password, probably use something like oauth2 instead. If oauth2 is not applicable for your situation…. well, tough luck.
Related Posts:
- Log in from one wordpress website to another wordpress website
- WordPress REST API call generates nonce twice on every call
- Rest Api WordPress
- Can someone explain what wp_session_tokens are, and what are they used for?
- How to check username/password without signing in the user
- Init action hook running late after PayPal’s return url?
- custom XMLRPC method plus authentication of user & WooCommerce order
- Problems after wp_set_password() containing an apostrophe
- WordPress custom authentication implementation
- How to: Rest endpoint returning empty object
- Custom endpoint that returns an xml
- Two-step login process – Is it possible?
- Plugin Sidebar is not Saving Meta Attribute to Post/Page after “Update”
- How do I approach removing menu items on the fly based on settings in my plugin?
- WP rest api v2 posts filter by ‘search’ & ‘category_name’ not working
- What method to use to call a REST API?
- How to extend expiry time of jwt wordpress token?
- Configuring WordPress Auth Cookie Expiration
- How to get the ID of the currently logged in user?
- Is there any way to check for user login and send him to login?
- WP REST API V2 – Add user data to response
- Proper way to pass credentials in a custom login form to avoid “headers already sent”
- How can I pass get_the_author_meta(‘user_email’) through the REST API?
- How to get results of subcategories also?(WP Rest Api v2)
- External Authentication, session_tokens not destroyed on logout
- Verify if user is wordpress logged in from another app since wordpress 4.0
- How to customize login process
- wp_insert_user() function password never match
- Logout users upon login, based on caps/role?
- Amending REST API function without deactivate/activate plugin every time changes is made
- How to save generated JWT token to cookies on login?
- Create a new post using rest api and save featured image using an external image url
- Adding custom end points, No error line
- Serve text/html from wp-json API via WPEngine, headers not being set properly
- Is it possible to make sure that only my plugins output is shown to the enduser?
- Secure REST with nonce works only when not logged
- Plugin Development for registered users
- How to do POST request with WP REST API v2 to custom table?
- Enqueue script globally
- WP Multisite login not working on one subsite. Possibly cookies/ history issue?
- rest_no_route on custom API endpoint wordpress
- How to set a cookie for logged in users to md5($user->ID . “my_secret”)?
- Custom Rest Endpoint: Post/Put/Patch not working
- Can’t retrieve body params from PUT endpoint using formdata
- Do I need to create an endpoint?
- How to use apiFetch to get author information in Gutenberg properly?
- Mock a dependency of a WP_REST_Controller class
- update_callback is not working in register_rest_field
- How do I validate extra pin field on my WordPress login form page?
- Secruity Questions on a timer
- How to redirect home page to another page after login for all user?
- Redirect returning users to a certain page?
- Allow REST API Endpoint to specific user and hide from public
- Custom Endpoint – Does it possible to use PUT method with WP API Rest?
- How to do admin ajax request in a plugin for rest api
- Attaching Image-file to userId
- Query String Filtering API
- Custom plugin & calling REST api of wordpress instance the plugins is running on
- GET request return value as error instead of success
- Allowing duplicating users with same user_login and user_email
- How to query a nested field in wordpress api using _fields param
- Get Custom taxonomy parent with wordpress REST API
- register_meta not showing custom post type metabox data in rest api
- why is apiFetch throwing Unhandled Promise Rejection: TypeError: Object is not a function
- How to Login a User inside a Plugin and Redirect to page?
- Using custom IDP with WP
- Securing custom rest API endpoints with public access from PWA
- WP_Query not ordering correctly
- Hiding the WordPress login and password fields from login page
- 403 error rest_’cookie_invalid_nonce’ on API Request
- The same session information for peer users on two different WordPress servers
- Adding Amchart Interface to WordPress API
- WC REST API Error Handling
- how to add security questions on wp-registration page and validate it
- Initializing rest endpoint issue
- redirect_to how to make it simply work with get parameter or similar?
- Multisite and the JSON REST API: How to?
- React in plugins: REST endpoints vs. regular functions
- Query only title/field/featured media of posts [closed]
- WP API users per page
- Best place to keep files that are called by cron jobs?
- Is it safe to use PUT and DELETE requests
- Multiple Users Logged In Causing Incorrect Account Returned
- Is it possible to make WordPress as a RESTful app?
- Get user logged in status from within a plugin. $current_user not defined
- Need edit profile link in the menu for logged in users
- Create a Custom Login System in WordPress [closed]
- how can I insert a link on login page
- user can login from single account detail from multiple locations(computer) at the same time [closed]
- oneOf two possible objects in WP REST API?
- Properly process a custom WP REST API request (Authenticate, Authorize + Validate)?
- Extend Plugin that creates an endpoint for GET request to also accepts POST requests
- How can create a custom plugin to call my webapi after any registration or membership plugin functionality
- Authenticate + Authorize WP REST API request before built-in WP JSON Schema Payload Validation?
- External api call using wordpress
- Does WP REST API cache internally executed (rest_do_request) requests?
- Run different permission_callback depending on HTTP method of custom REST API endpoint
- Login and register by API
- How to get locale within WP REST Request?
- How to boost WP custom post REST API GET queries by custom taxonomies