SlideShare a Scribd company logo
1 of 69
Download to read offline
@mscottford
BUILDING A BRIDGE TO
@mscottford
BY M. SCOTT FORD
CO-FOUNDER & CHIEF CODE WHISPERER, CORGIBYTES
HOW HARD COULD THAT BE?
A LEGACY APPLICATION
@mscottford
ABOUT ME
@mscottford
@mscottford@mscottford
CHIEF CODE WHISPERER
CO-FOUNDER AND
@mscottford
THIS IS A STORY
@mscottford
VENDORS
APICLIENTS
GAMMA
DELTA
BETA
ALPHA
THE ARCHITECTURE
@mscottford
VENDORS
API
ALPHA
TYPICAL INTEGRATION
CONNECTOR
VENDOR
SDK
VENDOR
SYSTEM
@mscottford
VENDORS
API
TARGET
TARGET INTEGRATION
CONNECTOR
TARGET
SYSTEM
??
NO SDK
@mscottford
WHAT DID WE KNOW?
TARGET SYSTEM
SERVICE
ON PREMISES
CLIENT UI
DATABASE
ADMIN UI
• Target system ran on Windows 7 desktop
• Data was stored in some form of database on the desktop
@mscottford
OPTIONS
TARGET SYSTEM
SERVICE
ON PREMISES
CLIENT UI
DATABASE
ADMIN UI
@mscottford
OPTIONS
TARGET SYSTEM
SERVICE
ON PREMISES
CLIENT UI
DATABASE
ADMIN UI
• Find an undocumented SDK
@mscottford
OPTIONS
TARGET SYSTEM
SERVICE
ON PREMISES
CLIENT UI
DATABASE
ADMIN UI
• Find an undocumented SDK
• Find libraries for
communicating with DB
@mscottford
OPTIONS
TARGET SYSTEM
SERVICE
ON PREMISES
CLIENT UI
DATABASE
ADMIN UI
• Find an undocumented SDK
• Find libraries for
communicating with DB
• Screen scrape the UI
@mscottford
OPTIONS
TARGET SYSTEM
SERVICE
ON PREMISES
CLIENT UI
DATABASE
ADMIN UI
• Find an undocumented SDK
• Find libraries for
communicating with DB
• Screen scrape the UI
• Reverse engineer DB file format
@mscottford
OPTIONS
TARGET SYSTEM
SERVICE
ON PREMISES
CLIENT UI
DATABASE
ADMIN UI
• Find an undocumented SDK
• Find libraries for
communicating with DB
• Screen scrape the UI
• Reverse engineer DB file format
@mscottford
PLAN OF ATTACK
Reverse engineer DB file format
Find libraries for communicating with DB
@mscottford
@mscottford
PLAN OF ATTACK
Reverse engineer DB file format
Find libraries for communicating with DB
Find an undocumented SDK
@mscottford
@mscottford
PLAN OF ATTACK
Reverse engineer DB file format
Find libraries for communicating with DB
Find an undocumented SDK
@mscottford
@mscottford
PLAN OF ATTACK
Reverse engineer DB file format
Find libraries for communicating with DB
Find an undocumented SDK
@mscottford
@mscottford
MAYBE THERE’S AN SDK
@mscottford
THE HUNT FOR AN SDK
@mscottford
@mscottford
THE HUNT FOR AN SDK
•Visually skimmed installation directory looking for
anything obvious
@mscottford
@mscottford
THE HUNT FOR AN SDK
•Visually skimmed installation directory looking for
anything obvious
•Found evidence of very old tooling - some .EXEs had
default icon from old versions of Visual C++
@mscottford
@mscottford
THE HUNT FOR AN SDK
•Visually skimmed installation directory looking for
anything obvious
•Found evidence of very old tooling - some .EXEs had
default icon from old versions of Visual C++
•Ran dumpbin on all DLLs for any callable functions
@mscottford
@mscottford
THE HUNT FOR AN SDK
•Visually skimmed installation directory looking for
anything obvious
•Found evidence of very old tooling - some .EXEs had
default icon from old versions of Visual C++
•Ran dumpbin on all DLLs for any callable functions
•Nothing obvious found
@mscottford
@mscottford
MAYBE THE DB IS OFF THE SHELF
@mscottford
FIND THE DB ACCESS DLL
@mscottford
@mscottford
FIND THE DB ACCESS DLL
•Looked for evidence of commercially available
database (you name it we looked) – found none
@mscottford
@mscottford
FIND THE DB ACCESS DLL
•Looked for evidence of commercially available
database (you name it we looked) – found none
•Looked though dumpbin output for data access
functions we could call
@mscottford
@mscottford
FIND THE DB ACCESS DLL
•Looked for evidence of commercially available
database (you name it we looked) – found none
•Looked though dumpbin output for data access
functions we could call
•Decompiled a few .NET DLLs
@mscottford
@mscottford
FIND THE DB ACCESS DLL
•Looked for evidence of commercially available
database (you name it we looked) – found none
•Looked though dumpbin output for data access
functions we could call
•Decompiled a few .NET DLLs
•Nothing obvious found
@mscottford
@mscottford
YAY! REVERSE ENGINEERING TIME!
@mscottford
REVERSE ENGINEERING DB
@mscottford
@mscottford
REVERSE ENGINEERING DB
•Find the files
@mscottford
@mscottford
REVERSE ENGINEERING DB
•Find the files
–Made a small change in the admin UI
@mscottford
@mscottford
REVERSE ENGINEERING DB
•Find the files
–Made a small change in the admin UI
–Sorted files by date modified
@mscottford
@mscottford
REVERSE ENGINEERING DB
•Find the files
–Made a small change in the admin UI
–Sorted files by date modified
–Got lucky! Only one file, a .BIN
@mscottford
@mscottford
REVERSE ENGINEERING DB
•Find the files
–Made a small change in the admin UI
–Sorted files by date modified
–Got lucky! Only one file, a .BIN
•Open our favorite hex editor Synalyze It!
@mscottford
@mscottford
SYNALYZE IT!
@mscottford
@mscottford
REVERSE ENGINEERING DB
@mscottford
@mscottford
REVERSE ENGINEERING DB
•Search for strings
–Found tables names – including “btree”
@mscottford
@mscottford
REVERSE ENGINEERING DB
•Search for strings
–Found tables names – including “btree”
•Look for patterns in the file
–Map them out in Synalyze It!
@mscottford
@mscottford
TIME FOR THE GRIND
@mscottford
@mscottford
THE GRIND
@mscottford
@mscottford
THE GRIND
•Make a change in the UI (mostly via client UI)
@mscottford
@mscottford
THE GRIND
•Make a change in the UI (mostly via client UI)
•Diff before and after
@mscottford
@mscottford
THE GRIND
•Make a change in the UI (mostly via client UI)
•Diff before and after
•Mark location in Synalize It
@mscottford
@mscottford
THE GRIND
•Make a change in the UI (mostly via client UI)
•Diff before and after
•Mark location in Synalize It
•Repeat
@mscottford
@mscottford
THE GRIND
•Make a change in the UI (mostly via client UI)
•Diff before and after
•Mark location in Synalize It
•Repeat
•Only focus on data that we need
@mscottford
@mscottford
BUILD THE CONNECTOR
@mscottford
@mscottford
BUILDING THE CONNECTOR
@mscottford
@mscottford
BUILDING THE CONNECTOR
•Only implement read commands
@mscottford
@mscottford
BUILDING THE CONNECTOR
•Only implement read commands
•Delay read/write until after demo
@mscottford
@mscottford
BUILDING THE CONNECTOR
•Only implement read commands
•Delay read/write until after demo
•Come up with some ideas about how to avoid conflicts
when write is implemented
@mscottford
@mscottford
VENDORS
API
TARGET
TARGET INTEGRATION
CONNECTOR
TARGET
SYSTEM
CUSTOM
SDK
@mscottford
TIME TO DEMO TO THE CLIENT
@mscottford
@mscottford
THE DEMO
@mscottford
@mscottford
THE DEMO
•CTO of vendor was present at the demo
@mscottford
@mscottford
THE DEMO
•CTO of vendor was present at the demo
•They were alarmed by the fact that it was working
@mscottford
@mscottford
THE DEMO
•CTO of vendor was present at the demo
•They were alarmed by the fact that it was working
•Turns out there was an SDK after all
@mscottford
@mscottford
THE DEMO
•CTO of vendor was present at the demo
•They were alarmed by the fact that it was working
•Turns out there was an SDK after all
•When they found out we had plans for read/write
support, their department handed it over
@mscottford
@mscottford
BUMMER
@mscottford
@mscottford
NOT SO FAST
@mscottford
@mscottford
NOT SO FAST
•We learned a lot
@mscottford
@mscottford
NOT SO FAST
•We learned a lot
•We had a ton of fun
@mscottford
@mscottford
NOT SO FAST
•We learned a lot
•We had a ton of fun
•Our work led to the best possible solution being
uncovered
@mscottford
@mscottford
NOT SO FAST
•We learned a lot
•We had a ton of fun
•Our work led to the best possible solution being
uncovered
•A read/write implementation would have been risky
@mscottford
@mscottford
CONTACT INFO
@mscottford
@corgibytes
corgibytes.com
LegacyCode.Rocks
@mscottford
QUESTIONS?
@mscottford
CONTACT INFO
@mscottford
@corgibytes
corgibytes.com
LegacyCode.Rocks

