I'm playing around with Maltego for target recon and investigation, and have started writing my own transforms in Python. Unfortunately, the current developer documentation is a little light on details, and I'm having to guess a lot of it.

Are there any decent resources on writing Maltego transforms, or any useful sample transforms that do more than a "Hello world" example? I'm especially interested in samples that demonstrate the various data types on entity parameters, since I just spent an hour trying to figure out how datetime was meant to be formatted.

1 Answer 1


You might want to take a look at the Canari Framework (https://www.canariproject.com/4-3-transform-development-quick-start/). It's an awesomely simple transform development framework that let's you do some pretty rad things ;).


Canari now has some additional support for complex field types. So far we've added datetime, timespan, color, and date. You can design an entity like so:

@EntityField(name='mydate', type=EntityFieldType.Date)
@EntityField(name='mydatetime', type=EntityFieldType.DateTime)
@EntityField(name='mytimespan', type=EntityFieldType.TimeSpan)
@EntityField(name='mycolor', type=EntityFieldType.Color)
class MyEntity(Entity):

And use it like so:

import datetime
e = MyEntity('value')
e.mydate = datetime.date.today()
# ... etc.

Hope this helps! Support for array types and other things coming soon. Also, if you are curious how to format things, simply design an Entity in Maltego with the various field types and see how it renders the property values in the property editor once you drag your entity onto the graph.

  • Didn't know you had an account on here Nadeem! Cheers for this. Still interested in more details on how various data types are used in raw transforms though.
    – Polynomial
    Feb 3, 2013 at 17:30
  • As for the raw data types this might be a space that might need some improvement in Canari. There is some support for some of the primitives like String, Integer, Float, Enums, etc. in Canari. Take a look at the canari.maltego.entities package in the project to see how they come into play. I will have to add support for the other stuff. That stuff is still unknown and might be a good side-project :) Feb 3, 2013 at 18:36

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .