Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(Re-)Add API endpoints for list manipulations #1387

Merged
merged 3 commits into from
May 29, 2020

Conversation

DL6ER
Copy link
Member

@DL6ER DL6ER commented May 26, 2020

By submitting this pull request, I confirm the following:

  • I have read and understood the contributors guide, as well as this entire template.
  • I have made only one major change in my proposed changes.
  • I have commented my proposed changes within the code.
  • I have tested my proposed changes, and have included unit tests where possible.
  • I am willing to help maintain this change if there are issues with it later.
  • I give this submission freely and claim no ownership.
  • It is compatible with the EUPL 1.2 license
  • I have squashed any insignificant commits. (git rebase)

What does this PR aim to accomplish?:

How does this PR accomplish the above?:

Add API endpoints api.php?list=black&add=domain.com like commands where add=domain and sub=domain can be used to manage the lists. A simple api.php?list=black will simply list all blacklisted domains.

list can be black, white, regex_white and regex_black.

What documentation changes (if any) are needed to support this PR?:

None

@DL6ER DL6ER added this to the v5.1 milestone May 26, 2020
@DL6ER DL6ER requested a review from PromoFaux May 26, 2020 16:39
Signed-off-by: DL6ER <dl6er@dl6er.de>
@DL6ER DL6ER force-pushed the new/api_add_sub_get_lists branch from 55c43df to 9105eef Compare May 26, 2020 16:41
@DL6ER DL6ER force-pushed the new/api_add_sub_get_lists branch from 9105eef to cce92cc Compare May 26, 2020 21:07
Signed-off-by: DL6ER <dl6er@dl6er.de>
@pralor-bot
Copy link

This pull request has been mentioned on Pi-hole Userspace. There might be relevant details there:

https://discourse.pi-hole.net/t/can-i-implement-my-own-plugin/33407/4

@PromoFaux
Copy link
Member

Presumably this PR also overrides #1360?

@pralor-bot
Copy link

This pull request has been mentioned on Pi-hole Userspace. There might be relevant details there:

https://discourse.pi-hole.net/t/php-webscripts/31016/32

@DL6ER
Copy link
Member Author

DL6ER commented May 27, 2020

@PromoFaux Yes

@PromoFaux
Copy link
Member

@DL6ER please resolve merge conflicts

@PromoFaux PromoFaux merged commit 7700d9b into devel May 29, 2020
@PromoFaux PromoFaux deleted the new/api_add_sub_get_lists branch May 29, 2020 22:30
@PromoFaux PromoFaux mentioned this pull request May 29, 2020
@pralor-bot
Copy link

This pull request has been mentioned on Pi-hole Userspace. There might be relevant details there:

https://discourse.pi-hole.net/t/black-whitelisting-does-not-work-on-v5-api/33119/4

@pralor-bot
Copy link

This pull request has been mentioned on Pi-hole Userspace. There might be relevant details there:

https://discourse.pi-hole.net/t/pi-hole-api/18565/7

@pralor-bot
Copy link

This pull request has been mentioned on Pi-hole Userspace. There might be relevant details there:

https://discourse.pi-hole.net/t/make-some-advance-api/26786/17

@PromoFaux PromoFaux mentioned this pull request Jul 5, 2020
@pralor-bot
Copy link

This pull request has been mentioned on Pi-hole Userspace. There might be relevant details there:

https://discourse.pi-hole.net/t/pi-hole-5-1-released/35577/1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants