Documentation
¶
Index ¶
- Variables
- type AuthMethod
- type EncryptMethod
- type Feature
- type Repository
- type UseCase
- func (uc *UseCase) BuildConfigurationObject(profileName string, data *entity.Profile, domainStuff *entity.Domain, ...) config.Configuration
- func (uc *UseCase) BuildWirelessProfiles(ctx context.Context, wifiConfigs []dto.ProfileWiFiConfigs, tenantID string) ([]config.WirelessProfile, error)
- func (uc *UseCase) DecryptPasswords(data *entity.Profile) error
- func (uc *UseCase) Delete(ctx context.Context, profileName, tenantID string) error
- func (uc *UseCase) Export(ctx context.Context, profileName, domainName, tenantID string) (encryptedYAML, encryptionKey string, err error)
- func (uc *UseCase) Get(ctx context.Context, top, skip int, tenantID string) ([]dto.Profile, error)
- func (uc *UseCase) GetByName(ctx context.Context, profileName, tenantID string) (*dto.Profile, error)
- func (uc *UseCase) GetCount(ctx context.Context, tenantID string) (int, error)
- func (uc *UseCase) GetDomainInformation(ctx context.Context, activation, domainName, tenantID string) (*entity.Domain, error)
- func (uc *UseCase) GetProfileData(ctx context.Context, profileName, tenantID string) (*entity.Profile, error)
- func (uc *UseCase) GetWiFiConfigurations(ctx context.Context, profileName, tenantID string) ([]dto.ProfileWiFiConfigs, error)
- func (uc *UseCase) HandleIEEE8021xSettings(ctx context.Context, data *entity.Profile, configuration *config.Configuration, ...) error
- func (uc *UseCase) Insert(ctx context.Context, d *dto.Profile) (*dto.Profile, error)
- func (uc *UseCase) SerializeAndEncryptYAML(configuration config.Configuration) (encryptedYAML, key string, err error)
- func (uc *UseCase) Update(ctx context.Context, d *dto.Profile) (*dto.Profile, error)
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrProfilesUseCase = consoleerrors.CreateConsoleError("ProfilesUseCase") ErrDatabase = sqldb.DatabaseError{Console: consoleerrors.CreateConsoleError("ProfilesUseCase")} ErrNotFound = sqldb.NotFoundError{Console: consoleerrors.CreateConsoleError("ProfilesUseCase")} ErrNotValid = dto.NotValidError{Console: consoleerrors.CreateConsoleError("ProfilesUseCase")} )
Functions ¶
This section is empty.
Types ¶
type AuthMethod ¶ added in v1.0.1
type AuthMethod int
const ( WPAPSK AuthMethod = 4 WPAIEEE8021x AuthMethod = 5 WPA2PSK AuthMethod = 6 WPA2IEEE8021x AuthMethod = 7 )
type EncryptMethod ¶ added in v1.0.1
type EncryptMethod int
const ( TKIP EncryptMethod = 3 CCMP EncryptMethod = 4 )
type Feature ¶
type Feature interface { GetCount(ctx context.Context, tenantID string) (int, error) Get(ctx context.Context, top, skip int, tenantID string) ([]dto.Profile, error) GetByName(ctx context.Context, profileName, tenantID string) (*dto.Profile, error) Delete(ctx context.Context, profileName, tenantID string) error Update(ctx context.Context, p *dto.Profile) (*dto.Profile, error) Insert(ctx context.Context, p *dto.Profile) (*dto.Profile, error) Export(ctx context.Context, profileName, domainName, tenantID string) (string, string, error) }
type Repository ¶
type Repository interface { GetCount(ctx context.Context, tenantID string) (int, error) Get(ctx context.Context, top, skip int, tenantID string) ([]entity.Profile, error) GetByName(ctx context.Context, profileName, tenantID string) (*entity.Profile, error) Delete(ctx context.Context, profileName, tenantID string) (bool, error) Update(ctx context.Context, p *entity.Profile) (bool, error) Insert(ctx context.Context, p *entity.Profile) (string, error) }
type UseCase ¶
type UseCase struct {
// contains filtered or unexported fields
}
UseCase -.
func New ¶
func New(r Repository, wifiConfig wificonfigs.Repository, w profilewificonfigs.Feature, i ieee8021xconfigs.Feature, log logger.Interface, d domains.Repository, safeRequirements security.Cryptor) *UseCase
New -.
func (*UseCase) BuildConfigurationObject ¶ added in v1.0.1
func (uc *UseCase) BuildConfigurationObject(profileName string, data *entity.Profile, domainStuff *entity.Domain, wifiConfigs []config.WirelessProfile) config.Configuration
func (*UseCase) BuildWirelessProfiles ¶ added in v1.0.1
func (*UseCase) DecryptPasswords ¶ added in v1.0.1
func (*UseCase) Export ¶ added in v1.0.1
func (uc *UseCase) Export(ctx context.Context, profileName, domainName, tenantID string) (encryptedYAML, encryptionKey string, err error)
Export - will call GetByName and return the profile with the associated wifi configs in YAML format to be downloaded.
func (*UseCase) GetDomainInformation ¶ added in v1.0.1
func (*UseCase) GetProfileData ¶ added in v1.0.1
func (*UseCase) GetWiFiConfigurations ¶ added in v1.0.1
func (*UseCase) HandleIEEE8021xSettings ¶ added in v1.0.1
func (*UseCase) SerializeAndEncryptYAML ¶ added in v1.0.1
func (uc *UseCase) SerializeAndEncryptYAML(configuration config.Configuration) (encryptedYAML, key string, err error)
Click to show internal directories.
Click to hide internal directories.