More Related Content

Similar to Building a Bridge to a Legacy Application: How Hard Can That Be?

SH 1 - SES 4 - Microservices - Andrew Morgan TLV.pptx
SH 1 - SES 4 - Microservices - Andrew Morgan TLV.pptxSH 1 - SES 4 - Microservices - Andrew Morgan TLV.pptx
SH 1 - SES 4 - Microservices - Andrew Morgan TLV.pptx
MongoDB
 
How We Fixed Our MongoDB Problems
How We Fixed Our MongoDB Problems How We Fixed Our MongoDB Problems
How We Fixed Our MongoDB Problems
MongoDB
 

Similar to Building a Bridge to a Legacy Application: How Hard Can That Be? (20)

Building A SaaS with CoreOS, Docker, and Etcd
Building A SaaS with CoreOS, Docker, and EtcdBuilding A SaaS with CoreOS, Docker, and Etcd
Building A SaaS with CoreOS, Docker, and Etcd
 
SH 1 - SES 4 - Microservices - Andrew Morgan TLV.pptx
SH 1 - SES 4 - Microservices - Andrew Morgan TLV.pptxSH 1 - SES 4 - Microservices - Andrew Morgan TLV.pptx
SH 1 - SES 4 - Microservices - Andrew Morgan TLV.pptx
 
