This commit is contained in:
dev-chiefworks
2022-10-02 08:41:15 -04:00
18 changed files with 64 additions and 1818 deletions
-20
View File
@@ -1,20 +0,0 @@
[Tue Apr 05 12:06:24.720510 2022] [mpm_prefork:notice] [pid 1] AH00163: Apache/2.4.53 (Debian) PHP/7.4.28 configured -- resuming normal operations
[Tue Apr 05 12:06:24.720972 2022] [core:notice] [pid 1] AH00094: Command line: 'apache2 -D FOREGROUND'
[Tue Apr 05 16:17:57.412357 2022] [core:error] [pid 18] (13)Permission denied: [client 172.26.0.1:35440] AH00132: file permissions deny server access: /var/www/html/public/passets/css/style.bundle.css, referer: http://192.168.1.140:7072/projects
[Wed Apr 13 20:13:22.677845 2022] [mpm_prefork:notice] [pid 1] AH00163: Apache/2.4.53 (Debian) PHP/7.4.28 configured -- resuming normal operations
[Wed Apr 13 20:13:22.679971 2022] [core:notice] [pid 1] AH00094: Command line: 'apache2 -D FOREGROUND'
[Wed May 11 18:50:19.616658 2022] [mpm_prefork:notice] [pid 1] AH00163: Apache/2.4.53 (Debian) PHP/7.4.28 configured -- resuming normal operations
[Wed May 11 18:50:19.617523 2022] [core:notice] [pid 1] AH00094: Command line: 'apache2 -D FOREGROUND'
[Wed Jun 15 21:40:02.559476 2022] [mpm_prefork:notice] [pid 1] AH00163: Apache/2.4.53 (Debian) PHP/7.4.28 configured -- resuming normal operations
[Wed Jun 15 21:40:02.562472 2022] [core:notice] [pid 1] AH00094: Command line: 'apache2 -D FOREGROUND'
[Thu Jun 16 11:08:48.567534 2022] [mpm_prefork:notice] [pid 1] AH00163: Apache/2.4.53 (Debian) PHP/7.4.28 configured -- resuming normal operations
[Thu Jun 16 11:08:48.571448 2022] [core:notice] [pid 1] AH00094: Command line: 'apache2 -D FOREGROUND'
[Tue Jul 19 20:49:00.876347 2022] [mpm_prefork:notice] [pid 1] AH00163: Apache/2.4.53 (Debian) PHP/7.4.28 configured -- resuming normal operations
[Tue Jul 19 20:49:00.877157 2022] [core:notice] [pid 1] AH00094: Command line: 'apache2 -D FOREGROUND'
[Tue Aug 16 21:55:34.276600 2022] [mpm_prefork:notice] [pid 1] AH00163: Apache/2.4.53 (Debian) PHP/7.4.28 configured -- resuming normal operations
[Tue Aug 16 21:55:34.279840 2022] [core:notice] [pid 1] AH00094: Command line: 'apache2 -D FOREGROUND'
[Wed Sep 14 10:42:31.608901 2022] [mpm_prefork:notice] [pid 1] AH00163: Apache/2.4.53 (Debian) PHP/7.4.28 configured -- resuming normal operations
[Wed Sep 14 10:42:31.610731 2022] [core:notice] [pid 1] AH00094: Command line: 'apache2 -D FOREGROUND'
[Mon Sep 19 16:43:39.019361 2022] [mpm_prefork:notice] [pid 1] AH00170: caught SIGWINCH, shutting down gracefully
[Mon Sep 19 16:43:42.408390 2022] [mpm_prefork:notice] [pid 1] AH00163: Apache/2.4.54 (Debian) PHP/7.4.30 configured -- resuming normal operations
[Mon Sep 19 16:43:42.412232 2022] [core:notice] [pid 1] AH00094: Command line: 'apache2 -D FOREGROUND'
File diff suppressed because it is too large Load Diff
+5 -2
View File
@@ -7,9 +7,12 @@ services:
args:
uid: ${UID}
environment:
- APACHE_RUN_USER=#${UID}
- APACHE_RUN_GROUP=#${UID}
- APACHE_RUN_USER=${UID}
- APACHE_RUN_GROUP=${UID}
- CI_ENV
- CI_CONFIG
restart: unless-stopped
image: registry.chiefsoft.net/chiefsoftnet-web:latest
volumes:
- ./:/var/www/html
- ./apache_log:/var/log/apache2
+3
View File
@@ -1,5 +1,6 @@
FROM php:7.4-apache
RUN echo "ServerName localhost" >> /etc/apache2/apache2.conf
RUN apt-get clean
RUN apt-get update
RUN apt-get install -y \
git \
@@ -48,5 +49,7 @@ ARG uid=1000
RUN useradd -G www-data,root -u $uid -d /home/devuser devuser
RUN mkdir -p /home/devuser/.composer && \
chown -R devuser:devuser /home/devuser
RUN cd /var/www/html && composer install
RUN chmod -R a+w /var/www/html/writable
EXPOSE 80
+10 -20
View File
@@ -6,10 +6,8 @@ namespace Laminas\Escaper;
use function bin2hex;
use function ctype_digit;
use function function_exists;
use function hexdec;
use function htmlspecialchars;
use function iconv;
use function in_array;
use function mb_convert_encoding;
use function ord;
@@ -38,7 +36,7 @@ class Escaper
* entities that XML supports. Using HTML entities would result in this error:
* XML Parsing Error: undefined entity
*
* @var array
* @var array<int, string>
*/
protected static $htmlNamedEntityMap = [
34 => 'quot', // quotation mark
@@ -67,6 +65,7 @@ class Escaper
* Static Matcher which escapes characters for HTML Attribute contexts
*
* @var callable
* @psalm-var callable(array<array-key, string>):string
*/
protected $htmlAttrMatcher;
@@ -74,6 +73,7 @@ class Escaper
* Static Matcher which escapes characters for Javascript contexts
*
* @var callable
* @psalm-var callable(array<array-key, string>):string
*/
protected $jsMatcher;
@@ -81,6 +81,7 @@ class Escaper
* Static Matcher which escapes characters for CSS Attribute contexts
*
* @var callable
* @psalm-var callable(array<array-key, string>):string
*/
protected $cssMatcher;
@@ -255,7 +256,7 @@ class Escaper
* Callback function for preg_replace_callback that applies HTML Attribute
* escaping to all matches.
*
* @param array $matches
* @param array<array-key, string> $matches
* @return string
*/
protected function htmlAttrMatcher($matches)
@@ -302,7 +303,7 @@ class Escaper
* Callback function for preg_replace_callback that applies Javascript
* escaping to all matches.
*
* @param array $matches
* @param array<array-key, string> $matches
* @return string
*/
protected function jsMatcher($matches)
@@ -325,7 +326,7 @@ class Escaper
* Callback function for preg_replace_callback that applies CSS
* escaping to all matches.
*
* @param array $matches
* @param array<array-key, string> $matches
* @return string
*/
protected function cssMatcher($matches)
@@ -391,32 +392,21 @@ class Escaper
}
/**
* Encoding conversion helper which wraps iconv and mbstring where they exist or throws
* and exception where neither is available.
* Encoding conversion helper which wraps mb_convert_encoding
*
* @param string $string
* @param string $to
* @param array|string $from
* @throws Exception\RuntimeException
* @return string
*/
protected function convertEncoding($string, $to, $from)
{
if (function_exists('iconv')) {
$result = iconv($from, $to, $string);
} elseif (function_exists('mb_convert_encoding')) {
$result = mb_convert_encoding($string, $to, $from);
} else {
throw new Exception\RuntimeException(
static::class
. ' requires either the iconv or mbstring extension to be installed'
. ' when escaping for non UTF-8 strings.'
);
}
$result = mb_convert_encoding($string, $to, $from);
if ($result === false) {
return ''; // return non-fatal blank string on encoding errors from users
}
return $result;
}
}
+5 -4
View File
@@ -150,6 +150,7 @@ class Kint
'Kint\\Parser\\ClosurePlugin',
'Kint\\Parser\\ColorPlugin',
'Kint\\Parser\\DateTimePlugin',
'Kint\\Parser\\EnumPlugin',
'Kint\\Parser\\FsPathPlugin',
'Kint\\Parser\\IteratorPlugin',
'Kint\\Parser\\JsonPlugin',
@@ -548,9 +549,11 @@ class Kint
*
* Functionally equivalent to Kint::dump(1) or Kint::dump(debug_backtrace())
*
* @param mixed ...$args
*
* @return int|string
*/
public static function dump()
public static function dump(...$args)
{
if (false === static::$enabled_mode) {
return 0;
@@ -558,8 +561,6 @@ class Kint
Utils::normalizeAliases(static::$aliases);
$args = \func_get_args();
$call_info = static::getCallInfo(static::$aliases, \debug_backtrace(DEBUG_BACKTRACE_IGNORE_ARGS), \count($args));
$statics = static::getStatics();
@@ -587,7 +588,7 @@ class Kint
isset($call_info['params']) ? $call_info['params'] : [],
\count($args)
);
$output = $kintstance->dumpAll($args, $bases);
$output = $kintstance->dumpAll(\array_values($args), $bases);
if (static::$return || \in_array('@', $call_info['modifiers'], true)) {
return $output;
+6
View File
@@ -30,6 +30,7 @@ use Kint\Zval\Representation\Representation;
use Kint\Zval\Value;
use ReflectionClass;
use ReflectionProperty;
use UnitEnum;
class ClassStaticsPlugin extends Plugin
{
@@ -56,6 +57,11 @@ class ClassStaticsPlugin extends Plugin
$consts = [];
foreach ($reflection->getConstants() as $name => $val) {
// Skip enum constants
if ($var instanceof UnitEnum && $val instanceof UnitEnum && $o->classname == \get_class($val)) {
continue;
}
$const = Value::blank($name, '\\'.$class.'::'.$name);
$const->const = true;
$const->depth = $o->depth + 1;
+11 -2
View File
@@ -34,6 +34,7 @@ use Kint\Zval\ResourceValue;
use Kint\Zval\Value;
use ReflectionObject;
use stdClass;
use TypeError;
class Parser
{
@@ -191,6 +192,10 @@ class Parser
public function childHasPath(InstanceValue $parent, Value $child)
{
if ('__PHP_Incomplete_Class' === $parent->classname) {
return false;
}
if ('object' === $parent->type && (null !== $parent->access_path || $child->static || $child->const)) {
if (Value::ACCESS_PUBLIC === $child->access) {
return true;
@@ -434,7 +439,7 @@ class Parser
$rep = new Representation('Properties');
if (KINT_PHP74) {
if (KINT_PHP74 && '__PHP_Incomplete_Class' != $object->classname) {
$rprops = $reflector->getProperties();
foreach ($rprops as $rprop) {
@@ -524,7 +529,11 @@ class Parser
}
$stash = $val;
$copy[$i] = $refmarker;
try {
$copy[$i] = $refmarker;
} catch (TypeError $e) {
$child->reference = true;
}
if ($val === $refmarker) {
$child->reference = true;
$val = $stash;
+4
View File
@@ -52,6 +52,10 @@ class TimestampPlugin extends Plugin
return;
}
if ($var < 0) {
return;
}
if (\in_array($var, self::$blacklist, true)) {
return;
}
+1 -1
View File
@@ -32,7 +32,7 @@ use Throwable;
class CliRenderer extends TextRenderer
{
/**
* @var bool enable colors when Kint is run in *UNIX* command line
* @var bool enable colors
*/
public static $cli_colors = true;
+2
View File
@@ -42,6 +42,7 @@ class TextRenderer extends Renderer
'microtime' => 'Kint\\Renderer\\Text\\MicrotimePlugin',
'recursion' => 'Kint\\Renderer\\Text\\RecursionPlugin',
'trace' => 'Kint\\Renderer\\Text\\TracePlugin',
'enum' => 'Kint\\Renderer\\Text\\EnumPlugin',
];
/**
@@ -55,6 +56,7 @@ class TextRenderer extends Renderer
'Kint\\Parser\\MicrotimePlugin',
'Kint\\Parser\\StreamPlugin',
'Kint\\Parser\\TracePlugin',
'Kint\\Parser\\EnumPlugin',
];
/**
+4
View File
@@ -109,6 +109,10 @@ final class Utils
if (\file_exists($installed) && \is_readable($installed)) {
$packages = \json_decode(\file_get_contents($installed), true);
if (!\is_array($packages)) {
continue;
}
foreach ($packages as $package) {
if (isset($package['extra'][$key]) && \is_array($package['extra'][$key])) {
$extras = \array_replace($extras, $package['extra'][$key]);
+8 -12
View File
@@ -30,13 +30,13 @@ if (!\function_exists('d')) {
/**
* Alias of Kint::dump().
*
* @param mixed ...$args
*
* @return int|string
*/
function d()
function d(...$args)
{
$args = \func_get_args();
return \call_user_func_array(['Kint', 'dump'], $args);
return Kint::dump(...$args);
}
Kint::$aliases[] = 'd';
@@ -49,16 +49,13 @@ if (!\function_exists('s')) {
* Alias of Kint::dump(), however the output is in plain htmlescaped text
* with some minor visibility enhancements added.
*
* If run in CLI mode, output is not escaped.
* If run in CLI colors are disabled
*
* To force rendering mode without autodetecting anything:
*
* Kint::$enabled_mode = Kint::MODE_PLAIN;
* Kint::dump( $variable );
* @param mixed ...$args
*
* @return int|string
*/
function s()
function s(...$args)
{
if (false === Kint::$enabled_mode) {
return 0;
@@ -77,8 +74,7 @@ if (!\function_exists('s')) {
CliRenderer::$cli_colors = false;
$args = \func_get_args();
$out = \call_user_func_array(['Kint', 'dump'], $args);
$out = Kint::dump(...$args);
Kint::$enabled_mode = $kstash;
CliRenderer::$cli_colors = $cstash;
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long