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

erreur sur validation sous-reseau #527

Open
webchl opened this issue Oct 20, 2023 · 6 comments
Open

erreur sur validation sous-reseau #527

webchl opened this issue Oct 20, 2023 · 6 comments
Assignees
Labels
question Further information is requested

Comments

@webchl
Copy link

webchl commented Oct 20, 2023

Bonjour,

je ne peux plus valider le formulaire de sous-reseaux

voici le message:
Symfony Exception [ Symfony Docs](https://symfony.com/doc/5.4.21/index.html) [Error](http://10.248.23.52/admin/subnetworks/32#trace-box-1) HTTP 500 Internal Server Error Interface "Illuminate\Contracts\Validation\ValidationRule" not found ExceptionStack Trace Error in [/var/www/mercator/app/Rules/Cidr.php ](http://10.248.23.52/admin/subnetworks/32)(line 12) use const FILTER_FLAG_IPV6;use const FILTER_VALIDATE_INT;use const FILTER_VALIDATE_IP;use Illuminate\Contracts\Validation\ValidationRule;class Cidr implements ValidationRule{ /** @var bool whether or not the rule has been called with network constraints */ private bool $has_bits; /** in [/var/www/mercator/vendor/composer/ClassLoader.php ](http://10.248.23.52/admin/subnetworks/32)include (line 571) in [/var/www/mercator/vendor/composer/ClassLoader.php ](http://10.248.23.52/admin/subnetworks/32)Composer\Autoload\includeFile (line 428) ClassLoader->loadClass() in [/var/www/mercator/app/Http/Requests/UpdateSubnetworkRequest.php ](http://10.248.23.52/admin/subnetworks/32)(line 30) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Container/BoundMethod.php ](http://10.248.23.52/admin/subnetworks/32)-> rules (line 36) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Container/Util.php ](http://10.248.23.52/admin/subnetworks/32):: Illuminate\Container\{closure} (line 40) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Container/BoundMethod.php ](http://10.248.23.52/admin/subnetworks/32):: unwrapIfClosure (line 93) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Container/BoundMethod.php ](http://10.248.23.52/admin/subnetworks/32):: callBoundMethod (line 37) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Container/Container.php ](http://10.248.23.52/admin/subnetworks/32):: call (line 653) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Foundation/Http/FormRequest.php ](http://10.248.23.52/admin/subnetworks/32)-> call (line 113) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Foundation/Http/FormRequest.php ](http://10.248.23.52/admin/subnetworks/32)-> createDefaultValidator (line 92) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Validation/ValidatesWhenResolvedTrait.php ](http://10.248.23.52/admin/subnetworks/32)-> getValidatorInstance (line 23) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Foundation/Providers/FormRequestServiceProvider.php ](http://10.248.23.52/admin/subnetworks/32)-> validateResolved (line 30) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Container/Container.php ](http://10.248.23.52/admin/subnetworks/32)-> Illuminate\Foundation\Providers\{closure} (line 1265) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Container/Container.php ](http://10.248.23.52/admin/subnetworks/32)-> fireCallbackArray (line 1230) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Container/Container.php ](http://10.248.23.52/admin/subnetworks/32)-> fireAfterResolvingCallbacks (line 1215) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Container/Container.php ](http://10.248.23.52/admin/subnetworks/32)-> fireResolvingCallbacks (line 778) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Foundation/Application.php ](http://10.248.23.52/admin/subnetworks/32)-> resolve (line 851) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Container/Container.php ](http://10.248.23.52/admin/subnetworks/32)-> resolve (line 694) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Foundation/Application.php ](http://10.248.23.52/admin/subnetworks/32)-> make (line 836) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Routing/RouteDependencyResolverTrait.php ](http://10.248.23.52/admin/subnetworks/32)-> make (line 79) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Routing/RouteDependencyResolverTrait.php ](http://10.248.23.52/admin/subnetworks/32)-> transformDependency (line 48) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Routing/RouteDependencyResolverTrait.php ](http://10.248.23.52/admin/subnetworks/32)-> resolveMethodDependencies (line 28) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Routing/ControllerDispatcher.php ](http://10.248.23.52/admin/subnetworks/32)-> resolveClassMethodDependencies (line 41) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Routing/Route.php ](http://10.248.23.52/admin/subnetworks/32)-> dispatch (line 262) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Routing/Route.php ](http://10.248.23.52/admin/subnetworks/32)-> runController (line 205) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Routing/Router.php ](http://10.248.23.52/admin/subnetworks/32)-> run (line 721) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php ](http://10.248.23.52/admin/subnetworks/32)-> Illuminate\Routing\{closure} (line 128) Pipeline->Illuminate\Pipeline\{closure}() in [/var/www/mercator/app/Http/Middleware/SetLocale.php ](http://10.248.23.52/admin/subnetworks/32)(line 28) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php ](http://10.248.23.52/admin/subnetworks/32)-> handle (line 167) Pipeline->Illuminate\Pipeline\{closure}() in [/var/www/mercator/app/Http/Middleware/AuthGates.php ](http://10.248.23.52/admin/subnetworks/32)(line 32) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php ](http://10.248.23.52/admin/subnetworks/32)-> handle (line 167) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Routing/Middleware/SubstituteBindings.php ](http://10.248.23.52/admin/subnetworks/32)-> Illuminate\Pipeline\{closure} (line 50) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php ](http://10.248.23.52/admin/subnetworks/32)-> handle (line 167) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Auth/Middleware/Authenticate.php ](http://10.248.23.52/admin/subnetworks/32)-> Illuminate\Pipeline\{closure} (line 44) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php ](http://10.248.23.52/admin/subnetworks/32)-> handle (line 167) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/VerifyCsrfToken.php ](http://10.248.23.52/admin/subnetworks/32)-> Illuminate\Pipeline\{closure} (line 78) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php ](http://10.248.23.52/admin/subnetworks/32)-> handle (line 167) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/View/Middleware/ShareErrorsFromSession.php ](http://10.248.23.52/admin/subnetworks/32)-> Illuminate\Pipeline\{closure} (line 49) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php ](http://10.248.23.52/admin/subnetworks/32)-> handle (line 167) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Session/Middleware/StartSession.php ](http://10.248.23.52/admin/subnetworks/32)-> Illuminate\Pipeline\{closure} (line 121) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Session/Middleware/StartSession.php ](http://10.248.23.52/admin/subnetworks/32)-> handleStatefulRequest (line 64) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php ](http://10.248.23.52/admin/subnetworks/32)-> handle (line 167) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Cookie/Middleware/AddQueuedCookiesToResponse.php ](http://10.248.23.52/admin/subnetworks/32)-> Illuminate\Pipeline\{closure} (line 37) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php ](http://10.248.23.52/admin/subnetworks/32)-> handle (line 167) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Cookie/Middleware/EncryptCookies.php ](http://10.248.23.52/admin/subnetworks/32)-> Illuminate\Pipeline\{closure} (line 67) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php ](http://10.248.23.52/admin/subnetworks/32)-> handle (line 167) Pipeline->Illuminate\Pipeline\{closure}() in [/var/www/mercator/app/Http/Middleware/ForceXForwardedProto.php ](http://10.248.23.52/admin/subnetworks/32)(line 17) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php ](http://10.248.23.52/admin/subnetworks/32)-> handle (line 167) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php ](http://10.248.23.52/admin/subnetworks/32)-> Illuminate\Pipeline\{closure} (line 103) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Routing/Router.php ](http://10.248.23.52/admin/subnetworks/32)-> then (line 723) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Routing/Router.php ](http://10.248.23.52/admin/subnetworks/32)-> runRouteWithinStack (line 698) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Routing/Router.php ](http://10.248.23.52/admin/subnetworks/32)-> runRoute (line 662) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Routing/Router.php ](http://10.248.23.52/admin/subnetworks/32)-> dispatchToRoute (line 651) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php ](http://10.248.23.52/admin/subnetworks/32)-> dispatch (line 167) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php ](http://10.248.23.52/admin/subnetworks/32)-> Illuminate\Foundation\Http\{closure} (line 128) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TransformsRequest.php ](http://10.248.23.52/admin/subnetworks/32)-> Illuminate\Pipeline\{closure} (line 21) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/ConvertEmptyStringsToNull.php ](http://10.248.23.52/admin/subnetworks/32)-> handle (line 31) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php ](http://10.248.23.52/admin/subnetworks/32)-> handle (line 167) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TransformsRequest.php ](http://10.248.23.52/admin/subnetworks/32)-> Illuminate\Pipeline\{closure} (line 21) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TrimStrings.php ](http://10.248.23.52/admin/subnetworks/32)-> handle (line 40) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php ](http://10.248.23.52/admin/subnetworks/32)-> handle (line 167) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/ValidatePostSize.php ](http://10.248.23.52/admin/subnetworks/32)-> Illuminate\Pipeline\{closure} (line 27) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php ](http://10.248.23.52/admin/subnetworks/32)-> handle (line 167) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/PreventRequestsDuringMaintenance.php ](http://10.248.23.52/admin/subnetworks/32)-> Illuminate\Pipeline\{closure} (line 86) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php ](http://10.248.23.52/admin/subnetworks/32)-> handle (line 167) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php ](http://10.248.23.52/admin/subnetworks/32)-> Illuminate\Pipeline\{closure} (line 103) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php ](http://10.248.23.52/admin/subnetworks/32)-> then (line 142) in [/var/www/mercator/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php ](http://10.248.23.52/admin/subnetworks/32)-> sendRequestThroughRouter (line 111) Kernel->handle() in [/var/www/mercator/public/index.php ](http://10.248.23.52/admin/subnetworks/32)(line 55)

idem sur admin/logical-servers/28

merci

@dbarzin
Copy link
Owner

dbarzin commented Oct 20, 2023

Cela ne se produit pas sur ma version.
As-tu bien la dernière version du code ?
As-tu effacer le cache ?
Peux-tu m'envoyer une capture d'écran des données envoyées ?

@dbarzin dbarzin self-assigned this Oct 20, 2023
@webchl
Copy link
Author

webchl commented Oct 23, 2023

Bonjour Didier

alors étapes de ce jour:
réalisation d'un snapshot
j'ai relancé la mise a jour (je l'avais faite il y a environ 15 jours) en suivant ceci:
cd /var/www/mercator
git pull
php artisan migrate
composer update
puis voici le message:
5 package suggestions were added by new dependencies, use composer suggest to see details.
Generating optimized autoload files