Powering Microservices with Docker, Kubernetes, Kafka, and MongoDB
Powering Microservices with Docker, Kubernetes, Kafka, and MongoDBPowering Microservices with Docker, Kubernetes, Kafka, and MongoDB
Powering Microservices with Docker, Kubernetes, Kafka, and MongoDB
 
Philly CocoaHeads 20160414 - Building Your App SDK With Swift
Philly CocoaHeads 20160414 - Building Your App SDK With SwiftPhilly CocoaHeads 20160414 - Building Your App SDK With Swift
Philly CocoaHeads 20160414 - Building Your App SDK With Swift
 
Serverless architectures
Serverless architecturesServerless architectures
Serverless architectures
 
Serverless architectures
Serverless architecturesServerless architectures
Serverless architectures
 
PHP is the king, nodejs is the prince and Python is the fool - Alessandro Cin...
PHP is the king, nodejs is the prince and Python is the fool - Alessandro Cin...PHP is the king, nodejs is the prince and Python is the fool - Alessandro Cin...
PHP is the king, nodejs is the prince and Python is the fool - Alessandro Cin...
 
PHP is the King, nodejs the prince and python the fool
PHP is the King, nodejs the prince and python the foolPHP is the King, nodejs the prince and python the fool
PHP is the King, nodejs the prince and python the fool
 
How We Fixed Our MongoDB Problems
How We Fixed Our MongoDB Problems How We Fixed Our MongoDB Problems
How We Fixed Our MongoDB Problems
 
Design for scale
Design for scaleDesign for scale
Design for scale
 
Velociraptor - SANS Summit 2019
Velociraptor - SANS Summit 2019Velociraptor - SANS Summit 2019
Velociraptor - SANS Summit 2019
 
Why Markdown?
Why Markdown?Why Markdown?
Why Markdown?
 
Prepare to defend thyself with Blue/Green
Prepare to defend thyself with Blue/GreenPrepare to defend thyself with Blue/Green
Prepare to defend thyself with Blue/Green
 
All Day DevOps 2016 Fabian - Defending Thyself with Blue Green
All Day DevOps 2016 Fabian - Defending Thyself with Blue GreenAll Day DevOps 2016 Fabian - Defending Thyself with Blue Green
All Day DevOps 2016 Fabian - Defending Thyself with Blue Green
 
Lets have a look at Apple's Metal Framework
Lets have a look at Apple's Metal FrameworkLets have a look at Apple's Metal Framework
Lets have a look at Apple's Metal Framework
 
Kubernetes and AWS Lambda can play nicely together
Kubernetes and AWS Lambda can play nicely togetherKubernetes and AWS Lambda can play nicely together
Kubernetes and AWS Lambda can play nicely together
 
Jumpstart: Your Introduction To MongoDB
Jumpstart: Your Introduction To MongoDBJumpstart: Your Introduction To MongoDB
Jumpstart: Your Introduction To MongoDB
 
