allfro / canari

Local and Remote Maltego Rapid Transform Development Framework
http://www.canariproject.com
102 stars 27 forks source link

Remote exception code #54

Closed erangden closed 9 years ago

erangden commented 9 years ago

I couldn't figure out a way to make plume return a 600 coded maltego exception as mentioned in http://dev.paterva.com/developer/advanced/transform_hub.php. I tried to use croak for this, but unsuccessfully. The following changes should allow you to customize a return exception in the transform.

allfro commented 9 years ago

Cool. I'll take a look at the PR. Must be a new protocol enhancement. Typically you need to throw an Exception from do_transform in order for it to show an exception. I had no idea they started adding the 600 code.

On Tuesday, 20 October 2015, erangden notifications@github.com wrote:

I couldn't figure out a way to make plume return a 600 coded maltego exception as mentioned in http://dev.paterva.com/developer/advanced/transform_hub.php. I tried to use croak for this, but unsuccessfully. The following changes should allow

you to customize a return exception in the transform.

You can view, comment on, or merge this pull request online at:

https://github.com/allfro/canari/pull/54 Commit Summary

  • allow custom maltegoExceptions from plume
  • allow error code attribute on maltegoException

File Changes

Patch Links:

— Reply to this email directly or view it on GitHub https://github.com/allfro/canari/pull/54.

allfro commented 9 years ago

So the error code addition to the xml object is fine but the other commit is unnecessary. You can raise an exception by doing raise MaltegoException("your msg", code=600)

On Tuesday, 20 October 2015, erangden notifications@github.com wrote:

I couldn't figure out a way to make plume return a 600 coded maltego exception as mentioned in http://dev.paterva.com/developer/advanced/transform_hub.php. I tried to use croak for this, but unsuccessfully. The following changes should allow

you to customize a return exception in the transform.

You can view, comment on, or merge this pull request online at:

https://github.com/allfro/canari/pull/54 Commit Summary

  • allow custom maltegoExceptions from plume
  • allow error code attribute on maltegoException

File Changes

Patch Links:

— Reply to this email directly or view it on GitHub https://github.com/allfro/canari/pull/54.

erangden commented 9 years ago

Thanks for the info. I'll change the commit and force push.

erangden commented 9 years ago

New commit. Mergeable like that?