GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.

Issues (1881)

Security Analysis    not enabled

This project does not seem to handle request data directly as such no vulnerable execution paths were found.

  Cross-Site Scripting
Cross-Site Scripting enables an attacker to inject code into the response of a web-request that is viewed by other users. It can for example be used to bypass access controls, or even to take over other users' accounts.
  File Exposure
File Exposure allows an attacker to gain access to local files that he should not be able to access. These files can for example include database credentials, or other configuration files.
  File Manipulation
File Manipulation enables an attacker to write custom data to files. This potentially leads to injection of arbitrary code on the server.
  Object Injection
Object Injection enables an attacker to inject an object into PHP code, and can lead to arbitrary code execution, file exposure, or file manipulation attacks.
  Code Injection
Code Injection enables an attacker to execute arbitrary code on the server.
  Response Splitting
Response Splitting can be used to send arbitrary responses.
  File Inclusion
File Inclusion enables an attacker to inject custom files into PHP's file loading mechanism, either explicitly passed to include, or for example via PHP's auto-loading mechanism.
  Command Injection
Command Injection enables an attacker to inject a shell command that is execute with the privileges of the web-server. This can be used to expose sensitive data, or gain access of your server.
  SQL Injection
SQL Injection enables an attacker to execute arbitrary SQL code on your database server gaining access to user data, or manipulating user data.
  XPath Injection
XPath Injection enables an attacker to modify the parts of XML document that are read. If that XML document is for example used for authentication, this can lead to further vulnerabilities similar to SQL Injection.
  LDAP Injection
LDAP Injection enables an attacker to inject LDAP statements potentially granting permission to run unauthorized queries, or modify content inside the LDAP tree.
  Header Injection
  Other Vulnerability
This category comprises other attack vectors such as manipulating the PHP runtime, loading custom extensions, freezing the runtime, or similar.
  Regex Injection
Regex Injection enables an attacker to execute arbitrary code in your PHP process.
  XML Injection
XML Injection enables an attacker to read files on your local filesystem including configuration files, or can be abused to freeze your web-server process.
  Variable Injection
Variable Injection enables an attacker to overwrite program variables with custom data, and can lead to further vulnerabilities.
Unfortunately, the security analysis is currently not available for your project. If you are a non-commercial open-source project, please contact support to gain access.

compatibility/class-polylang-compatibility.php (1 issue)

Upgrade to new PHP Analysis Engine

These results are based on our legacy PHP analysis, consider migrating to our new PHP analysis engine instead. Learn more

1
<?php
2
/**
3
 * Polylang Compatibility Class
4
 * Credit : @Chrystl from wordpress.org - https://wordpress.org/support/topic/polylang-conflict-with-foo-gallery
5
 * Date: 30/08/2015
6
 */
7
if ( ! class_exists( 'FooGallery_Polylang_Compatibility' ) ) {
8
9
	class FooGallery_Polylang_Compatibility {
0 ignored issues
show
Coding Style Compatibility introduced by
PSR1 recommends that each class must be in a namespace of at least one level to avoid collisions.

You can fix this by adding a namespace to your class:

namespace YourVendor;

class YourClass { }

When choosing a vendor namespace, try to pick something that is not too generic to avoid conflicts with other libraries.

Loading history...
10
11
		function __construct() {
12
13
			if ( class_exists( 'Polylang' ) ) {
14
15
				add_filter( 'pll_get_post_types', array( $this, 'add_foogallery_cpt' ), 10, 2 );
16
				add_filter( 'pll_copy_post_metas', array( $this, 'ignore_foogallery_meta' ), 10, 2 );
17
18
				//whitelist the Polylang metabox
19
				add_filter( 'foogallery_metabox_sanity_foogallery', array( $this, 'add_pll_metaboxes' ) );
20
21
				add_action( 'admin_notices', array( $this, 'admin_notice' ) );
22
			}
23
		}
24
25
26
		/**
27
		 * Adds Foogallery post type to Polylang settings as 'public' is set to false
28
		 *
29
		 * @param $post_types
30
		 * @param $settings
31
		 *
32
		 * @return mixed
33
		 */
34
		function add_foogallery_cpt( $post_types, $settings ) {
35
			if ( $settings ) {
36
				$post_types['foogallery'] = 'foogallery';
37
			}
38
39
			return $post_types;
40
		}
41
42
		/**
43
		 * Adds/whitelists polylang metabox 'ml_box' as Foogallery blocks it by default
44
		 *
45
		 * @param $metabox_ids
46
		 *
47
		 * @return array
48
		 */
49
		function add_pll_metaboxes ($metabox_ids) {
50
			$metabox_ids[] = 'ml_box';
51
			return $metabox_ids;
52
		}
53
54
		/**
55
		 * Unsets the copy and synchronization of the fooggallery post meta.
56
		 * A better solution will be to rewritte a copy function to get the translation
57
		 *
58
		 * @param $metas
59
		 * @param $sync
60
		 *
61
		 * @return mixed
62
		 */
63
		function ignore_foogallery_meta($metas, $sync) {
64
65
			$key = array_search( FOOGALLERY_META_SETTINGS, $metas );
66
			if ( $key ) unset( $metas[$key] );
67
68
			$key = array_search( FOOGALLERY_META_ATTACHMENTS, $metas );
69
			if ( $key ) unset( $metas[$key] );
70
71
			$key = array_search( FOOGALLERY_META_CUSTOM_CSS, $metas );
72
			if ( $key ) unset( $metas[$key] );
73
74
			$key = array_search( FOOGALLERY_META_TEMPLATE, $metas );
75
			if ( $key ) unset( $metas[$key] );
76
77
			$key = array_search( FOOGALLERY_META_SORT, $metas );
78
			if ( $key ) unset( $metas[$key] );
79
80
			return $metas;
81
		}
82
83
		/**
84
		 * Add an admin notice to FooGallery pages when Polylang setting media_support is set
85
		 */
86
		function admin_notice() {
87
			if ( FOOGALLERY_CPT_GALLERY === foo_current_screen_post_type() ) {
88
89
				$options = get_option('polylang');
90
91
				if ( array_key_exists( 'media_support', $options ) && 1 === $options['media_support'] ) {
92
					?>
93
					<div class="notice error">
94
						<p>
95
							<strong><?php _e( 'FooGallery + Polylang Alert : ', 'foogallery' ); ?></strong>
96
							<?php _e( 'We noticed that you have Polylang installed and you have chosen to activate languages and translations for media.', 'foogallery' ); ?><br />
97
							<?php _e( 'This may cause empty galleries on translated pages! To disable this feature, please visit Settings -> Languages -> Settings Tab.', 'foogallery' ); ?>
98
						</p>
99
					</div>
100
					<?php
101
				}
102
			}
103
		}
104
	}
105
}