Uint8List secureRandomBytes(int length) { final random = Random.secure(); return Uint8List.fromList( List<int>.generate(length, (_) => random.nextInt(256))); }