Documentation
¶
Index ¶
- Constants
- Variables
- func Debug(arg interface{})
- func DebugPrintf(fmt_str string, args ...interface{})
- func DecompressStream(compressed_container []byte) []byte
- type Directory
- type DirectoryHeader
- type OLEFile
- func (self *OLEFile) FindStreamByName(name string) *Directory
- func (self *OLEFile) GetStream(index uint32) []byte
- func (self *OLEFile) OpenStreamByName(name string) ([]byte, error)
- func (self *OLEFile) ReadChain(start uint32) []byte
- func (self *OLEFile) ReadFat(sector uint32) uint32
- func (self *OLEFile) ReadMiniChain(start uint32) []byte
- func (self *OLEFile) ReadMiniFat(sector uint32) uint32
- func (self *OLEFile) ReadMiniSector(sector uint32) []byte
- func (self *OLEFile) ReadSector(sector uint32) []byte
- type OLEHeader
- type VBAModule
Constants ¶
View Source
const ( // Limit the size of the document MAX_SECTORS = 1024 * 1024 MAX_SECTOR_SHIFT = 10 )
View Source
const ( FREESECT = 0xFFFFFFFF ENDOFCHAIN = 0xFFFFFFFE OLE_SIGNATURE = "\xD0\xCF\x11\xE0\xA1\xB1\x1A\xE1" MODULE_EXTENSION = "bas" CLASS_EXTENSION = "cls" FORM_EXTENSION = "frm" )
Variables ¶
View Source
var ( MAC_CODEPAGES = map[uint16]string{} BINFILE_NAME = regexp.MustCompile("(?i).bin$") )
View Source
var (
OLE_DEBUG *bool
)
Functions ¶
func DebugPrintf ¶
func DebugPrintf(fmt_str string, args ...interface{})
func DecompressStream ¶
Types ¶
type Directory ¶
type Directory struct {
Header DirectoryHeader
Index uint32
Name string
// contains filtered or unexported fields
}
type DirectoryHeader ¶
type OLEFile ¶
type OLEFile struct {
Header OLEHeader
SectorSize int
MiniSectorSize int
SectorCount int
FatSectors []uint32
Fat []uint32
MiniFat []uint32
Directory []*Directory
// contains filtered or unexported fields
}
func NewOLEFile ¶
func (*OLEFile) FindStreamByName ¶
func (*OLEFile) OpenStreamByName ¶
func (*OLEFile) ReadMiniChain ¶
func (*OLEFile) ReadMiniFat ¶
func (*OLEFile) ReadMiniSector ¶
func (*OLEFile) ReadSector ¶
type OLEHeader ¶
type OLEHeader struct {
AbSig [8]byte
Clid [16]byte
MinorVersion uint16
DllVersion uint16
ByteOrder uint16
SectorShift uint16
MiniSectorShift uint16
Reserved uint16
Reserved1 uint32
Reserved2 uint32
CsectFat uint32
SectDirStart uint32
Signature uint32
MiniSectorCutoff uint32
SectMiniFatStart uint32
CsectMiniFat uint32
SectDifStart uint32
CsectDif uint32
SectFat [109]uint32
}
Click to show internal directories.
Click to hide internal directories.