Secure form handling with client-side encryption for React applications - HIPAA-compliant form components with built-in security.
HIPPAGuard provides secure form components for handling sensitive healthcare data in React applications. It includes built-in encryption, data protection, and HIPAA compliance features.
- 🔒 Client-side AES-256-GCM encryption
- ⚕️ HIPAA & PHI/PII data protection
- 🛡️ Form validation & sanitization
- 🔄 Simple React hooks API
- 📝 Full TypeScript support
- ✅ Extensive test coverage
- 🚀 Lightweight with minimal dependencies
- 💪 Built for production use
npm install @hippaguard/react
import { SecureForm, SecureField } from '@hippaguard/react';
function PatientForm() {
const handleSubmit = async (data) => {
// Data is automatically encrypted
console.log('Encrypted form data:', data);
};
return (
<SecureForm onSubmit={handleSubmit}>
<SecureField
name="firstName"
label="First Name"
required
sensitivityLevel="PHI"
/>
<SecureTextArea
name="symptoms"
label="Current Symptoms"
sensitivityLevel="PHI"
/>
<button type="submit">
Submit
</button>
</SecureForm>
);
}
Standard input field with encryption and validation.
<SecureField
name="ssn"
label="Social Security Number"
type="text"
sensitivityLevel="PII"
validateFn={validateSSN}
required
/>
Multiline text input with encryption.
<SecureTextArea
name="notes"
label="Medical Notes"
rows={4}
sensitivityLevel="PHI"
/>
Secure checkbox component.
<SecureCheckbox
name="consent"
label="I consent to treatment"
sensitivityLevel="PHI"
/>
Radio button group with encryption.
<SecureRadioGroup
name="gender"
label="Gender"
options={['Male', 'Female', 'Other']}
sensitivityLevel="PHI"
/>
Built-in validation helpers:
import { validators } from '@hippaguard/react';
<SecureField
name="email"
validateFn={validators.combine([
validators.required(),
validators.email()
])}
/>
Provides encryption context.
import { SecurityProvider } from '@hippaguard/react';
function App() {
return (
<SecurityProvider>
<YourApp />
</SecurityProvider>
);
}
Access encryption functions.
const { encrypt, decrypt } = useSecurity();
- 🔐 AES-256-GCM encryption
- 🔑 Unique IV per encryption
- 🛡️ PBKDF2 key derivation
- 🧹 Auto key cleanup
- 🔒 Zero plaintext storage
- ✅ Input sanitization
We welcome contributions! Please check our Contributing Guide.
- Clone repo
git clone https://github.com/Anas-debug/HIPPAGuard.git
- Install dependencies
npm install
- Run tests
npm test
- Unit tests
- Integration tests
- Security tests
- Edge cases
- Current coverage: ~87%
- 📝 Documentation
- 🐛 Issues