Documentation
¶
Index ¶
- Constants
- Variables
- func CreateDocsEntry(label string, filename string, contentContainer *container.Scroll, ...) *fyne.MenuItem
- func Editor()
- func ExecuteEncoding(encoding string, data string) (string, error)
- func GetEncodings() iter.Seq[string]
- func MakeDocs() *fyne.MenuItem
- func MakeHelp() *fyne.Menu
- func OpenDoc(doc string)
- type MainWindow
- type PacketDisplay
- type PacketEntry
- func (p *PacketEntry) FocusGained()
- func (p *PacketEntry) FocusLost()
- func (p *PacketEntry) HasSelectedText() bool
- func (p *PacketEntry) MouseDown(event *desktop.MouseEvent)
- func (p *PacketEntry) MouseIn(event *desktop.MouseEvent)
- func (p *PacketEntry) MouseMoved(event *desktop.MouseEvent)
- func (p *PacketEntry) MouseOut()
- func (p *PacketEntry) MouseUp(event *desktop.MouseEvent)
- func (p *PacketEntry) SelectedText() string
- func (p *PacketEntry) SetText(text string)
- func (p *PacketEntry) TappedSecondary(evt *fyne.PointEvent)
- func (p *PacketEntry) TypedKey(_ *fyne.KeyEvent)
- func (p *PacketEntry) TypedRune(_ rune)
- func (p *PacketEntry) TypedShortcut(s fyne.Shortcut)
- type PacketFilter
- func (p *PacketFilter) AddListener(l func())
- func (p *PacketFilter) AppendPacket(packet packet.Packet)
- func (p *PacketFilter) ClearPackets()
- func (p *PacketFilter) CreateRenderer() fyne.WidgetRenderer
- func (p *PacketFilter) FilteredPackets() []packet.Packet
- func (p *PacketFilter) FindPacket(httpPacket packet.Packet) packet.Packet
- func (p *PacketFilter) LoadPackets()
- func (p *PacketFilter) LoadPacketsFromFile(filename string)
- func (p *PacketFilter) LoadPacketsFromReader(reader io.Reader)
- func (p *PacketFilter) SavePackets()
- func (p *PacketFilter) SetPackets(newPackets []packet.Packet)
- type PacketList
- type PacketRow
- type PlaceHolder
- type RecordButton
Constants ¶
const RECENTLY_OPENED = "RecentlyOpened"
Variables ¶
var ( SaveShortcut fyne.Shortcut = &desktop.CustomShortcut{KeyName: "S", Modifier: fyne.KeyModifierControl} OpenShortcut fyne.Shortcut = &desktop.CustomShortcut{KeyName: "O", Modifier: fyne.KeyModifierControl} SettingsShortcut fyne.Shortcut = &desktop.CustomShortcut{KeyName: "S", Modifier: fyne.KeyModifierControl | fyne.KeyModifierShift} ClearShortcut fyne.Shortcut = &desktop.CustomShortcut{KeyName: "X", Modifier: fyne.KeyModifierControl | fyne.KeyModifierShift} QuitShortcut fyne.Shortcut = &desktop.CustomShortcut{KeyName: "Q", Modifier: fyne.KeyModifierControl} )
Functions ¶
func CreateDocsEntry ¶ added in v0.14.0
func CreateDocsEntry(label string, filename string, contentContainer *container.Scroll, w fyne.Window) *fyne.MenuItem
CreateDocsEntry creates a menu subentry
func GetEncodings ¶
Types ¶
type MainWindow ¶ added in v0.17.0
type MainWindow struct { fyne.Window // PacketFilter manages the list of packets currently loaded into GITM PacketFilter *PacketFilter // contains filtered or unexported fields }
MainWindow is the main window of GITM It is the window that opens when the application is first launched.
func MakeMainWindow ¶ added in v0.17.0
func MakeMainWindow(packetChan chan packet.Packet, restart func()) *MainWindow
MakeMainWindow Creates the Fyne UI for GITM
func (*MainWindow) CheckForCrashData ¶ added in v0.17.0
func (m *MainWindow) CheckForCrashData()
CheckForCrashData checks to see if there is data from a prior crash.
If there is, it displays a comfirmation dialog for the user to choose whether to load the crash data.
func (*MainWindow) StartPacketHandler ¶ added in v0.17.0
func (m *MainWindow) StartPacketHandler()
type PacketDisplay ¶
type PacketDisplay struct { widget.BaseWidget // contains filtered or unexported fields }
func NewPacketDisplay ¶
func NewPacketDisplay(label string, w fyne.Window) *PacketDisplay
func (*PacketDisplay) CreateRenderer ¶
func (pd *PacketDisplay) CreateRenderer() fyne.WidgetRenderer
func (*PacketDisplay) SetText ¶
func (pd *PacketDisplay) SetText(text string)
type PacketEntry ¶
func NewPacketEntry ¶ added in v0.6.0
func NewPacketEntry(w fyne.Window) *PacketEntry
func (*PacketEntry) FocusGained ¶ added in v0.12.0
func (p *PacketEntry) FocusGained()
func (*PacketEntry) FocusLost ¶ added in v0.12.0
func (p *PacketEntry) FocusLost()
func (*PacketEntry) HasSelectedText ¶ added in v0.6.0
func (p *PacketEntry) HasSelectedText() bool
HasSelectedText reports whether there is an user-selected text
func (*PacketEntry) MouseDown ¶
func (p *PacketEntry) MouseDown(event *desktop.MouseEvent)
func (*PacketEntry) MouseIn ¶
func (p *PacketEntry) MouseIn(event *desktop.MouseEvent)
func (*PacketEntry) MouseMoved ¶
func (p *PacketEntry) MouseMoved(event *desktop.MouseEvent)
func (*PacketEntry) MouseOut ¶
func (p *PacketEntry) MouseOut()
func (*PacketEntry) MouseUp ¶
func (p *PacketEntry) MouseUp(event *desktop.MouseEvent)
func (*PacketEntry) SelectedText ¶ added in v0.6.0
func (p *PacketEntry) SelectedText() string
SelectedText returns the highlighted text
func (*PacketEntry) SetText ¶ added in v0.8.0
func (p *PacketEntry) SetText(text string)
func (*PacketEntry) TappedSecondary ¶ added in v0.6.0
func (p *PacketEntry) TappedSecondary(evt *fyne.PointEvent)
TappedSecondary handles when the user right clicks Creates the right click menu with entries for the supported decodings
func (*PacketEntry) TypedKey ¶ added in v0.12.0
func (p *PacketEntry) TypedKey(_ *fyne.KeyEvent)
func (*PacketEntry) TypedRune ¶ added in v0.12.0
func (p *PacketEntry) TypedRune(_ rune)
func (*PacketEntry) TypedShortcut ¶ added in v0.12.0
func (p *PacketEntry) TypedShortcut(s fyne.Shortcut)
type PacketFilter ¶ added in v0.8.0
type PacketFilter struct { widget.BaseWidget Packets []packet.Packet // contains filtered or unexported fields }
PacketFilter is a text input that allows the user to filter the packets captured by the proxy.
func NewPacketFilter ¶ added in v0.8.0
func NewPacketFilter(w fyne.Window) *PacketFilter
NewPacketFilter creates a new PacketFilter
func (*PacketFilter) AddListener ¶ added in v0.8.0
func (p *PacketFilter) AddListener(l func())
AddListener adds a listener function that will be called by p whenever the tracked packet list changes
func (*PacketFilter) AppendPacket ¶ added in v0.8.0
func (p *PacketFilter) AppendPacket(packet packet.Packet)
AppendPacket appends packet to the list trackets by p Calls all listeners added by AddListener
func (*PacketFilter) ClearPackets ¶ added in v0.8.0
func (p *PacketFilter) ClearPackets()
ClearPackets resets the list of tracked packets Calls all listeners added by AddListener
func (*PacketFilter) CreateRenderer ¶ added in v0.17.0
func (p *PacketFilter) CreateRenderer() fyne.WidgetRenderer
func (*PacketFilter) FilteredPackets ¶ added in v0.8.0
func (p *PacketFilter) FilteredPackets() []packet.Packet
FilteredPackets returns the list of packets that match the current filter input by the user
func (*PacketFilter) FindPacket ¶ added in v0.8.0
func (p *PacketFilter) FindPacket(httpPacket packet.Packet) packet.Packet
FindPacket searches the tracked packets for a matching packet
func (*PacketFilter) LoadPackets ¶ added in v0.11.0
func (p *PacketFilter) LoadPackets()
LoadPackets asks the user for a file to load from and then loads packets from that file
func (*PacketFilter) LoadPacketsFromFile ¶ added in v0.14.0
func (p *PacketFilter) LoadPacketsFromFile(filename string)
LoadPacketsFromMostRecentFile loads packets from the file most recently opened
func (*PacketFilter) LoadPacketsFromReader ¶ added in v0.14.0
func (p *PacketFilter) LoadPacketsFromReader(reader io.Reader)
LoadPacketsFromReader json unmarshals the reader contents
func (*PacketFilter) SavePackets ¶ added in v0.11.0
func (p *PacketFilter) SavePackets()
SavePackets asks the user for a file to save to, and then json marshalls the packet list, saving the result to the file.
func (*PacketFilter) SetPackets ¶ added in v0.8.0
func (p *PacketFilter) SetPackets(newPackets []packet.Packet)
SetPackets overwrites the tracked packets with packets Calls all listeners added by AddListener
type PacketList ¶ added in v0.17.0
type PacketList struct { widget.BaseWidget // contains filtered or unexported fields }
func NewPacketList ¶ added in v0.17.0
func NewPacketList(packetFilter *PacketFilter, mainWindow *MainWindow) *PacketList
func (*PacketList) CreateRenderer ¶ added in v0.17.0
func (p *PacketList) CreateRenderer() fyne.WidgetRenderer
func (*PacketList) MinSize ¶ added in v0.17.0
func (p *PacketList) MinSize() fyne.Size
type PacketRow ¶
type PacketRow struct { widget.BaseWidget // contains filtered or unexported fields }
func NewPacketRow ¶
func NewPacketRow() *PacketRow
func (*PacketRow) CreateRenderer ¶
func (row *PacketRow) CreateRenderer() fyne.WidgetRenderer
type PlaceHolder ¶ added in v0.13.0
type PlaceHolder struct { widget.BaseWidget // contains filtered or unexported fields }
func NewPlaceHolder ¶ added in v0.13.0
func NewPlaceHolder(label string, icon fyne.Resource) *PlaceHolder
func (*PlaceHolder) CreateRenderer ¶ added in v0.13.0
func (p *PlaceHolder) CreateRenderer() fyne.WidgetRenderer
func (*PlaceHolder) MinSize ¶ added in v0.13.0
func (p *PlaceHolder) MinSize() fyne.Size
type RecordButton ¶ added in v0.8.0
type RecordButton struct { widget.BaseWidget // IsRecording specified whether to record packets IsRecording bool // contains filtered or unexported fields }
RecordButton is a button that allows the user to choose whether they want to record packets that are MITMed by the proxy.
func NewRecordButton ¶ added in v0.8.0
func NewRecordButton(packetFilter *PacketFilter, w fyne.Window) *RecordButton
NewRecordButton creates a new RecordButton
func (*RecordButton) CreateRenderer ¶ added in v0.10.0
func (b *RecordButton) CreateRenderer() fyne.WidgetRenderer