Giter VIP home page Giter VIP logo

trellis-disable-xml-rpc's Introduction

trellis-disable-xml-rpc

GitHub tag license

Disable WordPress XML-RPC on Trellis sites.

Goal

Deny all requests to WordPress XML-RPC (i.e: /wp/xmlrpc.php) by Nginx.

Why disable WordPress XML-RPC?

Requirements

  • Trellis 17c26fc or later
  • Ansible v2.6 or later

Installation

Add this role to requirements.yml:

# requirements.yml
- src: https://github.com/ItinerisLtd/trellis-disable-xml-rpc
  version: 0.2.0 # Check for latest version!

Run the command:

➜ ansible-galaxy install -r requirements.yml --force

Add the role into dev.yml and server.yml, immediately after role: wordpress-setup:

roles:
  # Some other Trellis roles ...
  - { role: wordpress-setup, tags: [wordpress, wordpress-setup, letsencrypt] }
  - { role: trellis-disable-xml-rpc, tags: [nginx, wordpress, wordpress-setup] }
  # Some other Trellis roles ...

Then, re-provision as usual:

# https://roots.io/trellis/docs/local-development-setup/
➜ vagrant reload --provision

# https://roots.io/trellis/docs/remote-server-setup/
➜ ansible-playbook server.yml -e env=<environment>

Known Issues

Incompatible Plugins

Unfortunately, some plugins still relying on WordPress XML-RPC:

FAQs

Can I use this on managed hosting?

No, you can't use this on managed hosting such as Kinsta or WP Engine.

You can disable WordPress XML-RPC by filters:

Or, just use our plugin - itineris-disable-xml-rpc

It looks awesome. Where can I find some more goodies like this?

This isn't on wp.org. Where can I give a ⭐️⭐️⭐️⭐️⭐️ review?

Thanks! Glad you like it. It's important to make my boss know somebody is using this project. Instead of giving reviews on wp.org, consider:

  • tweet something good with mentioning @itineris_ltd
  • star this Github repo
  • watch this Github repo
  • write blog posts
  • submit pull requests
  • hire Itineris

Testing

Syntax Check

➜ ansible-playbook -i 'localhost,' --syntax-check tests/test.yml

Author Information

trellis-disable-xml-rpc is a Itineris Limited project created by Tang Rufus.

Special thanks to the Roots team whose Trellis make this project possible.

Full list of contributors can be found here.

Feedback

Please provide feedback! We want to make this library useful in as many projects as possible. Please submit an issue and point out what you do and don't like, or fork the project and make suggestions. No issue is too small.

Change log

Please see CHANGELOG for more information on what has changed recently.

License

trellis-disable-xml-rpc is released under the MIT License.

trellis-disable-xml-rpc's People

Contributors

tangrufus avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

trellis-disable-xml-rpc's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.