CipherUtils.java


current inspection = 2009-09-03 21:56:13 (id #1)


Filter Options
Annotation Kind:
pre
presumption
post
unanalyzed
test_vector


  • bool auth()

  • Kind Annotation Text
    pre(soft) init'ed(this.password)
    presumptioncom.dmdirc.config.IdentityManager:getConfigIdentity (...)@242 != null
    presumptioncom.dmdirc.config.IdentityManager:getGlobalConfig(. ..)@229 != null
    presumptioncom.dmdirc.config.IdentityManager:getGlobalConfig(. ..)@230 != null
    presumptioncom.dmdirc.config.IdentityManager:getGlobalConfig(. ..)@232 != null
    presumptioncom.dmdirc.config.IdentityManager:getGlobalConfig(. ..)@234 != null
    presumptiongetUserInput(...)@266 != null
    postinit'ed(return_value)
    postinit'ed(this.password)
    unanalyzedcall on com.dmdirc.Main:getUI
    unanalyzedcall on com.dmdirc.logger.Logger:userError
    unanalyzedcall on getUserInput
    unanalyzedcall on java.lang.String
    unanalyzedcall on java.lang.String:getBytes
    unanalyzedcall on java.lang.Throwable:__curr_excep_obj
    unanalyzedcall on java.nio.charset.Charset:forName
    unanalyzedcall on java.security.MessageDigest:digest
    unanalyzedcall on java.security.MessageDigest:getInstance
    test_vectorcom.dmdirc.config.ConfigManager:hasOptionString(... )@229: {0}, {1}
    test_vectorcom.dmdirc.config.ConfigManager:hasOptionString(... )@232: {0}, {1}
    test_vectorjava.lang.String:equals(...)@245: {1}, {0}
    test_vectorjava.lang.String:isEmpty(...)@238: {0}, {1}

  • bool checkAuthed()

  • Kind Annotation Text
    pre(soft) init'ed(this.ecipher)
    preinit'ed(this.dcipher)
    postinit'ed(return_value)
    test_vectorthis.dcipher: Addr_Set{null}, Inverse{null}
    test_vectorthis.ecipher: Addr_Set{null}, Inverse{null}

  • void com.dmdirc.util.CipherUtils()

  • Kind Annotation Text
    postnew byte[](CipherUtils#1) num objects == 1
    postthis.SALT == &new byte[](CipherUtils#1)
    postthis.SALT.length == 8
    postthis.SALT[0] == -87
    postthis.SALT[1] == -101
    postthis.SALT[2] == -56
    postthis.SALT[3] == 50
    postthis.SALT[4] == 86
    postthis.SALT[5] == 53
    postthis.SALT[6] == -29
    postthis.SALT[7] == 3

  • com.dmdirc.util.CipherUtils__static_init

  • Kind Annotation Text

  • void createCiphers()

  • Kind Annotation Text
    pre(soft) this.password != null
    presumptioninit'ed(com.dmdirc.logger.ErrorLevel.LOW)
    presumptionjavax.crypto.Cipher:getInstance(...)@191 != null
    presumptionjavax.crypto.Cipher:getInstance(...)@192 != null
    presumptionjavax.crypto.SecretKeyFactory:generateSecret(... )@189 != null
    presumptionjavax.crypto.SecretKeyFactory:getInstance(...)@189 != null
    postinit'ed(this.dcipher)
    postinit'ed(this.ecipher)

  • String decrypt(String)

  • Kind Annotation Text
    pre(soft) init'ed(net.miginfocom.Base64__static_init. new int[](Base64__static_init#1)[...])
    pre(soft) init'ed(this.ecipher)
    pre(soft) init'ed(this.password)
    preinit'ed(this.dcipher)
    presumptioninit'ed(com.dmdirc.logger.ErrorLevel.LOW)
    postinit'ed(this.dcipher)
    postinit'ed(this.ecipher)
    postinit'ed(this.password)
    postnew String(decrypt#1) num objects <= 1
    postreturn_value in Addr_Set{null,&amp;new String(decrypt#1)}
    unanalyzedcall on com.dmdirc.Main:getUI
    unanalyzedcall on com.dmdirc.config.ConfigManager:getOption
    unanalyzedcall on com.dmdirc.config.ConfigManager:hasOptionSt ring
    unanalyzedcall on com.dmdirc.config.Identity:setOption
    unanalyzedcall on com.dmdirc.config.IdentityManager:getConfig Identity
    unanalyzedcall on com.dmdirc.config.IdentityManager:getGlobal Config
    unanalyzedcall on com.dmdirc.logger.Logger:userError
    unanalyzedcall on getUserInput
    unanalyzedcall on java.lang.String
    unanalyzedcall on java.lang.String:charAt
    unanalyzedcall on java.lang.String:equals
    unanalyzedcall on java.lang.String:getBytes
    unanalyzedcall on java.lang.String:isEmpty
    unanalyzedcall on java.lang.String:length
    unanalyzedcall on java.lang.String:toCharArray
    unanalyzedcall on java.lang.Throwable:__curr_excep_obj
    unanalyzedcall on java.nio.charset.Charset:forName
    unanalyzedcall on java.security.MessageDigest:digest
    unanalyzedcall on java.security.MessageDigest:getInstance
    unanalyzedcall on javax.crypto.Cipher:getInstance
    unanalyzedcall on javax.crypto.Cipher:init
    unanalyzedcall on javax.crypto.SecretKey:getAlgorithm
    unanalyzedcall on javax.crypto.SecretKeyFactory:generateSecre t
    unanalyzedcall on javax.crypto.SecretKeyFactory:getInstance
    unanalyzedcall on javax.crypto.spec.PBEKeySpec
    unanalyzedcall on javax.crypto.spec.PBEParameterSpec
    test_vector!(this.dcipher == null) &amp; !(this.ecipher == null): {1}, {0}

  • String encrypt(String)

  • Kind Annotation Text
    pre(soft) init'ed(this.ecipher)
    pre(soft) init'ed(this.password)
    pre(soft) str != null
    preinit'ed(this.dcipher)
    presumptioninit'ed(com.dmdirc.logger.ErrorLevel.LOW)
    presumptionjavax.crypto.Cipher:doFinal(...).length@117 in {0, 3..169_538_366}
    postinit'ed(this.dcipher)
    postinit'ed(this.ecipher)
    postinit'ed(this.password)
    postnew String(encodeToString#1) num objects <= 1
    postreturn_value in Addr_Set{null,&amp;new String(encodeToString#1)}
    unanalyzedcall on com.dmdirc.Main:getUI
    unanalyzedcall on com.dmdirc.config.ConfigManager:getOption
    unanalyzedcall on com.dmdirc.config.ConfigManager:hasOptionSt ring
    unanalyzedcall on com.dmdirc.config.Identity:setOption
    unanalyzedcall on com.dmdirc.config.IdentityManager:getConfig Identity
    unanalyzedcall on com.dmdirc.config.IdentityManager:getGlobal Config
    unanalyzedcall on com.dmdirc.logger.Logger:userError
    unanalyzedcall on getUserInput
    unanalyzedcall on java.lang.String
    unanalyzedcall on java.lang.String:equals
    unanalyzedcall on java.lang.String:getBytes
    unanalyzedcall on java.lang.String:isEmpty
    unanalyzedcall on java.lang.String:toCharArray
    unanalyzedcall on java.lang.Throwable:__curr_excep_obj
    unanalyzedcall on java.nio.charset.Charset:forName
    unanalyzedcall on java.security.MessageDigest:digest
    unanalyzedcall on java.security.MessageDigest:getInstance
    unanalyzedcall on javax.crypto.Cipher:getInstance
    unanalyzedcall on javax.crypto.Cipher:init
    unanalyzedcall on javax.crypto.SecretKey:getAlgorithm
    unanalyzedcall on javax.crypto.SecretKeyFactory:generateSecre t
    unanalyzedcall on javax.crypto.SecretKeyFactory:getInstance
    unanalyzedcall on javax.crypto.spec.PBEKeySpec
    unanalyzedcall on javax.crypto.spec.PBEParameterSpec
    test_vector!(this.dcipher == null) &amp; !(this.ecipher == null): {1}, {0}

  • CipherUtils getCipherUtils()

  • Kind Annotation Text
    preinit'ed(me)
    postme != null
    postme == One-of{old me, &amp;new CipherUtils(getCipher Utils#1)}
    postnew CipherUtils(getCipherUtils#1) num objects <= 1
    postnew CipherUtils(getCipherUtils#1).SALT == &amp;new byte[](CipherUtils#1)
    postnew byte[](CipherUtils#1) num objects <= 1
    postnew byte[](CipherUtils#1).length == 8
    postnew byte[](CipherUtils#1)[0] == -87
    postnew byte[](CipherUtils#1)[1] == -101
    postnew byte[](CipherUtils#1)[2] == -56
    postnew byte[](CipherUtils#1)[3] == 50
    postnew byte[](CipherUtils#1)[4] == 86
    postnew byte[](CipherUtils#1)[5] == 53
    postnew byte[](CipherUtils#1)[6] == -29
    postnew byte[](CipherUtils#1)[7] == 3
    postreturn_value != null
    postreturn_value == One-of{old me, &amp;new CipherUtils(getCipherUtils#1)}
    test_vectorme: Inverse{null}, Addr_Set{null}

  • String getPassword(String)

  • Kind Annotation Text
    presumptioncom.dmdirc.Main:getUI(...)@266 != null
    postinit'ed(return_value)

  • String hash(String)

  • Kind Annotation Text
    pre(soft) data != null
    presumptioninit'ed(com.dmdirc.logger.ErrorLevel.LOW)
    presumptionjava.security.MessageDigest:getInstance(...)@160 != null
    postnew String(hash#1) num objects <= 1
    postreturn_value in Addr_Set{null,&amp;new String(hash#1)}