fof/src/eef08a1d-5367-4464-8d07-d47...
Robot 3e0a3c65cc
update 2024-04-07 13:20:18
2024-04-07 13:20:18 +02:00
..
README.md first commit 2023-10-09 11:38:00 +02:00
code.php first commit 2023-10-09 11:38:00 +02:00
code.power first commit 2023-10-09 11:38:00 +02:00
settings.json update 2024-04-07 13:20:18 2024-04-07 13:20:18 +02:00

README.md

██████╗  ██████╗ ██╗    ██╗███████╗██████╗
██╔══██╗██╔═══██╗██║    ██║██╔════╝██╔══██╗
██████╔╝██║   ██║██║ █╗ ██║█████╗  ██████╔╝
██╔═══╝ ██║   ██║██║███╗██║██╔══╝  ██╔══██╗
██║     ╚██████╔╝╚███╔███╔╝███████╗██║  ██║
╚═╝      ╚═════╝  ╚══╝╚══╝ ╚══════╝╚═╝  ╚═╝

class Randval (Details)

namespace: VDM\Joomla\FOF\Encrypt

@startuml
class Randval  #Gold {
  + generate(integer $bytes = 32) : string
  + genRandomBytes(integer $length = 32) : string
}

note right of Randval::generate
  Returns a cryptographically secure random value.
Since we only run on PHP 7+ we can use random_bytes(), which internally uses a crypto safe PRNG. If the function
doesn't exist, Joomla already loads a secure polyfill.
The reason this method exists is backwards compatibility with older versions of FOF. It also allows us to quickly
address any future issues if Joomla drops the polyfill or otherwise find problems with PHP's random_bytes() on
some weird host (you can't be too careful when releasing mass-distributed software).

  return: string
end note

note right of Randval::genRandomBytes
  Generate random bytes. Adapted from Joomla! 3.2.
Since we only run on PHP 7+ we can use random_bytes(), which internally uses a crypto safe PRNG. If the function
doesn't exist, Joomla already loads a secure polyfill.
The reason this method exists is backwards compatibility with older versions of FOF. It also allows us to quickly
address any future issues if Joomla drops the polyfill or otherwise find problems with PHP's random_bytes() on
some weird host (you can't be too careful when releasing mass-distributed software).

  return: string
end note
 
@enduml

     ██╗ ██████╗██████╗
     ██║██╔════╝██╔══██╗
     ██║██║     ██████╔╝
██   ██║██║     ██╔══██╗
╚█████╔╝╚██████╗██████╔╝
 ╚════╝  ╚═════╝╚═════╝

Build with Joomla Component Builder