|
HTML Parser Home Page | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.htmlparser.scanners.ScriptDecoder
public class ScriptDecoder
Decode script. Script obfuscated by the Windows Script Encoder provided by Microsoft, is converted to plaintext. This code is based loosely on example code provided by MrBrownstone with changes by Joe Steele, see scrdec14.c.
Field Summary | |
---|---|
static int |
LAST_STATE
The state to enter when decrypting is complete. |
protected static int[] |
mDigits
The base 64 decoding table. |
protected static byte[] |
mEncodingIndex
Table of lookup choice. |
protected static char[] |
mEscaped
The escaped characters corresponding to the each escape sequence. |
protected static char[] |
mEscapes
Escape sequence characters. |
protected static char[] |
mLeader
The leader. |
protected static char[][] |
mLookupTable
Two dimensional lookup table. |
protected static char[] |
mPrefix
The prefix. |
protected static char[] |
mTrailer
The trailer. |
protected static int |
STATE_CHECKSUM
State when reading the checksum. |
protected static int |
STATE_DECODE
State while decoding. |
static int |
STATE_DONE
Termination state. |
protected static int |
STATE_ESCAPE
State when reading an escape sequence. |
protected static int |
STATE_FINAL
State while exiting. |
static int |
STATE_INITIAL
State on entry. |
protected static int |
STATE_LENGTH
State while reading the encoded length. |
protected static int |
STATE_PREFIX
State when reading up to decoded text. |
Constructor Summary | |
---|---|
ScriptDecoder()
|
Method Summary | |
---|---|
static String |
Decode(Page page,
Cursor cursor)
Decode script encoded by the Microsoft obfuscator. |
protected static long |
decodeBase64(char[] p)
Extract the base 64 encoded number. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final int STATE_DONE
public static final int STATE_INITIAL
protected static final int STATE_LENGTH
protected static final int STATE_PREFIX
protected static final int STATE_DECODE
protected static final int STATE_ESCAPE
protected static final int STATE_CHECKSUM
protected static final int STATE_FINAL
public static int LAST_STATE
Decode()
method.
protected static byte[] mEncodingIndex
protected static char[][] mLookupTable
protected static int[] mDigits
protected static char[] mLeader
protected static char[] mPrefix
protected static char[] mTrailer
protected static char[] mEscapes
protected static char[] mEscaped
Constructor Detail |
---|
public ScriptDecoder()
Method Detail |
---|
protected static long decodeBase64(char[] p)
p
- Six base 64 encoded digits.
public static String Decode(Page page, Cursor cursor) throws ParserException
page
- The source for encoded text.cursor
- The position at which to start decoding.
This is advanced to the end of the encoded text.
ParserException
- If an error is discovered while decoding.
|
© 2006 Derrick Oswald Sep 17, 2006
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
HTML Parser is an open source library released under Common Public License. |