Skip to content

zspitzer/extension-smb

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Lucee Extension SMB Resource Provider

Java CI

This extension provides SMB (Server Message Block) / CIFS (Common Internet File System) virtual file system support for Lucee, allowing you to read, write, and manipulate files on Windows network shares and Samba servers using standard CFML file functions.

Documentation

Usage

Access SMB shares using the smb:// scheme with standard CFML file functions:

// Basic usage with credentials in URL
smbPath = "smb://username:password@server/share/path/";

// Check if directory exists
if ( directoryExists( smbPath ) ) {
    // List files
    files = directoryList( smbPath );

    // Read a file
    content = fileRead( smbPath & "document.txt" );

    // Write a file
    fileWrite( smbPath & "output.txt", "Hello SMB!" );
}

// With domain authentication
smbPath = "smb://DOMAIN;username:password@server/share/";

URL Format

smb://[domain;]username:password@host[:port]/share/path/
  • domain - Optional Windows domain
  • username - SMB username
  • password - SMB password
  • host - Server hostname or IP
  • port - Optional port (default: 445)
  • share - Share name
  • path - Path within the share

Supported Operations

  • directoryCreate() / directoryDelete() / directoryExists() / directoryList()
  • fileRead() / fileWrite() / fileDelete() / fileExists()
  • fileCopy() / fileMove()
  • getFileInfo() / fileSetLastModified()

Requirements

  • Lucee 6.x or later
  • Java 17 or later

Technical Details

This extension uses jcifs-codelibs 3.0.0, a modern fork of the JCIFS library with SMB2/SMB3 support.

Issues

Lucee JIRA - SMB Issues

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors