class Matter::Network::WiFiCredentials

Overview

WiFi Credentials

Represents parsed WiFi credentials in a structured format. The backend can use this information to configure the network interface without needing to parse raw bytes.

Defined in:

matter/network/credentials.cr

Constructors

Instance Method Summary

Constructor Detail

def self.new(credentials : Bytes) #

[View source]

Instance Method Detail

def credentials : Bytes #

The credential data (passphrase or PSK)


[View source]
def is_psk : Bool #

Whether this is a raw PSK (true) or passphrase (false)


[View source]
def passphrase : String #

Get credentials as a string (for passphrases)


[View source]
def psk_hex : String #

Get credentials as hex string (for PSKs)


[View source]
def raw : Bytes #

Get raw credential bytes


[View source]
def security_type : WiFiSecurityType #

Inferred security type based on credential length and format


[View source]
def to_s(io : IO) #
Description copied from class Reference

Appends a short String representation of this object which includes its class name and its object address.

class Person
  def initialize(@name : String, @age : Int32)
  end
end

Person.new("John", 32).to_s # => #<Person:0x10a199f20>

[View source]