Yubico CSV Conversion Tool For Duo is a Powershell script that allows you to convert CSV files into a CSV format that Duo will accept for import.
- Non Destructive! - Original source material is not modified with this script.
- Scaleable! This script is performant even with CSV files containing 100K+ entries.
- Fast! Convert your file and be on your way.
- Any operating system capable of running Powershell (Windows, Linux, macOS)
- While this script runs on virtually any version of Powershell, it is the most performant when running on Powershell 7+.
- A CSV file to use. You may have recieved one from the Yubico Production Team via a Custom Configuration order, or you may have generated one after using the Yubico Personalization Tool.
-
As a general rule of thumb, never run Powershell scripts that you do not understand. Always feel free to review this script for yourself and ask questions in the form of a GitHub Issue
-
For safety, I recommend that you run this script on a secure machine, taking care to delete or securely store the CSV file once you are done uploading it to Duo. This script does not require network access.
-
For clarity on Powershell's default script execution policies, please review the Microsoft documentation .
- Launch
Yubico_CSV_Conversion_Tool_For_Duo.ps1
- Follow the prompt to select or define the location of the CSV file you wish to convert
- Review the location of the CSV file to convert and the location of the converted file, then press Enter to start
- There will be a CSV file in the same directory as the original file entitled
<sourcematerial>_ConvertedForDuo.CSV
. - Upload this file to Duo
- A Yubico Format CSV file looks like this
7538154,ejfhcciecgul,ea8d4cf9b363,aa4badc32d149a4c5df0612d278e28e1,000000000000,2023-04-13T11:53:36,
This equates to...
Serial Number, Public ID, Private ID, Seed Value, Access Code, Timestamp
- Conversely, a Duo formatted CSV file looks like this
ejfhcciecgul,ea8d4cf9b363,aa4badc32d149a4c5df0612d278e28e1,
Which in English, looks like the following
Public ID, Private ID, Seed Value,
This script is designed to create a Duo appropriate CSV file by copying the second, third and fourth columns of each CSV line into a new file.