From Android NDK To AOSP
From Android NDK To AOSPFrom Android NDK To AOSP
From Android NDK To AOSP
 
NoSQL Couchbase Lite & BigData HPCC Systems
NoSQL Couchbase Lite & BigData HPCC SystemsNoSQL Couchbase Lite & BigData HPCC Systems
NoSQL Couchbase Lite & BigData HPCC Systems
 
End to End .NET Development on Mac
End to End .NET Development on MacEnd to End .NET Development on Mac
End to End .NET Development on Mac
 

More from M. Scott Ford

Communication is Just as Important as Code
Communication is Just as Important as CodeCommunication is Just as Important as Code
Communication is Just as Important as Code
M. Scott Ford
 

More from M. Scott Ford (10)

Lessons Learned Migrating from Jekyll to Next.pptx
Lessons Learned Migrating from Jekyll to Next.pptxLessons Learned Migrating from Jekyll to Next.pptx
Lessons Learned Migrating from Jekyll to Next.pptx
 
PyGeekle 2022 - A Deep Dive into Measuring Dependency Freshness with LibYear
PyGeekle 2022 - A Deep Dive into Measuring Dependency Freshness with LibYearPyGeekle 2022 - A Deep Dive into Measuring Dependency Freshness with LibYear
PyGeekle 2022 - A Deep Dive into Measuring Dependency Freshness with LibYear
 
Communication is Just as Important as Code
Communication is Just as Important as CodeCommunication is Just as Important as Code
Communication is Just as Important as Code
 
MenderCon 2021 - Keynote
MenderCon 2021 - KeynoteMenderCon 2021 - Keynote
MenderCon 2021 - Keynote
 
Moving a Monolith to Kubernetes
Moving a Monolith to KubernetesMoving a Monolith to Kubernetes
Moving a Monolith to Kubernetes
 
MenderCon 2020 Keynote Presentation
MenderCon 2020 Keynote PresentationMenderCon 2020 Keynote Presentation
MenderCon 2020 Keynote Presentation
 
Makers and menders - Finding Talent for Legacy Code Projects
Makers and menders - Finding Talent for Legacy Code ProjectsMakers and menders - Finding Talent for Legacy Code Projects
Makers and menders - Finding Talent for Legacy Code Projects
 
A deep dive into measuring dependency freshness with lib year
A deep dive into measuring dependency freshness with lib yearA deep dive into measuring dependency freshness with lib year
A deep dive into measuring dependency freshness with lib year
 
Embracing the Red Bar: A Technique for Safely Refactoring Your Test Suite
Embracing the Red Bar: A Technique for Safely Refactoring Your Test SuiteEmbracing the Red Bar: A Technique for Safely Refactoring Your Test Suite
Embracing the Red Bar: A Technique for Safely Refactoring Your Test Suite
 
Old Code, New Tricks
Old Code, New TricksOld Code, New Tricks
Old Code, New Tricks
 

Recently uploaded

%+27788225528 love spells in Knoxville Psychic Readings, Attraction spells,Br...
%+27788225528 love spells in Knoxville Psychic Readings, Attraction spells,Br...%+27788225528 love spells in Knoxville Psychic Readings, Attraction spells,Br...
%+27788225528 love spells in Knoxville Psychic Readings, Attraction spells,Br...
masabamasaba
 
%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...
%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...
%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...
masabamasaba
 
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
masabamasaba
 
Abortion Pill Prices Boksburg [(+27832195400*)] 🏥 Women's Abortion Clinic in ...
Abortion Pill Prices Boksburg [(+27832195400*)] 🏥 Women's Abortion Clinic in ...Abortion Pill Prices Boksburg [(+27832195400*)] 🏥 Women's Abortion Clinic in ...
Abortion Pill Prices Boksburg [(+27832195400*)] 🏥 Women's Abortion Clinic in ...
Medical / Health Care (+971588192166) Mifepristone and Misoprostol tablets 200mg
 

Recently uploaded (20)

Direct Style Effect Systems - The Print[A] Example - A Comprehension Aid
Direct Style Effect Systems -The Print[A] Example- A Comprehension AidDirect Style Effect Systems -The Print[A] Example- A Comprehension Aid
Direct Style Effect Systems - The Print[A] Example - A Comprehension Aid
 
AI & Machine Learning Presentation Template
AI & Machine Learning Presentation TemplateAI & Machine Learning Presentation Template
AI & Machine Learning Presentation Template
 
WSO2CON 2024 - API Management Usage at La Poste and Its Impact on Business an...
WSO2CON 2024 - API Management Usage at La Poste and Its Impact on Business an...WSO2CON 2024 - API Management Usage at La Poste and Its Impact on Business an...
WSO2CON 2024 - API Management Usage at La Poste and Its Impact on Business an...
 
