Error: Type was not found or was not a compile-time constant: ICipher.

33 views
Skip to first unread message

Roger

unread,
Sep 24, 2016, 5:18:26 PM9/24/16
to BigBlueButton-dev
Presently, I am attempting to incorporate DES encryption into the BBB server.  I am using this library:

https://code.google.com/archive/p/as3crypto

So far, I have copied as3crypto.swc into ~/dev/bigbluebutton/bigbluebutton-client/libs, and added it to the libs3.xml file:

      <root url="jar://$PROJECT_DIR$/bigbluebutton-client/libs/as3crypto.swc!/" />

How should I include this as an import?  When I try to build, I get these errors:

    [mxmlc] /home/rmoore/dev/bigbluebutton/bigbluebutton-client/src/org/bigbluebutton/modules/timer/views/TimerWindow.mxml(171):  Error: Type was not found or was not a compile-time constant: IPad.
    [mxmlc] 
    [mxmlc]                             var pad:IPad = new NullPad();
    [mxmlc] 
    [mxmlc] /home/rmoore/dev/bigbluebutton/bigbluebutton-client/src/org/bigbluebutton/modules/timer/views/TimerWindow.mxml(172):  Error: Type was not found or was not a compile-time constant: ICipher.
    [mxmlc] 
    [mxmlc]                             var des:ICipher = Crypto.getCipher("des-cbc", key, pad);
    [mxmlc] 
    [mxmlc] /home/rmoore/dev/bigbluebutton/bigbluebutton-client/src/org/bigbluebutton/modules/timer/views/TimerWindow.mxml(173):  Error: Type was not found or was not a compile-time constant: IVMode.
    [mxmlc] 
    [mxmlc]                             var ivmode:IVMode = aes as IVMode;
    [mxmlc] 
    [mxmlc] /home/rmoore/dev/bigbluebutton/bigbluebutton-client/src/org/bigbluebutton/modules/timer/views/TimerWindow.mxml(169):  Error: Access of undefined property Hex.
    [mxmlc] 
    [mxmlc]                             var inputBA:ByteArray=Hex.toArray(Hex.fromString(input));        
    [mxmlc] 
    [mxmlc] /home/rmoore/dev/bigbluebutton/bigbluebutton-client/src/org/bigbluebutton/modules/timer/views/TimerWindow.mxml(170):  Error: Access of undefined property Hex.
    [mxmlc] 
    [mxmlc]                             var key:ByteArray = Hex.toArray(Hex.fromString(decrKey));                
    [mxmlc] 
    [mxmlc] /home/rmoore/dev/bigbluebutton/bigbluebutton-client/src/org/bigbluebutton/modules/timer/views/TimerWindow.mxml(171):  Error: Call to a possibly undefined method NullPad.
    [mxmlc] 
    [mxmlc]                             var pad:IPad = new NullPad();
    [mxmlc] 
    [mxmlc] /home/rmoore/dev/bigbluebutton/bigbluebutton-client/src/org/bigbluebutton/modules/timer/views/TimerWindow.mxml(172):  Error: Access of undefined property Crypto.
    [mxmlc] 
    [mxmlc]                             var des:ICipher = Crypto.getCipher("des-cbc", key, pad);
    [mxmlc] 
    [mxmlc] /home/rmoore/dev/bigbluebutton/bigbluebutton-client/src/org/bigbluebutton/modules/timer/views/TimerWindow.mxml(173):  Error: Access of undefined property aes.
    [mxmlc] 
    [mxmlc]                             var ivmode:IVMode = aes as IVMode;
    [mxmlc] 
    [mxmlc] /home/rmoore/dev/bigbluebutton/bigbluebutton-client/src/org/bigbluebutton/modules/timer/views/TimerWindow.mxml(173):  Error: Access of undefined property IVMode.
    [mxmlc] 
    [mxmlc]                             var ivmode:IVMode = aes as IVMode;
    [mxmlc] 
    [mxmlc] /home/rmoore/dev/bigbluebutton/bigbluebutton-client/src/org/bigbluebutton/modules/timer/views/TimerWindow.mxml(174):  Error: Access of undefined property Hex.
    [mxmlc] 
    [mxmlc]                             ivmode.IV = Hex.toArray(Hex.fromString(decrIV));            
    [mxmlc] 
    [mxmlc] /home/rmoore/dev/bigbluebutton/bigbluebutton-client/src/org/bigbluebutton/modules/timer/views/TimerWindow.mxml(177):  Error: Access of undefined property Base64.
    [mxmlc] 
    [mxmlc]                             return Base64.encodeByteArray( inputBA);
    [mxmlc] 

BUILD FAILED
/home/rmoore/dev/bigbluebutton/bigbluebutton-client/build.xml:201: The following error occurred while executing this line:
/home/rmoore/dev/bigbluebutton/bigbluebutton-client/build.xml:373: mxmlc task failed

Total time: 3 minutes 4 seconds
~/dev/bigbluebutton/bigbluebutton-client $     [mxmlc] /home/rmoore

Do you have any suggestions?  TIA.

Roger

unread,
Sep 24, 2016, 7:24:55 PM9/24/16
to BigBlueButton-dev
This is my code:

                       import com.hurlant.crypto.symmetric.AESKey;
                        import com.hurlant.crypto.symmetric.DESKey;
                        import com.hurlant.util.Hex;
                      

                            // ...
                            var pad:IPad = new NullPad();
                            var aes:ICipher = Crypto.getCipher("des-cbc", key, pad);
                            var ivmode:IVMode = aes as IVMode;
                            ivmode.IV = Hex.toArray(Hex.fromString(decrIV));            
                            aes.encrypt(inputBA);  
                            // ...

Chad Pilkey

unread,
Sep 26, 2016, 12:49:23 PM9/26/16
to BigBlueButton-dev
If that is your complete list of imports you aren't importing enough classes. The error messages all say that the class can't be found because you haven't imported them.

Missing imports is likely the cause of the problem in your other post too
https://groups.google.com/d/msg/bigbluebutton-dev/6rQrmOzDDdg/4fssrxI3BwAJ

Roger Moore

unread,
Sep 26, 2016, 2:47:23 PM9/26/16
to bigblueb...@googlegroups.com
Yes, that's it--thank you!  I didn't know that in ActionScript you have to import each individual class. :)

--
You received this message because you are subscribed to a topic in the Google Groups "BigBlueButton-dev" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/bigbluebutton-dev/UGty6fVh1Yc/unsubscribe.
To unsubscribe from this group and all its topics, send an email to bigbluebutton-dev+unsubscribe@googlegroups.com.
To post to this group, send email to bigbluebutton-dev@googlegroups.com.
Visit this group at https://groups.google.com/group/bigbluebutton-dev.
For more options, visit https://groups.google.com/d/optout.

Reply all
Reply to author
Forward
0 new messages