10-15-2018 02:15 AM
I am attempting to deserialize uccx scripts and i have hit a road block. my knowledge of Java is limited but from what i have been able to figure out you have to use the classes that created the serialized file in order to deserialize it. from what i can tell there are least a few JAR files that are needed. these are provided by the CCX script editor application.
CiscoWFFBase.jar
CiscoAppImpl.jar
CiscoWFAPI1.0.jar
CiscoAppImpl has a method in the that calls the following code which looks like Java deserialize code.
com.cisco.wfframework.obj.WFWorkflow wf = com.cisco.wfframework.obj.WFWorkflow.load(fname, Application.class.getClassLoader());
I could be wrong but this jar seems to be what loads or saves the scripts(AEF files). these jars also require that that a class called com.cisco.log.logmananger runs.
this is where i am hitting a block as i am struggling to to find a why that will allow me to bypass this. i have attempted to create custom class that do not log and have had some success by passing logmanager but this code fails am I am wondering if it due to the edits(striped out any section that tried to log) the error i get is listed below but I can get through 2 iterations of com.cisco.util.DoublyLinkedList.readObject(DoublyLinkedList.java) then the error is thrown.
is anyone willing to provide some insight or know of documentation that could help with this?
Exception in thread "main" java.io.StreamCorruptedException: unexpected block data
at java.io.ObjectInputStream.readObject0(Unknown Source)
at java.io.ObjectInputStream.defaultReadFields(Unknown Source)
at java.io.ObjectInputStream.readSerialData(Unknown Source)
at java.io.ObjectInputStream.readOrdinaryObject(Unknown Source)
at java.io.ObjectInputStream.readObject0(Unknown Source)
at java.io.ObjectInputStream.readObject(Unknown Source)
at com.cisco.wfframework.obj.WFBeanStep.readObjectCurrentVersion(WFBeanStep.java:537)
at com.cisco.wfframework.obj.WFBeanStep.readObject(WFBeanStep.java:401)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at java.io.ObjectStreamClass.invokeReadObject(Unknown Source)
at java.io.ObjectInputStream.readSerialData(Unknown Source)
at java.io.ObjectInputStream.readOrdinaryObject(Unknown Source)
at java.io.ObjectInputStream.readObject0(Unknown Source)
at java.io.ObjectInputStream.readObject(Unknown Source)
at com.cisco.util.DoublyLinkedList.readObject(DoublyLinkedList.java:220)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at java.io.ObjectStreamClass.invokeReadObject(Unknown Source)
at java.io.ObjectInputStream.readSerialData(Unknown Source)
at java.io.ObjectInputStream.readOrdinaryObject(Unknown Source)
at java.io.ObjectInputStream.readObject0(Unknown Source)
at java.io.ObjectInputStream.readObject(Unknown Source)
at com.cisco.wfframework.obj.WFWorkflow.readObjectCurrentVersion(WFWorkflow.java:1088)
at com.cisco.wfframework.obj.WFWorkflow.readObject(WFWorkflow.java:833)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at java.io.ObjectStreamClass.invokeReadObject(Unknown Source)
at java.io.ObjectInputStream.readSerialData(Unknown Source)
at java.io.ObjectInputStream.readOrdinaryObject(Unknown Source)
at java.io.ObjectInputStream.readObject0(Unknown Source)
at java.io.ObjectInputStream.readObject(Unknown Source)
at com.cisco.wfframework.obj.WFWorkflow.load(WFWorkflow.java:191)
at com.cisco.wfframework.obj.WFWorkflow.load(WFWorkflow.java:161)
at com.cisco.wfframework.obj.WFWorkflow.load(WFWorkflow.java:145)
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide