How to run an open source license compliance audit before licensing a private codebase
An open source license compliance audit before licensing a codebase identifies every third-party component, its license and how it entered the repositories, then confirms the company wrote or owns the rest. A fractional CTO runs it as a dependency scan, snippet and history review, authorship check and exclusion list, so only company-owned code is offered for review.
What the audit has to prove
The audit answers one question for the company's counsel and for SourceX's rights review: which parts of the codebase the company can license, and which parts must be carved out. That is a different question from ordinary product compliance. Shipping software asks whether the product honors its dependencies' licenses; licensing a repository for AI training asks whether the company has the right to license the text of each file, its full history and the engineering records around it.
Buyers care because commit history, pull requests, review threads and linked tickets show how engineers actually diagnose and fix problems, which is the record of work that coding agents are trained and evaluated on. Third-party code inside those repositories belongs to someone else, and unclear rights stop a deal at review. The US Copyright Office's report series on copyright and AI, whose training-focused part was released as a pre-publication version in May 2025, discusses licensing approaches for training material; treat it as context, not as law.
Prerequisites before you scan
- Read-only access to every Git host the company has used, including archived organizations and old self-hosted servers.
- A list of contractors, agencies and offshore teams that committed code, with their agreements.
- Any existing SBOM, open source policy or report from a prior financing or acquisition diligence.
- Client contracts, if the company builds software for customers, as IT services firms, agencies and custom development shops do.
- A software composition analysis (SCA) tool with snippet matching, and access to counsel who can interpret the results.
- The CEO's agreement that the audit is internal and that nothing leaves the company.
The audit, step by step
- Map repositories and history. Count repositories, languages, years of commit history, contributors and linked issue trackers. Include archived and forked repositories. Record metadata only.
- Run dependency SCA on every manifest. Generate an SBOM, in SPDX or CycloneDX format, for each repository so declared dependencies, versions and declared licenses are listed. Packages fetched at build time are usually not stored in the repository; vendored copies are.
- Hunt for vendored and copied code. Search folders named vendor, third-party, lib or external, minified bundles, checked-in binaries and license headers naming another copyright holder. Run snippet matching to catch code pasted from public projects or forums.
- Scan the whole history, not only the default branch. A file removed years ago still sits in Git history, and a license to the history includes it. Scan all branches and tags, or plan to offer a cleaned snapshot instead of full history.
- Build the license inventory. One row per component: name, location, detected license, how it entered (manifest, vendored copy or snippet) and the proposed action.
- Classify each row. Group results as permissive, weak copyleft, strong copyleft, network copyleft, commercial SDK, or unknown. Unknown is not permissive: code with no license grant gives you the fewest rights of all.
- Check authorship and assignment. The Copyright Office's Circular 30 on works made for hire explains that work an employee creates within the scope of employment belongs to the employer, while commissioned work qualifies only in specific statutory categories with a signed written agreement. Collect the IP assignment clause for every contractor and agency that committed code; gaps go on the exclusion list or get fixed with a written assignment.
- Screen for secrets, personal data and controlled technical data. Flag API keys, credentials, customer records in test fixtures or logs, and anything that may be export-controlled. The guide on ITAR and EAR technical data explains why that material stays out of a license.
- Write the exclusion list. Third-party directories, copyleft components counsel flags, client-owned code, controlled data and unassigned contractor work. Exclusions are normal; a well-documented core of company-owned code is what matters.
- Summarize on one page. Repositories in scope, years of history, contributor counts, exclusion categories and open questions for counsel. The CEO decides on this summary, not on the code.
How license categories translate into decisions
The category tells you which question to put to counsel. It does not answer it.
| Category | Common examples | Question for counsel | Usual handling in an audit |
|---|---|---|---|
| Permissive | MIT, BSD, Apache 2.0 | Do notice and attribution conditions follow the files into a license? | Often excluded as third-party code anyway |
| Weak copyleft | LGPL, MPL, EPL | Are the company's modifications its own work or derivatives? | Exclude the component; review modified files |
| Strong copyleft | GPL family | Has GPL code been mixed into the company's own files? | Exclude; flag mixed files for review |
| Network copyleft | AGPL | Do any services or tools embed it? | Exclude; review anything built around it |
| Commercial SDK | Licensed vendor libraries | Does the vendor license restrict disclosure or redistribution? | Exclude and check confidentiality terms |
| No license or unknown | Pasted snippets, abandoned forks | Who owns it, and can that be shown? | Treat as third-party and exclude |
Read each license text with counsel rather than relying on category labels; terms differ between versions.
Common mistakes and how to avoid them
| Mistake | Why it hurts | Fix |
|---|---|---|
| Scanning only the main branch | Deleted third-party files remain in history | Scan all refs, or offer a cleaned snapshot |
| Treating unlicensed code as free to use | Without a grant, the author keeps the rights | Exclude unknown-license code |
| Skipping contractor agreements | Commissioned code may not belong to the company | Collect assignments and exclude the gaps |
| Counting client deliverables | Service firms often assign code to their clients | Check client contracts and exclude client-owned work |
| Leaving secrets in history | Credentials and customer data travel with the history | Scan, rotate and agree redaction before any work |
| Sending the SBOM or repositories to a referral partner | Partners make introductions only | Keep every output inside the company |
Illustrative example
Illustrative: a fictional 140-person B2B accounting software company has eleven years of history across 64 repositories, plus Jira projects and code review threads. The fractional CTO's audit finds a vendored charting library, two GPL utilities copied into an internal tools repository, a payments SDK under a commercial license, and three years of work from an offshore agency whose contract contains a broad IP assignment. The exclusion list removes the vendored library, the GPL utilities and the SDK; the agency's work stays in scope once counsel confirms the assignment. The CEO reads the one-page summary and asks for an introduction. No code leaves the company until an agreement is signed and the company authorizes delivery.
Where the audit fits in an introduction
The audit is not a prerequisite for an introduction; it is what a well-prepared company brings to the rights review. A software company is a fit when it is US-based, has 50+ full-time employees at peak (contractors excluded) and several years of documented operations, holds the rights to what it would license, and has an owner, CEO, CFO or authorized representative to sponsor it. The who qualifies page sets out the full baseline, and the page for fractional CTOs covers how technical advisers raise licensing with a CEO.
The same preserve-before-change discipline applies beyond code, from CMMS migrations to call recording purges. Your role stays the same in each: introduce the company and give basic fit information. SourceX and the company handle the inventory, rights review, redaction terms, contracting and delivery, and de-identification and redaction requirements are agreed before any work begins.
Partners earn 25% of the eligible platform fees SourceX actually collects from the referred company's licensing deals, capped at $100,000 per referred company. Payment follows only after the buyer pays and SourceX receives its fee, and no reward is guaranteed. If you hold an advisory or board role, check your engagement terms on outside fees before registering.
This is general information, not legal, tax or financial advice. Confirm with your own counsel before acting on any license interpretation.
Next step
Start with step one: map the repositories and their history, metadata only. If the company fits, register as a partner to introduce it; the CEO can also start the company application at sourcex.si/apply with your referral link attached.
- Step 1Share your linkSend your personal link to a company you know.
- Step 2Company appliesThe company applies itself at /apply.
- Step 3Buyer selects and paysThe buyer selects and pays for the data and SourceX receives its fee.
- Step 4You get your rewardYour share of SourceX fees becomes payable.
Common questions
Does licensing code for AI training trigger copyleft obligations?
That depends on the license text and on whether the license counts as distributing the code, which is a question for counsel rather than a scanning tool. The practical approach most audits take is to exclude copyleft components entirely and review any company files that mixed copyleft code in, so the question never has to be answered for the licensed portion.
How long does an open source audit take for a mid-size codebase?
It depends on the number of repositories, the depth of history and how much code was vendored or pasted in. Dependency scans run quickly; the time goes into reviewing snippet matches, scanning old branches and collecting contractor agreements. Plan for the contractor paperwork to be the slowest part, since it often sits with finance or legal rather than engineering.
Do we need a finished SBOM before an introduction?
No. An introduction needs only basic fit information about size, history, systems and rights. The audit can run after SourceX's initial qualification, when the company completes its data inventory. Knowing the rough share of third-party and contractor code early still helps the CEO judge whether the codebase is worth putting forward.
What if contractor code has no IP assignment?
Treat it as excluded until fixed. Code commissioned from a contractor is not automatically owned by the company, so counsel may recommend a written assignment from the contractor or agency, if they can still be reached. Where that is not possible, remove those files or repositories from scope and note the gap in the summary.
Is AI-assisted code in the repositories a problem?
Flag it in the summary so counsel can review it, because questions about rights in AI-generated material are still developing. Code written with an assistant as part of normal engineering work is different from records generated with AI in order to sell them, which is a red flag that disqualifies material from licensing.
Related pages
- ITAR and EAR technical data: why controlled records stay out of a data license
- Which US businesses are a fit for a SourceX data licensing introduction
- Referral opportunities for fractional CTOs
- CMMS migration: how to preserve maintenance history before cutover
- Call recording retention policy: what to keep, what to purge and what to list first
Free resources
- Enterprise value calculator — Enterprise value from equity value, debt and cash.
- Earnout scenario calculator — Probability-weighted earnout value and its present value.
- Profit margin calculator — Profit and margin across three scenarios.
- All free tools · MCP resource center
By SourceX Partnerships Team · Published 2026-10-09 · Updated 2026-10-09
Know a US company with valuable proprietary data?
Become a referral partner from anywhere we support, get your link and introduce an owner or authorized decision-maker.
Refer a company →I own a business
Explore licensing your company's data to AI developers worldwide. Start a short assessment; no uploads needed.
Start an assessment