%+27788225528 love spells in Knoxville Psychic Readings, Attraction spells,Br...
%+27788225528 love spells in Knoxville Psychic Readings, Attraction spells,Br...%+27788225528 love spells in Knoxville Psychic Readings, Attraction spells,Br...
%+27788225528 love spells in Knoxville Psychic Readings, Attraction spells,Br...
 
WSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital Transformation
WSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital TransformationWSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital Transformation
WSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital Transformation
 
%in ivory park+277-882-255-28 abortion pills for sale in ivory park
%in ivory park+277-882-255-28 abortion pills for sale in ivory park %in ivory park+277-882-255-28 abortion pills for sale in ivory park
%in ivory park+277-882-255-28 abortion pills for sale in ivory park
 
%in tembisa+277-882-255-28 abortion pills for sale in tembisa
%in tembisa+277-882-255-28 abortion pills for sale in tembisa%in tembisa+277-882-255-28 abortion pills for sale in tembisa
%in tembisa+277-882-255-28 abortion pills for sale in tembisa
 
MarTech Trend 2024 Book : Marketing Technology Trends (2024 Edition) How Data...
MarTech Trend 2024 Book : Marketing Technology Trends (2024 Edition) How Data...MarTech Trend 2024 Book : Marketing Technology Trends (2024 Edition) How Data...
MarTech Trend 2024 Book : Marketing Technology Trends (2024 Edition) How Data...
 
WSO2CON 2024 Slides - Unlocking Value with AI
WSO2CON 2024 Slides - Unlocking Value with AIWSO2CON 2024 Slides - Unlocking Value with AI
WSO2CON 2024 Slides - Unlocking Value with AI
 
%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...
%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...
%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...
 
Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...
Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...
Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...
 
%in Soweto+277-882-255-28 abortion pills for sale in soweto
%in Soweto+277-882-255-28 abortion pills for sale in soweto%in Soweto+277-882-255-28 abortion pills for sale in soweto
%in Soweto+277-882-255-28 abortion pills for sale in soweto
 
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
 
What Goes Wrong with Language Definitions and How to Improve the Situation
What Goes Wrong with Language Definitions and How to Improve the SituationWhat Goes Wrong with Language Definitions and How to Improve the Situation
What Goes Wrong with Language Definitions and How to Improve the Situation
 
VTU technical seminar 8Th Sem on Scikit-learn
VTU technical seminar 8Th Sem on Scikit-learnVTU technical seminar 8Th Sem on Scikit-learn
VTU technical seminar 8Th Sem on Scikit-learn
 
WSO2Con2024 - Hello Choreo Presentation - Kanchana
WSO2Con2024 - Hello Choreo Presentation - KanchanaWSO2Con2024 - Hello Choreo Presentation - Kanchana
WSO2Con2024 - Hello Choreo Presentation - Kanchana
 
Abortion Pill Prices Boksburg [(+27832195400*)] 🏥 Women's Abortion Clinic in ...
Abortion Pill Prices Boksburg [(+27832195400*)] 🏥 Women's Abortion Clinic in ...Abortion Pill Prices Boksburg [(+27832195400*)] 🏥 Women's Abortion Clinic in ...
Abortion Pill Prices Boksburg [(+27832195400*)] 🏥 Women's Abortion Clinic in ...
 
WSO2CON 2024 - Navigating API Complexity: REST, GraphQL, gRPC, Websocket, Web...
WSO2CON 2024 - Navigating API Complexity: REST, GraphQL, gRPC, Websocket, Web...WSO2CON 2024 - Navigating API Complexity: REST, GraphQL, gRPC, Websocket, Web...
WSO2CON 2024 - Navigating API Complexity: REST, GraphQL, gRPC, Websocket, Web...
 
BUS PASS MANGEMENT SYSTEM USING PHP.pptx
BUS PASS MANGEMENT SYSTEM USING PHP.pptxBUS PASS MANGEMENT SYSTEM USING PHP.pptx
BUS PASS MANGEMENT SYSTEM USING PHP.pptx
 
WSO2CON 2024 - Building the API First Enterprise – Running an API Program, fr...
WSO2CON 2024 - Building the API First Enterprise – Running an API Program, fr...WSO2CON 2024 - Building the API First Enterprise – Running an API Program, fr...
WSO2CON 2024 - Building the API First Enterprise – Running an API Program, fr...
 

Building a Bridge to a Legacy Application: How Hard Can That Be?