shell bypass 403

GrazzMean Shell

: /usr/share/doc/perl-Moose/t/cmop/ [ drwxr-xr-x ]
Uname: Linux web3.us.cloudlogin.co 5.10.226-xeon-hst #2 SMP Fri Sep 13 12:28:44 UTC 2024 x86_64
Software: Apache
PHP version: 8.1.31 [ PHP INFO ] PHP os: Linux
Server Ip: 162.210.96.117
Your Ip: 3.143.0.200
User: edustar (269686) | Group: tty (888)
Safe Mode: OFF
Disable Function:
NONE

name : immutable_custom_trait.t
use strict;
use warnings;

use Test::More;
use Test::Fatal;

use Class::MOP;

{

    package My::Meta;

    use strict;
    use warnings;

    use parent 'Class::MOP::Class';

    sub initialize {
        shift->SUPER::initialize(
            @_,
            immutable_trait => 'My::Meta::Class::Immutable::Trait',
        );
    }
}

{
    package My::Meta::Class::Immutable::Trait;

    use MRO::Compat;
    use parent 'Class::MOP::Class::Immutable::Trait';

    sub another_method { 42 }

    sub superclasses {
        my $orig = shift;
        my $self = shift;
        $self->$orig(@_);
    }
}

{
    package Foo;

    use strict;
    use warnings;
    use metaclass;

    __PACKAGE__->meta->add_attribute('foo');

    __PACKAGE__->meta->make_immutable;
}

{
    package Bar;

    use strict;
    use warnings;
    use metaclass 'My::Meta';

    use parent -norequire => 'Foo';

    __PACKAGE__->meta->add_attribute('bar');

    ::is( ::exception { __PACKAGE__->meta->make_immutable }, undef, 'can safely make a class immutable when it has a custom metaclass and immutable trait' );
}

{
    can_ok( Bar->meta, 'another_method' );
    is( Bar->meta->another_method, 42, 'another_method returns expected value' );
    is_deeply(
        [ Bar->meta->superclasses ], ['Foo'],
        'Bar->meta->superclasses returns expected value after immutabilization'
    );
}

done_testing;
© 2025 GrazzMean