<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Hashing DWG files - empty models don't receive the same hash code in AutoCAD Forum</title>
    <link>https://forums.autodesk.com/t5/autocad-forum/hashing-dwg-files-empty-models-don-t-receive-the-same-hash-code/m-p/9644092#M99738</link>
    <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/1717597"&gt;@tim_crouse&lt;/a&gt;&lt;/P&gt;&lt;P&gt;I managed to compute a human-readable byte array by using the DXF file format. Just like you said, the amount of time spend in the drawing is also saved into the byte array. In addition, the $FINGERPRINTGUID also differs:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;$TDCREATE&lt;BR /&gt;40&lt;BR /&gt;2459045.493807870&lt;BR /&gt;9&lt;BR /&gt;$TDUCREATE&lt;BR /&gt;40&lt;BR /&gt;2459045.410474537&lt;BR /&gt;9&lt;BR /&gt;$TDUPDATE&lt;BR /&gt;40&lt;BR /&gt;2459050.246168982&lt;BR /&gt;9&lt;BR /&gt;$TDUUPDATE&lt;BR /&gt;40&lt;BR /&gt;2459050.162835648&lt;BR /&gt;9&lt;BR /&gt;$TDINDWG&lt;BR /&gt;40&lt;BR /&gt;0.0003935185&lt;BR /&gt;9&lt;BR /&gt;$TDUSRTIMER&lt;BR /&gt;40&lt;BR /&gt;0.0003935185&lt;BR /&gt;9&lt;BR /&gt;$USRTIMER&lt;BR /&gt;70&lt;BR /&gt;1&lt;BR /&gt;9&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I believe it wouldn't suffice to just delete/ignore these lines in the byte array, because a different view/orientation of the same model would lead to changes in the byte array? With that, it will be quite hard to use hash codes to determine identical looking models.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;When just copying and pasting a basic 3D model, the hash will be identical.&lt;/P&gt;</description>
    <pubDate>Mon, 20 Jul 2020 08:44:50 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2020-07-20T08:44:50Z</dc:date>
    <item>
      <title>Hashing DWG files - empty models don't receive the same hash code</title>
      <link>https://forums.autodesk.com/t5/autocad-forum/hashing-dwg-files-empty-models-don-t-receive-the-same-hash-code/m-p/9638605#M99733</link>
      <description>&lt;DIV class="postcell post-layout--right"&gt;&lt;DIV class="post-text"&gt;&lt;P&gt;I want to use a hash function (SHA1) to determine whether two DWG models from AutoCAD 2018 are identical or not. To test if this works, I created two empty dwg files and used the SHA1 function in c# (System.Security.Cryptography.sha1) to calculate the hash code.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I was expecting resulting codes to be identical, since I only started two new empty models and then saved them directly. The only data which should differ is the name and date &amp;amp; time of creation (all meta data, which shouldn't play a role for the algorithm). Yet, the result was two different hash codes.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So I looked into the byte array of the two files. The only thing I could get out of it (a lot of lines which I could not interpret in any way), was that some of the meta data as date and time of creation is written in the byte array. Therefore the two files are actually not identical, eventhough the models are. So there will always be a different hash code for all hashed DWG models.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Does anyone know of this problem or a work-around for my issue?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Snippet of the byte array in which the saving time and date is captured:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;A p p I n f o D a t a L i s t �H��&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;P&gt;M��ρ��P� 2 2 . 0 . 4 9 . 0 . 0 ���%�דI����(o��r A u t o d e s k D W G . T h i s f i l e i s a T r u s t e d D W G l a s t s a v e d b y a n A u t o d e s k a p p l i c a t i o n o r A u t o d e s k l i c e n s e d a p p l i c a t i o n . �����Oh�� +'��J&amp;lt; p r o p _ s e t f m t _ i d = " { f 2 9 f 8 5 e 0 - 4 f f 9 - 1 0 6 8 - a b 9 1 - 0 8 0 0 2 b 2 7 b 3 d 9 } " &amp;gt; &amp;lt; p r o p i d = " 8 " &amp;gt; &amp;lt; s t r i n g &amp;gt; M a x &amp;lt; / s t r i n g &amp;gt; &amp;lt; / p r o p &amp;gt; &amp;lt; p r o p i d = " 1 0 " &amp;gt; &amp;lt; d a t e t i m e &amp;gt; 2 0 2 0 - 0 7 - 1 4 T 0 9 : 5 1 : 3 3 &amp;lt; / d a t e t i m e &amp;gt; &amp;lt; / p r o p &amp;gt; &amp;lt; p r o p i d = " 2 5 8 " &amp;gt; &amp;lt; s t r i n g &amp;gt; A u t o C A D 2 0 1 8 &amp;lt; / s t r i n g &amp;gt; &amp;lt; / p r o p &amp;gt; &amp;lt; p r o p i d = " 2 5 9 " &amp;gt; &amp;lt; s t r i n g &amp;gt; O . 4 9 . 0 . 0 &amp;lt; / s t r i n g &amp;gt; &amp;lt; / p r o p &amp;gt; &amp;lt; p r o p i d = " 1 2 " &amp;gt; &amp;lt; d a t e t i m e &amp;gt; 2 0 2 0 - 0 7 - 1 4 T 0 9 : 5 1 : 2 9 &amp;lt; / d a t e t i m e &amp;gt; &amp;lt; / p r o p &amp;gt; &amp;lt; / p r o p _ s e t &amp;gt; ���Q�βD����;��D� " &amp;lt; P r o d u c t I n f o r m a t i o n n a m e = \ " A u t o C A D \ " b u i l d _ v e r s i o n = \ " O . 4 9 . 0 . 0 ( x 6 4 ) \ " r e g i s t r y _ v e r s i o n = \ " 2 2 . 0 \ " i n s t a l l _ i d _ s t r i n g = \ " A C A D - 1 0 0 1 : 4 0 9 \ " r e g i s t r y _ l o c a l e I D = \ " 1 0 3 3 \ " &amp;gt; "&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Thu, 16 Jul 2020 09:43:09 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/autocad-forum/hashing-dwg-files-empty-models-don-t-receive-the-same-hash-code/m-p/9638605#M99733</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2020-07-16T09:43:09Z</dc:date>
    </item>
    <item>
      <title>Re: Hashing DWG files - empty models don't receive the same hash code</title>
      <link>https://forums.autodesk.com/t5/autocad-forum/hashing-dwg-files-empty-models-don-t-receive-the-same-hash-code/m-p/9639888#M99734</link>
      <description>&lt;P&gt;Hashing can't be used. It's much more complex than that to figure out if they are equal.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 16 Jul 2020 19:48:23 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/autocad-forum/hashing-dwg-files-empty-models-don-t-receive-the-same-hash-code/m-p/9639888#M99734</guid>
      <dc:creator>JTBWorld</dc:creator>
      <dc:date>2020-07-16T19:48:23Z</dc:date>
    </item>
    <item>
      <title>Re: Hashing DWG files - empty models don't receive the same hash code</title>
      <link>https://forums.autodesk.com/t5/autocad-forum/hashing-dwg-files-empty-models-don-t-receive-the-same-hash-code/m-p/9642545#M99735</link>
      <description>&lt;P&gt;There are many ways to compare drawings. What is the purpose of this comparison?&lt;/P&gt;</description>
      <pubDate>Sat, 18 Jul 2020 16:45:54 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/autocad-forum/hashing-dwg-files-empty-models-don-t-receive-the-same-hash-code/m-p/9642545#M99735</guid>
      <dc:creator>RobDraw</dc:creator>
      <dc:date>2020-07-18T16:45:54Z</dc:date>
    </item>
    <item>
      <title>Re: Hashing DWG files - empty models don't receive the same hash code</title>
      <link>https://forums.autodesk.com/t5/autocad-forum/hashing-dwg-files-empty-models-don-t-receive-the-same-hash-code/m-p/9642632#M99736</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Although the objects in the drawings may be identical there are other unseen aspects that are not identical.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The first one that comes to mind is the metadata associated, one such piece is the amount of time spent in the drawing which will be different between the two drawings.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Although the HASH will be a tough way to determine duplicity as a basic test to test your concept would be to perform the operation on a copy of the drawing.&amp;nbsp; This could have some benefits, albeit not what you originally intended.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Best Regards&lt;/P&gt;&lt;P&gt;-Tim C.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 18 Jul 2020 19:08:57 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/autocad-forum/hashing-dwg-files-empty-models-don-t-receive-the-same-hash-code/m-p/9642632#M99736</guid>
      <dc:creator>tim_crouse</dc:creator>
      <dc:date>2020-07-18T19:08:57Z</dc:date>
    </item>
    <item>
      <title>Re: Hashing DWG files - empty models don't receive the same hash code</title>
      <link>https://forums.autodesk.com/t5/autocad-forum/hashing-dwg-files-empty-models-don-t-receive-the-same-hash-code/m-p/9644077#M99737</link>
      <description>&lt;P&gt;I wanted to create a table of all past versions/variants of some projects. To be able to assign the versions in the table to the 3D models afterwards, I thought of using a hash code.&lt;/P&gt;</description>
      <pubDate>Mon, 20 Jul 2020 08:30:55 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/autocad-forum/hashing-dwg-files-empty-models-don-t-receive-the-same-hash-code/m-p/9644077#M99737</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2020-07-20T08:30:55Z</dc:date>
    </item>
    <item>
      <title>Re: Hashing DWG files - empty models don't receive the same hash code</title>
      <link>https://forums.autodesk.com/t5/autocad-forum/hashing-dwg-files-empty-models-don-t-receive-the-same-hash-code/m-p/9644092#M99738</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/1717597"&gt;@tim_crouse&lt;/a&gt;&lt;/P&gt;&lt;P&gt;I managed to compute a human-readable byte array by using the DXF file format. Just like you said, the amount of time spend in the drawing is also saved into the byte array. In addition, the $FINGERPRINTGUID also differs:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;$TDCREATE&lt;BR /&gt;40&lt;BR /&gt;2459045.493807870&lt;BR /&gt;9&lt;BR /&gt;$TDUCREATE&lt;BR /&gt;40&lt;BR /&gt;2459045.410474537&lt;BR /&gt;9&lt;BR /&gt;$TDUPDATE&lt;BR /&gt;40&lt;BR /&gt;2459050.246168982&lt;BR /&gt;9&lt;BR /&gt;$TDUUPDATE&lt;BR /&gt;40&lt;BR /&gt;2459050.162835648&lt;BR /&gt;9&lt;BR /&gt;$TDINDWG&lt;BR /&gt;40&lt;BR /&gt;0.0003935185&lt;BR /&gt;9&lt;BR /&gt;$TDUSRTIMER&lt;BR /&gt;40&lt;BR /&gt;0.0003935185&lt;BR /&gt;9&lt;BR /&gt;$USRTIMER&lt;BR /&gt;70&lt;BR /&gt;1&lt;BR /&gt;9&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I believe it wouldn't suffice to just delete/ignore these lines in the byte array, because a different view/orientation of the same model would lead to changes in the byte array? With that, it will be quite hard to use hash codes to determine identical looking models.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;When just copying and pasting a basic 3D model, the hash will be identical.&lt;/P&gt;</description>
      <pubDate>Mon, 20 Jul 2020 08:44:50 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/autocad-forum/hashing-dwg-files-empty-models-don-t-receive-the-same-hash-code/m-p/9644092#M99738</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2020-07-20T08:44:50Z</dc:date>
    </item>
    <item>
      <title>Re: Hashing DWG files - empty models don't receive the same hash code</title>
      <link>https://forums.autodesk.com/t5/autocad-forum/hashing-dwg-files-empty-models-don-t-receive-the-same-hash-code/m-p/9644287#M99739</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;@Anonymous&amp;nbsp;wrote:&lt;BR /&gt;&lt;P&gt;I wanted to create a table of all past versions/variants of some projects. To be able to assign the versions in the table to the 3D models afterwards,&amp;nbsp;&lt;/P&gt;&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;That sounds different from your original question about checking to see if they are duplicates.&lt;/P&gt;</description>
      <pubDate>Mon, 20 Jul 2020 11:09:28 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/autocad-forum/hashing-dwg-files-empty-models-don-t-receive-the-same-hash-code/m-p/9644287#M99739</guid>
      <dc:creator>RobDraw</dc:creator>
      <dc:date>2020-07-20T11:09:28Z</dc:date>
    </item>
    <item>
      <title>Re: Hashing DWG files - empty models don't receive the same hash code</title>
      <link>https://forums.autodesk.com/t5/autocad-forum/hashing-dwg-files-empty-models-don-t-receive-the-same-hash-code/m-p/9644725#M99740</link>
      <description>&lt;P&gt;Version control is best handled with a proper EDMS, such as Vault, Projectwise, or Adept.&lt;/P&gt;</description>
      <pubDate>Mon, 20 Jul 2020 14:59:09 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/autocad-forum/hashing-dwg-files-empty-models-don-t-receive-the-same-hash-code/m-p/9644725#M99740</guid>
      <dc:creator>dgorsman</dc:creator>
      <dc:date>2020-07-20T14:59:09Z</dc:date>
    </item>
  </channel>
</rss>