Illuminate\Foundation\ComposerScripts::postAutoloadDump
@php artisan package:discover --ansi

In trustedproxy.php line 48:

Undefined constant Illuminate\Http\Request::HEADER_X_FORWARDED_ALL

Script @php artisan package:discover --ansi handling the post-autoload-dump event returned with error code 1

du coup l'accès a mercator HS et je suis revenu en arriere sur mon snapshot

merci de ton aide

@dbarzin
Copy link
Owner

dbarzin commented Oct 23, 2023 via email

@webchl
Copy link
Author

webchl commented Oct 23, 2023

desole mais concretement je ne sais pas ce qu'il faut faire

@dbarzin
Copy link
Owner

dbarzin commented Oct 23, 2023

C'est décrit ici : #381

@dbarzin dbarzin added the question Further information is requested label Oct 23, 2023
@webchl
Copy link
Author

webchl commented Oct 24, 2023

donc pour information détaillée

il faut modifier le fichier /var/www/mercator/config/trustedproxy.php et modifier la ligne
'headers' => Illuminate\Http\Request::HEADER_X_FORWARDED_ALL,

en

'headers' => Illuminate\Http\Request::HEADER_X_FORWARDED_FOR | Illuminate\Http\Request::HEADER_X_FORWARDED_HOST | Illuminate\Http\Request::HEADER_X_FORWARDED_PORT | Illuminate\Http\Request::HEADER_X_FORWARDED_PROTO | Illuminate\Http\Request::HEADER_X_FORWARDED_AWS_ELB,

puis réaliser la mise a jour:

cd /var/www/mercator
git pull
php artisan migrate
composer update
php artisan config:clear && php artisan view:clear

désormais plus d'erreurs

merci

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants