Data Visualization Desktop: Make it Yours, But do not Forget Security!

Bf71450537acca19e045ae6f7febdf9a?s=47 Gianni Ceresa
December 04, 2017

Data Visualization Desktop: Make it Yours, But do not Forget Security!

Custom plugin development for Oracle Data Visualization Desktop and the security impact of using unknown and from not trusted sources.

Presented at UKOUG Tech17 in Birmingham (UK)

Bf71450537acca19e045ae6f7febdf9a?s=128

Gianni Ceresa

December 04, 2017
Tweet

Transcript

  1. None
  2. • • • How to build a custom plugin (the

    theory) How to build it without doc as there isn’t one (I hope you like JavaScript…) DVD is more similar to OBIEE than what you can imagine Web service APIs At least a bit about the current version of it: v4 (aka 12.2.4.0.0)
  3. None
  4. • • • • • • • • • •

  5. None
  6. • • What you get from Oracle

  7. • • •

  8. None
  9. set DVDESKTOP_SDK_HOME="C:\Oracle\Oracle Data Visualization Desktop" set PLUGIN_DEV_DIR="C:\Oracle\DVD_plugins" set PATH=%DVDESKTOP_SDK_HOME%\tools\bin;%PATH% cd

    %PLUGIN_DEV_DIR% bicreateenv bicreateplugin viz -id ch.datalysis.tech17demo -subType dataviz Path where DVD is installed Path where the plugins will be developed (optional) Unique ID, java package “style” name
  10. None
  11. .\gradlew run Definitely SDK mode Interesting URL: 127.0.0.1 a webserver

    run locally port 49765, can be different as it’s a randomly chosen port /va/ui/home.jsp just like in OBIEE
  12. document.cookie="ORA_BI_SESSTOK=authenticated; path=/"

  13. None
  14. WARNING Code is about to start, I hope you like

    JavaScript
  15. • • •

  16. • • skin!css!ch-datalysis-tech17demo/tech17demostyles ch-datalysis-tech17demo/Donut3D

  17. render Where the fun happen

  18. None
  19. render d3.select("body") d3.select(elContainer) $(elContainer).empty(); Sample code use the same standard,

    variables names start by the type: “el” = element, “n” = number etc.
  20. Paste the code for the 3D Donut directly inside “render”

    after the existing code Main change to use the provided container
  21. Random column just to be able to have a canvas

    My custom plugin Match perfectly the sample
  22. Easy, isn’t it? The plugin display a 3D donut, sure,

    but… • It doesn’t resize • It doesn’t display any real value coming from DVD • It doesn’t react to anything Keeping it short: we have a nice but useless plugin ! And now it’s where the painful part starts …
  23. • • var nWidth = $(elContainer).width(); var nHeight = $(elContainer).height();

    nWidth nHeight • resizeVisualization • _render • _render resizeVisualization • render _render
  24. Triggered on resize Empty function calling the new _render New

    “render” function No formal doc, found the code in a tutorial…
  25. Figures are still random, they change at each call of

    _render
  26. • • • • If there was a clear formal

    doc I could tell you exactly what it is and how it works … As there isn’t one, I can just “guess” based on samples and pieces of code
  27. getEdgeExtent getItemEndSlice • • • getValue getNumberValue Column 1 Column

    2 Column 3 # row A A1 10 0 A2 25 1 A3 5 2 B B1 2 3 B2 6 4 B3 8 5 C C1 15 6 layers
  28. None
  29. None
  30. var color = d3.scale.category20(); color(i) i color(i) If there was

    a doc I could probably ask DVD to gives me colours for the values to keep them in sync with other canvas, but there isn’t one …
  31. None
  32. Let’s stop here with a custom plugin development… A lot

    more should/could be done (colours, legend, interactions etc.) • The lack of documentation is clearly not helping • Lot of functions exists (look for a file named “report_base.js” and enjoy finding nice interesting things inside) • It is extremely time consuming
  33. • • • • • • • •

  34. • • • •

  35. • • • • • (remember I said DVD is

    more similar to OBIEE than what you could imagine?)
  36. None
  37. None
  38. None
  39. None
  40. • • • • •

  41. None
  42. • • • • • • •

  43. None
  44. • • • • • •

  45. None
  46. None
  47. None
  48. • • • • • •

  49. None
  50. None
  51. • I’m not telling you it’s the case I’m not

    telling you to find a way to do it that way I’m just expressing a “theoretical” possibility…
  52. None
  53. None