tui

package
v2.10.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 2, 2025 License: MIT Imports: 24 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	LdapServer       string
	LdapPort         int
	LdapUsername     string
	LdapPassword     string
	LdapPasswordFile string
	NtlmHash         string
	NtlmHashFile     string
	DomainName       string
	SocksServer      string
	TargetSpn        string
	KdcHost          string
	TimeFormat       string
	CertFile         string
	KeyFile          string
	PfxFile          string
	CCachePath       string

	Kerberos     bool
	Emojis       bool
	Colors       bool
	FormatAttrs  bool
	ExpandAttrs  bool
	AttrLimit    int
	CacheEntries bool
	Deleted      bool
	LoadSchema   bool
	PagingSize   uint32
	Timeout      int32
	Insecure     bool
	Ldaps        bool
	SearchFilter string
	RootDN       string
	ShowHeader   bool
	AuthType     int
)
View Source
var DefaultTheme = GodapTheme{

	TViewTheme: baseTheme,

	FieldBackgroundColor: tcell.ColorBlack,
	PlaceholderStyle:     tcell.Style{}.Foreground(tcell.ColorGray).Background(tcell.ColorBlack),
	PlaceholderTextColor: tcell.ColorGray,

	FormButtonStyle:           tcell.Style{}.Background(tcell.ColorWhite),
	FormButtonTextColor:       tcell.ColorBlack,
	FormButtonBackgroundColor: tcell.ColorWhite,
	FormButtonActivatedStyle:  tcell.StyleDefault.Background(tcell.ColorGray),

	RecycledNodeColor: tcell.ColorRed,
	DeletedNodeColor:  tcell.ColorGray,
	DisabledNodeColor: tcell.ColorYellow,
}
View Source
var GodapVer = "Godap v2.10.4"

Functions

func GetAttrCellColor added in v2.8.0

func GetAttrCellColor(cellName string, cellValue string) (string, bool)

func GetEntryColor added in v2.8.0

func GetEntryColor(entry *ldap.Entry) (tcell.Color, bool)

func SetupApp

func SetupApp()

Types

type EntryCache

type EntryCache struct {
	// contains filtered or unexported fields
}

func (*EntryCache) Add

func (sc *EntryCache) Add(key string, val *ldap.Entry)

func (*EntryCache) Clear

func (sc *EntryCache) Clear()

func (*EntryCache) Delete

func (sc *EntryCache) Delete(key string)

func (*EntryCache) FindWithRegexp

func (sc *EntryCache) FindWithRegexp(needle *regexp.Regexp) []EntryMatch

func (*EntryCache) Get

func (sc *EntryCache) Get(key string) (*ldap.Entry, bool)

func (*EntryCache) Length

func (sc *EntryCache) Length() int

type EntryMatch

type EntryMatch struct {
	MatchField      string
	MatchDN         string
	MatchAttrName   string
	MatchAttrVal    string
	MatchAttrValIdx int
	MatchPosBegin   int
	MatchPosEnd     int
}
type GPOLink struct {
	Target   string
	GUID     string
	Path     string
	Enabled  bool
	Enforced bool
}
func ParseGPLinks(gpoLinks string, target string) ([]GPOLink, error)

type GodapPage

type GodapPage struct {
	// contains filtered or unexported fields
}

type GodapTheme added in v2.8.0

type GodapTheme struct {
	TViewTheme tview.Theme

	// Input fields
	FieldBackgroundColor tcell.Color
	PlaceholderStyle     tcell.Style
	PlaceholderTextColor tcell.Color

	// Form buttons
	FormButtonStyle           tcell.Style
	FormButtonTextColor       tcell.Color
	FormButtonBackgroundColor tcell.Color
	FormButtonActivatedStyle  tcell.Style

	// Tree node colors
	RecycledNodeColor tcell.Color
	DeletedNodeColor  tcell.Color
	DisabledNodeColor tcell.Color
}

type ParsedACE

type ParsedACE struct {
	Idx            int
	SamAccountName string
	Type           string
	Mask           []string
	Inheritance    bool
	Scope          string
	NoPropagate    bool
	Severity       int
	Raw            sdl.ACEInt
}

type XForm

type XForm struct {
	*tview.Form
}

Form customizations

func NewXForm

func NewXForm() *XForm

func (*XForm) AddCheckbox

func (f *XForm) AddCheckbox(label string, checked bool, changed func(checked bool)) *XForm

func (*XForm) AddDropDown

func (f *XForm) AddDropDown(label string, options []string, initialOption int, selected func(option string, optionIndex int)) *XForm

func (*XForm) AddInputField

func (f *XForm) AddInputField(label, value string, fieldWidth int, accept func(textToCheck string, lastChar rune) bool, changed func(text string)) *XForm

func (*XForm) AddPasswordField

func (f *XForm) AddPasswordField(label, value string, fieldWidth int, mask rune, changed func(text string)) *XForm

func (*XForm) AddTextArea added in v2.10.0

func (f *XForm) AddTextArea(label string, text string, fieldWidth, fieldHeight int, maxLength int, changed func(text string)) *XForm

func (*XForm) AddTextView

func (f *XForm) AddTextView(label, text string, fieldWidth, fieldHeight int, dynamicColors, scrollable bool) *XForm

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL